Mercurial > SDL_sound_CoreAudio
annotate configure.in @ 103:706ec5842737
Updated for autoconf change, and placed #error messages so people don't
build this file.
author | Ryan C. Gordon <icculus@icculus.org> |
---|---|
date | Wed, 03 Oct 2001 18:15:25 +0000 |
parents | 6d9fdec2f708 |
children | de42ca5599ac |
rev | line source |
---|---|
65 | 1 # Process this file with autoconf to produce a configure script. |
66
54e10585e0cf
Changed AC_INIT() to look for SDL_sound.c, not COPYING, since I'm keeping
Ryan C. Gordon <icculus@icculus.org>
parents:
65
diff
changeset
|
2 AC_INIT(SDL_sound.c) |
65 | 3 |
4 dnl --------------------------------------------------------------------- | |
5 dnl System/version info | |
6 dnl --------------------------------------------------------------------- | |
7 | |
8 # Making releases: | |
9 # MICRO_VERSION += 1; | |
10 # INTERFACE_AGE += 1; | |
11 # BINARY_AGE += 1; | |
12 # if any functions have been added, set INTERFACE_AGE to 0. | |
13 # if backwards compatibility has been broken, | |
14 # set BINARY_AGE and INTERFACE_AGE to 0. | |
15 | |
16 MAJOR_VERSION=0 | |
17 MINOR_VERSION=1 | |
18 MICRO_VERSION=2 | |
19 INTERFACE_AGE=0 | |
20 BINARY_AGE=0 | |
21 VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION | |
22 | |
23 AC_SUBST(MAJOR_VERSION) | |
24 AC_SUBST(MINOR_VERSION) | |
25 AC_SUBST(MICRO_VERSION) | |
26 AC_SUBST(INTERFACE_AGE) | |
27 AC_SUBST(BINARY_AGE) | |
28 AC_SUBST(VERSION) | |
29 | |
30 # libtool versioning | |
31 LT_RELEASE=$MAJOR_VERSION.$MINOR_VERSION | |
32 LT_CURRENT=`expr $MICRO_VERSION - $INTERFACE_AGE` | |
33 LT_REVISION=$INTERFACE_AGE | |
34 LT_AGE=`expr $BINARY_AGE - $INTERFACE_AGE` | |
35 | |
36 AC_SUBST(LT_RELEASE) | |
37 AC_SUBST(LT_CURRENT) | |
38 AC_SUBST(LT_REVISION) | |
39 AC_SUBST(LT_AGE) | |
40 | |
41 dnl Detect the canonical host and target build environment | |
42 AC_CANONICAL_HOST | |
43 AC_CANONICAL_TARGET | |
44 | |
45 dnl Setup for automake | |
100
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
46 AM_CONFIG_HEADER(config.h) |
65 | 47 AM_INIT_AUTOMAKE(SDL_sound, $VERSION) |
48 | |
49 | |
50 dnl --------------------------------------------------------------------- | |
51 dnl Compilers and other tools | |
52 dnl --------------------------------------------------------------------- | |
53 | |
54 AC_PROG_CC | |
55 AC_PROG_INSTALL | |
56 AC_PROG_LN_S | |
57 AC_PROG_LIBTOOL | |
58 | |
59 | |
60 dnl --------------------------------------------------------------------- | |
100
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
61 dnl Debug mode? |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
62 dnl --------------------------------------------------------------------- |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
63 |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
64 AC_ARG_ENABLE(debug, |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
65 [ --enable-debug enable debug mode [default=no]], |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
66 , enable_smpeg=no) |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
67 if test x$enable_debug = xyes; then |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
68 if test x$ac_cv_prog_cc_g = xyes; then |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
69 CFLAGS="-g -O0" |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
70 else |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
71 CFLAGS="-O0" |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
72 fi |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
73 AC_DEFINE(DEBUG) |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
74 else |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
75 AC_DEFINE(NDEBUG) |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
76 fi |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
77 |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
78 |
6d9fdec2f708
added config.h, added --enable-debug flag, various other changes to the build system
fingolfin
parents:
85
diff
changeset
|
79 dnl --------------------------------------------------------------------- |
65 | 80 dnl Checks for libraries. |
81 dnl --------------------------------------------------------------------- | |
82 | |
83 dnl Check for SDL | |
84 SDL_VERSION=1.2.0 | |
85 AM_PATH_SDL($SDL_VERSION, | |
86 :, | |
87 AC_MSG_ERROR([*** SDL version $SDL_VERSION not found!]) | |
88 ) | |
89 CFLAGS="$CFLAGS $SDL_CFLAGS" | |
90 LIBS="$LIBS $SDL_LIBS" | |
91 | |
92 dnl Check for voc decoder inclusion... | |
93 AC_ARG_ENABLE(voc, | |
94 [ --enable-voc enable VOC decoding [default=yes]], | |
95 , enable_voc=yes) | |
96 if test x$enable_voc = xyes; then | |
97 AC_DEFINE(SOUND_SUPPORTS_VOC) | |
98 fi | |
99 | |
100 | |
101 dnl Check for wav decoder inclusion... | |
102 AC_ARG_ENABLE(wav, | |
103 [ --enable-wav enable WAV decoding [default=yes]], | |
104 , enable_wav=yes) | |
105 if test x$enable_wav = xyes; then | |
106 AC_DEFINE(SOUND_SUPPORTS_WAV) | |
107 fi | |
108 | |
109 | |
110 dnl Check for raw decoder inclusion... | |
111 AC_ARG_ENABLE(raw, | |
112 [ --enable-raw enable raw audio "decoding" [default=yes]], | |
113 , enable_raw=yes) | |
114 if test x$enable_raw = xyes; then | |
115 AC_DEFINE(SOUND_SUPPORTS_RAW) | |
116 fi | |
117 | |
118 | |
119 dnl Check for aiff decoder inclusion... | |
120 AC_ARG_ENABLE(aiff, | |
121 [ --enable-aiff enable AIFF decoding [default=yes]], | |
122 , enable_aiff=yes) | |
123 if test x$enable_aiff = xyes; then | |
124 AC_DEFINE(SOUND_SUPPORTS_AIFF) | |
125 fi | |
126 | |
127 | |
85 | 128 dnl DO NOT ENABLE THIS YET. IT'S NOT COMPLETE. |
129 dnl DO NOT ENABLE THIS YET. IT'S NOT COMPLETE. | |
130 dnl DO NOT ENABLE THIS YET. IT'S NOT COMPLETE. | |
131 dnl DO NOT ENABLE THIS YET. IT'S NOT COMPLETE. | |
132 dnl Check for shn decoder inclusion... | |
133 AC_ARG_ENABLE(shn, | |
134 [ --enable-shn enable SHN decoding [default=no]], | |
135 , enable_shn=no) | |
136 if test x$enable_shn = xyes; then | |
137 AC_DEFINE(SOUND_SUPPORTS_SHN) | |
138 fi | |
139 dnl DO NOT ENABLE THIS YET. IT'S NOT COMPLETE. | |
140 dnl DO NOT ENABLE THIS YET. IT'S NOT COMPLETE. | |
141 dnl DO NOT ENABLE THIS YET. IT'S NOT COMPLETE. | |
142 dnl DO NOT ENABLE THIS YET. IT'S NOT COMPLETE. | |
143 | |
144 | |
65 | 145 dnl Check for libmikmod |
146 AC_ARG_ENABLE(mikmod, | |
147 [ --enable-mikmod enable MOD decoding via mikmod [default=yes]], | |
148 , enable_mikmod=yes) | |
149 if test x$enable_mikmod = xyes; then | |
150 AM_PATH_LIBMIKMOD | |
151 if test "x$no_libmikmod" = "x" ; then | |
152 CFLAGS="$CFLAGS $LIBMIKMOD_CFLAGS" | |
153 LIBS="$LIBS $LIBMIKMOD_LIBS" | |
154 LDADD="$LDADD $LIBMIKMOD_LDADD" | |
155 AC_DEFINE(SOUND_SUPPORTS_MOD) | |
156 fi | |
157 fi | |
158 | |
159 dnl Check for vorbis | |
160 AC_ARG_ENABLE(vorbis, | |
161 [ --enable-vorbis enable OGG music via vorbis [default=yes]], | |
162 , enable_vorbis=yes) | |
163 if test x$enable_vorbis = xyes; then | |
164 AM_PATH_VORBIS | |
165 if test "x$no_vorbis" = "x" ; then | |
166 CFLAGS="$CFLAGS $VORBIS_CFLAGS" | |
167 LIBS="$LIBS $VORBIS_LIBS $VORBISFILE_LIBS $VORBISENC_LIBS" | |
168 AC_DEFINE(SOUND_SUPPORTS_OGG) | |
169 fi | |
170 fi | |
171 | |
172 dnl Check for SMPEG | |
173 AC_ARG_ENABLE(smpeg, | |
174 [ --enable-smpeg enable MP3 music via smpeg [default=yes]], | |
175 , enable_smpeg=yes) | |
176 if test x$enable_smpeg = xyes; then | |
177 SMPEG_VERSION=0.4.3 | |
178 AM_PATH_SMPEG($SMPEG_VERSION, , no_smpeg=yes) | |
179 if test "x$no_smpeg" = "x" ; then | |
180 CFLAGS="$CFLAGS $SMPEG_CFLAGS" | |
181 LIBS="$LIBS $SMPEG_LIBS" | |
182 AC_DEFINE(SOUND_SUPPORTS_MP3) | |
183 fi | |
184 fi | |
185 | |
186 | |
187 | |
188 # Checks for header files. | |
189 AC_HEADER_STDC | |
190 AC_CHECK_HEADERS([stdlib.h string.h]) | |
191 | |
192 # Checks for typedefs, structures, and compiler characteristics. | |
193 AC_C_CONST | |
194 AC_TYPE_SIZE_T | |
195 | |
196 # Checks for library functions. | |
74
2777e65f6478
Commented out AC_FUNC_MALLOC for now.
Ryan C. Gordon <icculus@icculus.org>
parents:
66
diff
changeset
|
197 |
2777e65f6478
Commented out AC_FUNC_MALLOC for now.
Ryan C. Gordon <icculus@icculus.org>
parents:
66
diff
changeset
|
198 # This is only in the bleeding edge autoconf distro... |
2777e65f6478
Commented out AC_FUNC_MALLOC for now.
Ryan C. Gordon <icculus@icculus.org>
parents:
66
diff
changeset
|
199 #AC_FUNC_MALLOC |
2777e65f6478
Commented out AC_FUNC_MALLOC for now.
Ryan C. Gordon <icculus@icculus.org>
parents:
66
diff
changeset
|
200 |
65 | 201 AC_FUNC_MEMCMP |
202 AC_CHECK_FUNCS([memset strrchr]) | |
203 | |
204 | |
205 AC_OUTPUT([ | |
206 Makefile | |
207 decoders/Makefile | |
208 test/Makefile | |
209 ]) |