VirtualBox

source: vbox/trunk/src/libs/libogg-1.3.5/configure.ac@ 99863

Last change on this file since 99863 was 96360, checked in by vboxsync, 2 years ago

libogg, libvorbis: export to OSE

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 5.1 KB
Line 
1dnl Process this file with autoconf to produce a configure script.
2
3AC_INIT([libogg],[1.3.5],[[email protected]])
4
5LT_INIT
6AC_CONFIG_MACRO_DIR([m4])
7AC_CONFIG_SRCDIR(src/framing.c)
8
9AM_INIT_AUTOMAKE
10AM_MAINTAINER_MODE([enable])
11
12dnl Library versioning
13
14LIB_CURRENT=8
15LIB_REVISION=5
16LIB_AGE=8
17AC_SUBST(LIB_CURRENT)
18AC_SUBST(LIB_REVISION)
19AC_SUBST(LIB_AGE)
20
21AC_PROG_CC
22AM_PROG_CC_C_O
23
24dnl Set some options based on environment
25
26cflags_save="$CFLAGS"
27if test -z "$GCC"; then
28 case $host in
29 *-*-irix*)
30 DEBUG="-g -signed"
31 CFLAGS="-O2 -w -signed"
32 PROFILE="-p -g3 -O2 -signed"
33 ;;
34 sparc-sun-solaris*)
35 DEBUG="-v -g"
36 CFLAGS="-xO4 -fast -w -fsimple -native -xcg92"
37 PROFILE="-v -xpg -g -xO4 -fast -native -fsimple -xcg92 -Dsuncc"
38 ;;
39 *)
40 DEBUG="-g"
41 CFLAGS="-O"
42 PROFILE="-g -p"
43 ;;
44 esac
45else
46 case $host in
47 *-*-linux*)
48 DEBUG="-g -Wall -fsigned-char"
49 CFLAGS="-O2 -Wall -ffast-math -fsigned-char"
50 PROFILE="-Wall -W -pg -g -O2 -ffast-math -fsigned-char"
51 ;;
52 sparc-sun-*)
53 DEBUG="-g -Wall -fsigned-char"
54 CFLAGS="-O2 -ffast-math -fsigned-char"
55 PROFILE="-pg -g -O2 -fsigned-char"
56 ;;
57 *-*-darwin*)
58 DEBUG="-fno-common -g -Wall -fsigned-char"
59 CFLAGS="-fno-common -O4 -Wall -fsigned-char -ffast-math"
60 PROFILE="-fno-common -O4 -Wall -pg -g -fsigned-char -ffast-math"
61 ;;
62 *)
63 DEBUG="-g -Wall -fsigned-char"
64 CFLAGS="-O2 -fsigned-char"
65 PROFILE="-O2 -g -pg -fsigned-char"
66 ;;
67 esac
68fi
69CFLAGS="$CFLAGS $cflags_save"
70DEBUG="$DEBUG $cflags_save"
71PROFILE="$PROFILE $cflags_save"
72
73dnl Checks for programs.
74
75dnl Checks for libraries.
76
77dnl Checks for header files.
78AC_HEADER_STDC
79INCLUDE_INTTYPES_H=0
80INCLUDE_STDINT_H=0
81INCLUDE_SYS_TYPES_H=0
82AC_CHECK_HEADER(inttypes.h,INCLUDE_INTTYPES_H=1)
83AC_CHECK_HEADER(stdint.h,INCLUDE_STDINT_H=1)
84AC_CHECK_HEADER(sys/types.h,INCLUDE_SYS_TYPES_H=1)
85
86dnl Checks for typedefs, structures, and compiler characteristics.
87AC_C_CONST
88
89dnl Check for types
90
91AC_CHECK_SIZEOF(int16_t)
92AC_CHECK_SIZEOF(uint16_t)
93AC_CHECK_SIZEOF(u_int16_t)
94AC_CHECK_SIZEOF(int32_t)
95AC_CHECK_SIZEOF(uint32_t)
96AC_CHECK_SIZEOF(u_int32_t)
97AC_CHECK_SIZEOF(int64_t)
98AC_CHECK_SIZEOF(uint64_t)
99AC_CHECK_SIZEOF(short)
100AC_CHECK_SIZEOF(int)
101AC_CHECK_SIZEOF(long)
102AC_CHECK_SIZEOF(long long)
103
104case 2 in
105 $ac_cv_sizeof_int16_t) SIZE16="int16_t";;
106 $ac_cv_sizeof_short) SIZE16="short";;
107 $ac_cv_sizeof_int) SIZE16="int";;
108esac
109
110case 2 in
111 $ac_cv_sizeof_uint16_t) USIZE16="uint16_t";;
112 $ac_cv_sizeof_short) USIZE16="unsigned short";;
113 $ac_cv_sizeof_int) USIZE16="unsigned int";;
114 $ac_cv_sizeof_u_int16_t) USIZE16="u_int16_t";;
115esac
116
117case 4 in
118 $ac_cv_sizeof_int32_t) SIZE32="int32_t";;
119 $ac_cv_sizeof_short) SIZE32="short";;
120 $ac_cv_sizeof_int) SIZE32="int";;
121 $ac_cv_sizeof_long) SIZE32="long";;
122esac
123
124case 4 in
125 $ac_cv_sizeof_uint32_t) USIZE32="uint32_t";;
126 $ac_cv_sizeof_short) USIZE32="unsigned short";;
127 $ac_cv_sizeof_int) USIZE32="unsigned int";;
128 $ac_cv_sizeof_long) USIZE32="unsigned long";;
129 $ac_cv_sizeof_u_int32_t) USIZE32="u_int32_t";;
130esac
131
132case 8 in
133 $ac_cv_sizeof_int64_t) SIZE64="int64_t";;
134 $ac_cv_sizeof_int) SIZE64="int";;
135 $ac_cv_sizeof_long) SIZE64="long";;
136 $ac_cv_sizeof_long_long) SIZE64="long long";;
137esac
138
139case 8 in
140 $ac_cv_sizeof_uint64_t) USIZE64="uint64_t";;
141 $ac_cv_sizeof_unsigned_int) USIZE64="unsigned int";;
142 $ac_cv_sizeof_unsigned_long) USIZE64="unsigned long";;
143 $ac_cv_sizeof_unsigned_long_long) USIZE64="unsigned long long";;
144esac
145
146if test -z "$SIZE16"; then
147 AC_MSG_ERROR(No 16 bit type found on this platform!)
148fi
149if test -z "$USIZE16"; then
150 AC_MSG_ERROR(No unsigned 16 bit type found on this platform!)
151fi
152if test -z "$SIZE32"; then
153 AC_MSG_ERROR(No 32 bit type found on this platform!)
154fi
155if test -z "$USIZE32"; then
156 AC_MSG_ERROR(No unsigned 32 bit type found on this platform!)
157fi
158if test -z "$SIZE64"; then
159 AC_MSG_WARN(No 64 bit type found on this platform!)
160fi
161if test -z "$USIZE64"; then
162 AC_MSG_WARN(No unsigned 64 bit type found on this platform!)
163fi
164
165AC_ARG_ENABLE([crc],
166 [AS_HELP_STRING([--disable-crc],
167 [Disable CRC in the demuxer])],,
168 [enable_crc=yes])
169
170AM_CONDITIONAL([DISABLE_CRC], [test "$enable_crc" = "no"])
171
172AS_IF([test "$enable_crc" = "no"],[
173 AC_DEFINE([DISABLE_CRC], [1], [Do not build with CRC])
174])
175
176dnl Checks for library functions.
177AC_FUNC_MEMCMP
178
179dnl Make substitutions
180
181AC_SUBST(LIBTOOL_DEPS)
182AC_SUBST(INCLUDE_INTTYPES_H)
183AC_SUBST(INCLUDE_STDINT_H)
184AC_SUBST(INCLUDE_SYS_TYPES_H)
185AC_SUBST(SIZE16)
186AC_SUBST(USIZE16)
187AC_SUBST(SIZE32)
188AC_SUBST(USIZE32)
189AC_SUBST(SIZE64)
190AC_SUBST(USIZE64)
191AC_SUBST(OPT)
192AC_SUBST(LIBS)
193AC_SUBST(DEBUG)
194AC_SUBST(CFLAGS)
195AC_SUBST(PROFILE)
196
197
198AC_CONFIG_FILES([
199Makefile
200src/Makefile
201doc/Makefile doc/libogg/Makefile
202include/Makefile include/ogg/Makefile include/ogg/config_types.h
203libogg.spec
204ogg.pc
205ogg-uninstalled.pc
206])
207AC_CONFIG_HEADERS([config.h])
208
209AC_OUTPUT
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette