Commit | Line | Data |
---|---|---|
de6d9b64 | 1 | #!/bin/sh |
0f3cb305 | 2 | # |
5cbcf02c | 3 | # ffmpeg configure script (c) 2000, 2001, 2002 Fabrice Bellard |
0f3cb305 | 4 | # |
cf9d24ad DC |
5 | |
6 | if test x"$1" = x"-h" -o x"$1" = x"--help" ; then | |
7 | cat << EOF | |
8 | ||
9 | Usage: configure [options] | |
10 | Options: [defaults in brackets after descriptions] | |
11 | ||
12 | EOF | |
13 | echo "Standard options:" | |
14 | echo " --help print this message" | |
15 | echo " --prefix=PREFIX install in PREFIX [$prefix]" | |
16 | echo " --mandir=DIR man documentation in DIR [PREFIX/man]" | |
17 | echo " --enable-mp3lame enable mp3 encoding via libmp3lame [default=no]" | |
18 | echo " --enable-vorbis enable vorbis support via libvorbisenc [default=no]" | |
19 | echo " --enable-faad enable faad support via libfaad [default=no]" | |
20 | echo " --enable-faadbin build faad support with runtime linking [default=no]" | |
21 | echo " --enable-faac enable faac support via libfaac [default=no]" | |
22 | echo " --enable-mingw32 enable mingw32 native/cross windows compile" | |
23 | echo " --enable-a52 enable GPL'ed A52 support [default=no]" | |
24 | echo " --enable-a52bin open liba52.so.0 at runtime [default=no]" | |
23c99253 | 25 | echo " --enable-dts enable GPL'ed DTS support [default=no]" |
cf9d24ad DC |
26 | echo " --enable-pp enable GPL'ed post processing support [default=no]" |
27 | echo " --enable-shared-pp use libpostproc.so [default=no]" | |
28 | echo " --enable-shared build shared libraries [default=no]" | |
29 | echo " --enable-amr_nb enable amr_nb float audio codec" | |
30 | echo " --enable-amr_nb-fixed use fixed point for amr-nb codec" | |
64cba748 | 31 | echo " --enable-amr_wb enable amr_wb float audio codec" |
cf9d24ad | 32 | echo " --enable-sunmlib use Sun medialib [default=no]" |
9c3d33d6 | 33 | echo " --enable-pthreads use pthreads [default=no]" |
b2e3c528 | 34 | echo " --enable-gpl allow use of gpl code, the resulting libav* and ffmpeg will be under gpl [default=no]" |
cf9d24ad DC |
35 | echo "" |
36 | echo "Advanced options (experts only):" | |
37 | echo " --source-path=PATH path of source code [$source_path]" | |
38 | echo " --cross-prefix=PREFIX use PREFIX for compile tools [$cross_prefix]" | |
39 | echo " --cc=CC use C compiler CC [$cc]" | |
40 | echo " --make=MAKE use specified make [$make]" | |
41 | echo " --extra-cflags=ECFLAGS add ECFLAGS to CFLAGS [$CFLAGS]" | |
42 | echo " --extra-ldflags=ELDFLAGS add ELDFLAGS to LDFLAGS [$LDFLAGS]" | |
43 | echo " --extra-libs=ELIBS add ELIBS [$ELIBS]" | |
44 | echo " --cpu=CPU force cpu to CPU [$cpu]" | |
45 | echo " --tune=PROCESSOR tune code for a particular CPU (may fails or misperforms on other CPUs)" | |
46 | echo " --powerpc-perf-enable enable performance report on PPC (requires enabling PMC)" | |
47 | echo " --disable-mmx disable mmx usage" | |
48 | echo " --disable-altivec disable AltiVec usage" | |
49 | echo " --disable-audio-oss disable OSS audio support [default=no]" | |
50 | echo " --disable-audio-beos disable BeOS audio support [default=no]" | |
51 | echo " --disable-v4l disable video4linux grabbing [default=no]" | |
52 | echo " --disable-dv1394 disable DV1394 grabbing [default=no]" | |
53 | echo " --disable-network disable network support [default=no]" | |
54 | echo " --disable-zlib disable zlib [default=no]" | |
55 | echo " --disable-simple_idct disable simple IDCT routines [default=no]" | |
56 | echo " --disable-vhook disable video hooking support" | |
57 | echo " --enable-gprof enable profiling with gprof [$gprof]" | |
58 | echo " --disable-debug disable debugging symbols" | |
59 | echo " --disable-opts disable compiler optimizations" | |
60 | echo " --disable-mpegaudio-hp faster (but less accurate)" | |
61 | echo " mpegaudio decoding [default=no]" | |
62 | echo " --disable-ffserver disable ffserver build" | |
63 | echo " --disable-ffplay disable ffplay build" | |
64 | echo " --disable-risky disables patent encumbered codecs" | |
65 | echo " --enable-small optimize for size instead of speed" | |
da9b170c | 66 | echo " --enable-memalign-hack emulate memalign, interferes with memory debuggers" |
cf9d24ad DC |
67 | echo "" |
68 | echo "NOTE: The object files are build at the place where configure is launched" | |
69 | exit 1 | |
70 | fi | |
71 | ||
0f3cb305 | 72 | # set temporary file name |
57514323 | 73 | if test ! -z "$TMPDIR" ; then |
0f3cb305 | 74 | TMPDIR1="${TMPDIR}" |
57514323 | 75 | elif test ! -z "$TEMPDIR" ; then |
0f3cb305 | 76 | TMPDIR1="${TEMPDIR}" |
3d204385 | 77 | else |
0f3cb305 | 78 | TMPDIR1="/tmp" |
3d204385 NK |
79 | fi |
80 | ||
0f3cb305 FB |
81 | TMPC="${TMPDIR1}/ffmpeg-conf-${RANDOM}-$$-${RANDOM}.c" |
82 | TMPO="${TMPDIR1}/ffmpeg-conf-${RANDOM}-$$-${RANDOM}.o" | |
f3ec2d46 | 83 | TMPE="${TMPDIR1}/ffmpeg-conf-${RANDOM}-$$-${RANDOM}" |
0f3cb305 FB |
84 | TMPS="${TMPDIR1}/ffmpeg-conf-${RANDOM}-$$-${RANDOM}.S" |
85 | TMPH="${TMPDIR1}/ffmpeg-conf-${RANDOM}-$$-${RANDOM}.h" | |
86 | ||
de6d9b64 FB |
87 | # default parameters |
88 | prefix="/usr/local" | |
23a65308 | 89 | mandir="" |
951bf3e6 | 90 | bindir="" |
0f3cb305 | 91 | cross_prefix="" |
de6d9b64 FB |
92 | cc="gcc" |
93 | ar="ar" | |
be7109c1 | 94 | ranlib="ranlib" |
4a908fbc | 95 | make="make" |
0f3cb305 | 96 | strip="strip" |
de6d9b64 | 97 | cpu=`uname -m` |
a4adb608 | 98 | tune="generic" |
e45a2872 | 99 | powerpc_perf="no" |
0f3cb305 | 100 | mmx="default" |
ab6c65f6 | 101 | altivec="default" |
d46aba26 | 102 | mmi="default" |
de6d9b64 | 103 | case "$cpu" in |
ef0bc4c9 | 104 | i386|i486|i586|i686|i86pc|BePC) |
de6d9b64 | 105 | cpu="x86" |
de6d9b64 | 106 | ;; |
93caefc7 AB |
107 | # armv4l is a subset of armv5tel |
108 | armv4l|armv5tel) | |
6ed7422a | 109 | cpu="armv4l" |
6ed7422a | 110 | ;; |
91d1f1a4 NK |
111 | alpha) |
112 | cpu="alpha" | |
91d1f1a4 | 113 | ;; |
a43bd1d7 | 114 | "Power Macintosh"|ppc) |
90cee0c3 MN |
115 | cpu="powerpc" |
116 | ;; | |
d46aba26 LS |
117 | mips) |
118 | cpu="mips" | |
119 | ;; | |
bb476ff3 | 120 | sun4u|sparc64) |
a7beab73 RS |
121 | cpu="sparc64" |
122 | ;; | |
bb476ff3 JM |
123 | sparc) |
124 | cpu="sparc" | |
125 | ;; | |
bdb2e37c AB |
126 | sh4) |
127 | cpu="sh4" | |
128 | ;; | |
de6d9b64 | 129 | *) |
0f3cb305 | 130 | cpu="unknown" |
de6d9b64 FB |
131 | ;; |
132 | esac | |
133 | gprof="no" | |
5cbcf02c FB |
134 | v4l="yes" |
135 | audio_oss="yes" | |
dfdfa47c | 136 | audio_beos="no" |
8aa3ee32 | 137 | dv1394="yes" |
5cbcf02c | 138 | network="yes" |
0147f198 | 139 | zlib="yes" |
a6741398 | 140 | mp3lame="no" |
81e0d0b4 | 141 | vorbis="no" |
0fc50e58 ZK |
142 | faad="no" |
143 | faadbin="no" | |
29d48296 | 144 | faac="no" |
ba9261e5 | 145 | a52="no" |
57514323 | 146 | a52bin="no" |
23c99253 | 147 | dts="no" |
ba9261e5 | 148 | pp="no" |
bba9b16c | 149 | shared_pp="no" |
732d9245 | 150 | mingw32="no" |
3f027ca7 | 151 | cygwin="no" |
f3ec2d46 | 152 | os2="no" |
83286d2a | 153 | lshared="no" |
cddf3f45 GM |
154 | optimize="yes" |
155 | debug="yes" | |
ef0bc4c9 | 156 | extralibs="-lm" |
c02dbee1 | 157 | simpleidct="yes" |
0f3cb305 | 158 | bigendian="no" |
7f965c1c | 159 | inttypes="yes" |
b5c950c4 | 160 | emu_fast_int="no" |
a8721c09 | 161 | vhook="default" |
adbc0510 PG |
162 | dlfcn="no" |
163 | dlopen="no" | |
1eb2212e | 164 | mpegaudio_hp="yes" |
e1707f52 | 165 | SHFLAGS=-shared |
26b35efb | 166 | netserver="no" |
4baca069 | 167 | need_inet_aton="no" |
8154d2e0 | 168 | ffserver="yes" |
a86b921c | 169 | ffplay="yes" |
4baca069 PG |
170 | LDFLAGS=-Wl,--warn-common |
171 | FFSLDFLAGS=-Wl,-E | |
f3ec2d46 SG |
172 | LIBPREF="lib" |
173 | LIBSUF=".a" | |
174 | SLIBPREF="lib" | |
175 | SLIBSUF=".so" | |
951bf3e6 | 176 | EXESUF="" |
1d0d55da | 177 | risky="yes" |
891f64b3 | 178 | amr_nb="no" |
d663a1fd | 179 | amr_wb="no" |
bc634f6f | 180 | amr_nb_fixed="no" |
f80f7964 | 181 | sunmlib="no" |
9c3d33d6 | 182 | pthreads="no" |
b2e3c528 | 183 | gpl="no" |
da9b170c | 184 | memalignhack="no" |
ef0bc4c9 FR |
185 | |
186 | # OS specific | |
187 | targetos=`uname -s` | |
188 | case $targetos in | |
189 | BeOS) | |
190 | prefix="/boot/home/config" | |
191 | # helps building libavcodec | |
cddf3f45 | 192 | CFLAGS="-DPIC -fomit-frame-pointer" |
31ba0b4d | 193 | # 3 gcc releases known for BeOS, each with ugly bugs |
b2924696 | 194 | gcc_version="`$cc -v 2>&1 | grep version | cut -d ' ' -f3-`" |
31ba0b4d FR |
195 | case "$gcc_version" in |
196 | 2.9-beos-991026*|2.9-beos-000224*) echo "R5/GG gcc" | |
197 | mmx="no" | |
198 | ;; | |
199 | *20010315*) echo "BeBits gcc" | |
200 | CFLAGS="$CFLAGS -fno-expensive-optimizations" | |
201 | ;; | |
202 | esac | |
e1707f52 MN |
203 | SHFLAGS=-nostart |
204 | # disable linux things | |
205 | audio_oss="no" | |
5cbcf02c | 206 | v4l="no" |
8aa3ee32 | 207 | dv1394="no" |
dfdfa47c FR |
208 | # enable beos things |
209 | audio_beos="yes" | |
ef0bc4c9 FR |
210 | # no need for libm, but the inet stuff |
211 | # Check for BONE | |
212 | if (echo $BEINCLUDES|grep 'headers/be/bone' >/dev/null); then | |
213 | extralibs="-lbind -lsocket" | |
214 | else | |
26b35efb | 215 | netserver="yes" |
4baca069 | 216 | need_inet_aton="yes" |
26b35efb | 217 | extralibs="-lnet" |
ef0bc4c9 | 218 | fi ;; |
4baca069 PG |
219 | SunOS) |
220 | v4l="no" | |
221 | audio_oss="no" | |
8aa3ee32 | 222 | dv1394="no" |
4baca069 PG |
223 | make="gmake" |
224 | LDFLAGS="" | |
225 | FFSLDFLAGS="" | |
226 | need_inet_aton="yes" | |
227 | extralibs="$extralibs -lsocket -lnsl" | |
228 | ;; | |
9c938e77 PG |
229 | FreeBSD) |
230 | v4l="no" | |
231 | audio_oss="yes" | |
8aa3ee32 | 232 | dv1394="no" |
9c938e77 | 233 | make="gmake" |
12043e1d SS |
234 | CFLAGS="-pthread" |
235 | LDFLAGS="$LDFLAGS -export-dynamic -pthread" | |
9c938e77 | 236 | ;; |
4a908fbc | 237 | BSD/OS) |
5cbcf02c | 238 | v4l="no" |
6063bce7 | 239 | audio_oss="yes" |
8aa3ee32 | 240 | dv1394="no" |
4a908fbc AB |
241 | extralibs="-lpoll -lgnugetopt -lm" |
242 | make="gmake" | |
243 | ;; | |
90cee0c3 | 244 | Darwin) |
a43bd1d7 | 245 | cc="cc" |
90cee0c3 MN |
246 | v4l="no" |
247 | audio_oss="no" | |
8aa3ee32 | 248 | dv1394="no" |
d3b15036 | 249 | ffserver="no" |
a43bd1d7 | 250 | SHFLAGS="-dynamiclib" |
90cee0c3 | 251 | extralibs="" |
a43bd1d7 | 252 | darwin="yes" |
47930f09 | 253 | strip="strip -x" |
4850b2d2 | 254 | LDFLAGS="-Wl,-d" |
4baca069 | 255 | FFSLDFLAGS=-Wl,-bind_at_load |
90cee0c3 | 256 | ;; |
732d9245 | 257 | MINGW32*) |
951bf3e6 FB |
258 | # Note: the rest of the mingw32 config is done afterwards as mingw32 |
259 | # can be forced on command line for linux cross compilation | |
732d9245 BE |
260 | mingw32="yes" |
261 | ;; | |
3f027ca7 FB |
262 | CYGWIN*) |
263 | v4l="no" | |
264 | audio_oss="yes" | |
8aa3ee32 | 265 | dv1394="no" |
3f027ca7 FB |
266 | extralibs="" |
267 | cygwin="yes" | |
268 | test -f /usr/include/inttypes.h || \ | |
269 | test -f /usr/local/include/inttypes.h || \ | |
270 | echo "Missing inttypes.h, please copy cygwin_inttypes.h to" \ | |
271 | "/usr/include/inttypes.h !!!" | |
272 | ;; | |
b55e4ef4 | 273 | Linux) |
4baca069 | 274 | LDFLAGS="$LDFLAGS -rdynamic" |
b55e4ef4 | 275 | ;; |
99614dd4 MB |
276 | IRIX*) |
277 | ranlib="echo ignoring ranlib" | |
278 | v4l="no" | |
279 | audio_oss="no" | |
280 | make="gmake" | |
281 | ;; | |
f3ec2d46 SG |
282 | OS/2) |
283 | TMPE=$TMPE".exe" | |
69db4e10 SG |
284 | ar="emxomfar -p64" |
285 | ranlib="echo ignoring ranlib" | |
286 | strip="echo ignoring strip" | |
cddf3f45 | 287 | CFLAGS="-Zomf" |
69db4e10 | 288 | LDFLAGS="-Zomf -Zstack 16384 -s" |
f3ec2d46 SG |
289 | SHFLAGS="" |
290 | FFSLDFLAGS="" | |
291 | LIBPREF="" | |
292 | LIBSUF=".lib" | |
293 | SLIBPREF="" | |
294 | SLIBSUF=".dll" | |
951bf3e6 | 295 | EXESUF=".exe" |
f3ec2d46 SG |
296 | extralibs="" |
297 | v4l="no" | |
298 | audio_oss="no" | |
8aa3ee32 | 299 | dv1394="no" |
f3ec2d46 SG |
300 | network="no" |
301 | ffserver="no" | |
302 | os2="yes" | |
303 | ;; | |
ef0bc4c9 FR |
304 | *) ;; |
305 | esac | |
de6d9b64 | 306 | |
6852ac95 RD |
307 | # From mplayer configure. We need TARGET_OS available |
308 | # to the Makefile, so it can distinguish between flavors | |
309 | # of AltiVec on PowerPC | |
310 | TARGET_OS=`( uname -s ) 2>&1` | |
311 | case "$TARGET_OS" in | |
312 | Linux|FreeBSD|NetBSD|BSD/OS|OpenBSD|SunOS|QNX|Darwin|GNU) | |
313 | ;; | |
314 | IRIX*) | |
315 | TARGET_OS=IRIX | |
316 | ;; | |
317 | HP-UX*) | |
318 | TARGET_OS=HP-UX | |
319 | ;; | |
320 | [cC][yY][gG][wW][iI][nN]*) | |
321 | TARGET_OS=CYGWIN | |
322 | ;; | |
323 | *) | |
324 | TARGET_OS="$TARGET_OS-UNKNOWN" | |
325 | ;; | |
326 | esac | |
327 | ||
0f3cb305 FB |
328 | # find source path |
329 | # XXX: we assume an absolute path is given when launching configure, | |
330 | # except in './configure' case. | |
586bc755 | 331 | source_path="`echo $0 | sed -e 's#/configure##'`" |
0f3cb305 FB |
332 | source_path_used="yes" |
333 | if test -z "$source_path" -o "$source_path" = "." ; then | |
334 | source_path=`pwd` | |
335 | source_path_used="no" | |
de6d9b64 FB |
336 | fi |
337 | ||
338 | for opt do | |
339 | case "$opt" in | |
340 | --prefix=*) prefix=`echo $opt | cut -d '=' -f 2` | |
341 | ;; | |
23a65308 FB |
342 | --mandir=*) mandir=`echo $opt | cut -d '=' -f 2` |
343 | ;; | |
0f3cb305 FB |
344 | --source-path=*) source_path=`echo $opt | cut -d '=' -f 2` |
345 | ;; | |
346 | --cross-prefix=*) cross_prefix=`echo $opt | cut -d '=' -f 2` | |
347 | ;; | |
de6d9b64 FB |
348 | --cc=*) cc=`echo $opt | cut -d '=' -f 2` |
349 | ;; | |
4a908fbc AB |
350 | --make=*) make=`echo $opt | cut -d '=' -f 2` |
351 | ;; | |
0f3cb305 FB |
352 | --extra-cflags=*) CFLAGS="${opt#--extra-cflags=}" |
353 | ;; | |
354 | --extra-ldflags=*) LDFLAGS=${opt#--extra-ldflags=} | |
355 | ;; | |
356 | --extra-libs=*) extralibs=${opt#--extra-libs=} | |
357 | ;; | |
de6d9b64 FB |
358 | --cpu=*) cpu=`echo $opt | cut -d '=' -f 2` |
359 | ;; | |
a4adb608 MN |
360 | --tune=*) tune=`echo $opt | cut -d '=' -f 2` |
361 | ;; | |
e45a2872 RD |
362 | --powerpc-perf-enable) powerpc_perf="yes" |
363 | ;; | |
de6d9b64 FB |
364 | --disable-mmx) mmx="no" |
365 | ;; | |
ab6c65f6 BF |
366 | --disable-altivec) altivec="no" |
367 | ;; | |
de6d9b64 FB |
368 | --enable-gprof) gprof="yes" |
369 | ;; | |
5cbcf02c FB |
370 | --disable-v4l) v4l="no" |
371 | ;; | |
372 | --disable-audio-oss) audio_oss="no" | |
373 | ;; | |
dfdfa47c FR |
374 | --disable-audio-beos) audio_beos="no" |
375 | ;; | |
8aa3ee32 MK |
376 | --disable-dv1394) dv1394="no" |
377 | ;; | |
ffc0ef96 | 378 | --disable-network) network="no"; ffserver="no" |
5cbcf02c | 379 | ;; |
0147f198 FR |
380 | --disable-zlib) zlib="no" |
381 | ;; | |
ba9261e5 | 382 | --enable-a52) a52="yes" |
6ed7422a | 383 | ;; |
9c938e77 | 384 | --enable-a52bin) a52bin="yes" ; extralibs="$ldl $extralibs" |
57514323 | 385 | ;; |
23c99253 MN |
386 | --enable-dts) dts="yes" ; extralibs="$extralibs -ldts" |
387 | ;; | |
ba9261e5 | 388 | --enable-pp) pp="yes" |
bba9b16c MN |
389 | ;; |
390 | --enable-shared-pp) shared_pp="yes" | |
391 | ;; | |
a6741398 J |
392 | --enable-mp3lame) mp3lame="yes" |
393 | ;; | |
81e0d0b4 MH |
394 | --enable-vorbis) vorbis="yes" |
395 | ;; | |
445ad18d ZK |
396 | --enable-faad) faad="yes" |
397 | ;; | |
398 | --enable-faadbin) faadbin="yes" | |
399 | ;; | |
29d48296 MN |
400 | --enable-faac) faac="yes" |
401 | ;; | |
68892110 PG |
402 | --disable-vhook) vhook="no" |
403 | ;; | |
c02dbee1 | 404 | --disable-simple_idct) simpleidct="no" |
045ed63f | 405 | ;; |
732d9245 BE |
406 | --enable-mingw32) mingw32="yes" |
407 | ;; | |
83286d2a | 408 | --enable-shared) lshared="yes" |
0319c531 | 409 | ;; |
cddf3f45 GM |
410 | --disable-debug) debug="no" |
411 | ;; | |
412 | --disable-opts) optimize="no" | |
413 | ;; | |
1eb2212e FB |
414 | --disable-mpegaudio-hp) mpegaudio_hp="no" |
415 | ;; | |
8154d2e0 FB |
416 | --disable-ffserver) ffserver="no" |
417 | ;; | |
a86b921c FB |
418 | --disable-ffplay) ffplay="no" |
419 | ;; | |
1d0d55da MN |
420 | --disable-risky) risky="no" |
421 | ;; | |
cddf3f45 | 422 | --enable-small) optimize="small" |
553a6284 | 423 | ;; |
891f64b3 | 424 | --enable-amr_nb) amr_nb="yes" |
425 | ;; | |
bc634f6f ZK |
426 | --enable-amr_nb-fixed) amr_nb_fixed="yes" |
427 | ;; | |
64cba748 MN |
428 | --enable-amr_wb) amr_wb="yes" |
429 | ;; | |
f80f7964 RS |
430 | --enable-sunmlib) sunmlib="yes" |
431 | ;; | |
9c3d33d6 MN |
432 | --enable-pthreads) pthreads="yes" |
433 | ;; | |
b2e3c528 MN |
434 | --enable-gpl) gpl="yes" |
435 | ;; | |
da9b170c MN |
436 | --enable-memalign-hack) memalignhack="yes" |
437 | ;; | |
de6d9b64 FB |
438 | esac |
439 | done | |
440 | ||
b2e3c528 MN |
441 | if test "$gpl" != "yes"; then |
442 | if test "$pp" != "no" -o "$shared_pp" != "no"; then | |
443 | echo "The Postprocessing code is under GPL and --enable-gpl is not specified" | |
444 | fail="yes" | |
445 | fi | |
446 | ||
447 | if test "$a52" != "no" -o "$a52bin" != "no"; then | |
448 | echo "liba52 is under GPL and --enable-gpl is not specified" | |
449 | fail="yes" | |
450 | fi | |
23c99253 MN |
451 | |
452 | if test "$dts" != "no"; then | |
453 | echo "libdts is under GPL and --enable-gpl is not specified" | |
454 | fail="yes" | |
455 | fi | |
b2e3c528 MN |
456 | |
457 | if test "$faad" != "no" -o "$faadbin" != "no"; then | |
458 | cat > $TMPC << EOF | |
459 | #include <faad.h> | |
460 | int main( void ) { return 0; } | |
461 | EOF | |
462 | ||
463 | if $cc $CFLAGS -o $TMPE $TMPC 2> /dev/null ; then | |
464 | cat > $TMPC << EOF | |
465 | #include <faad.h> | |
466 | #ifndef FAAD2_VERSION | |
467 | ok faad1 | |
468 | #endif | |
469 | int main( void ) { return 0; } | |
470 | EOF | |
471 | if $cc $CFLAGS -o $TMPE $TMPC 2> /dev/null ; then | |
472 | echo "faad2 is under GPL and --enable-gpl is not specified" | |
473 | fail="yes" | |
474 | fi | |
475 | else | |
476 | faad="no" | |
477 | faadbin="no" | |
478 | echo "faad test failed" | |
479 | fi | |
480 | fi | |
481 | ||
482 | ||
a18b5183 | 483 | if test "$fail" = "yes"; then |
b2e3c528 MN |
484 | exit 1 |
485 | fi | |
486 | fi | |
487 | ||
0f3cb305 FB |
488 | # compute mmx state |
489 | if test $mmx = "default"; then | |
490 | if test $cpu = "x86"; then | |
491 | mmx="yes" | |
492 | else | |
493 | mmx="no" | |
494 | fi | |
495 | fi | |
496 | ||
cf9d24ad | 497 | #Darwin CC versions |
75388c74 | 498 | needmdynamicnopic="no" |
cf9d24ad | 499 | if test $targetos = Darwin; then |
b2924696 | 500 | if test -n "`$cc -v 2>&1 | grep xlc`"; then |
747a0554 | 501 | CFLAGS="$CFLAGS -qpdf2 -qlanglvl=extc99 -qmaxmem=-1 -qarch=auto -qtune=auto" |
cf9d24ad | 502 | else |
b2924696 | 503 | gcc_version="`$cc -v 2>&1 | grep version | cut -d ' ' -f3-`" |
cf9d24ad DC |
504 | case "$gcc_version" in |
505 | *2.95*) | |
747a0554 | 506 | CFLAGS="$CFLAGS -no-cpp-precomp -pipe -fomit-frame-pointer" |
cf9d24ad | 507 | ;; |
75388c74 | 508 | *3.*) |
747a0554 | 509 | CFLAGS="$CFLAGS -no-cpp-precomp -pipe -fomit-frame-pointer -force_cpusubtype_ALL -Wno-sign-compare" |
75388c74 MN |
510 | if test "$lshared" = no; then |
511 | needmdynamicnopic="yes" | |
512 | fi | |
cf9d24ad DC |
513 | ;; |
514 | *) | |
747a0554 | 515 | CFLAGS="$CFLAGS -no-cpp-precomp -pipe -fomit-frame-pointer" |
75388c74 MN |
516 | if test "$lshared" = no; then |
517 | needmdynamicnopic="yes" | |
518 | fi | |
cf9d24ad DC |
519 | ;; |
520 | esac | |
521 | fi | |
522 | fi | |
523 | ||
ab6c65f6 BF |
524 | # Can only do AltiVec on PowerPC |
525 | if test $altivec = "default"; then | |
526 | if test $cpu = "powerpc"; then | |
527 | altivec="yes" | |
528 | else | |
529 | altivec="no" | |
530 | fi | |
531 | fi | |
532 | ||
a4adb608 MN |
533 | # Add processor-specific flags |
534 | TUNECPU="generic" | |
9007f514 | 535 | POWERPCMODE="32bits" |
a4adb608 MN |
536 | if test $tune != "generic"; then |
537 | case $tune in | |
538 | 601|ppc601|PowerPC601) | |
539 | CFLAGS="$CFLAGS -mcpu=601" | |
540 | if test $altivec = "yes"; then | |
541 | echo "WARNING: tuning for PPC601 but altivec enabled !"; | |
542 | fi | |
543 | TUNECPU=ppc601 | |
544 | ;; | |
545 | 603*|ppc603*|PowerPC603*) | |
546 | CFLAGS="$CFLAGS -mcpu=603" | |
547 | if test $altivec = "yes"; then | |
548 | echo "WARNING: tuning for PPC603 but altivec enabled !"; | |
549 | fi | |
550 | TUNECPU=ppc603 | |
551 | ;; | |
552 | 604*|ppc604*|PowerPC604*) | |
553 | CFLAGS="$CFLAGS -mcpu=604" | |
554 | if test $altivec = "yes"; then | |
555 | echo "WARNING: tuning for PPC604 but altivec enabled !"; | |
556 | fi | |
557 | TUNECPU=ppc604 | |
558 | ;; | |
8d6625b6 | 559 | G3|g3|75*|ppc75*|PowerPC75*) |
fe0f2a97 | 560 | CFLAGS="$CFLAGS -mcpu=750 -mtune=750 -mpowerpc-gfxopt" |
a4adb608 MN |
561 | if test $altivec = "yes"; then |
562 | echo "WARNING: tuning for PPC75x but altivec enabled !"; | |
563 | fi | |
564 | TUNECPU=ppc750 | |
565 | ;; | |
8d6625b6 | 566 | G4|g4|745*|ppc745*|PowerPC745*) |
fe0f2a97 | 567 | CFLAGS="$CFLAGS -mcpu=7450 -mtune=7450 -mpowerpc-gfxopt" |
3efd4952 RD |
568 | if test $altivec = "no"; then |
569 | echo "WARNING: tuning for PPC745x but altivec disabled !"; | |
570 | fi | |
571 | TUNECPU=ppc7450 | |
572 | ;; | |
573 | 74*|ppc74*|PowerPC74*) | |
fe0f2a97 | 574 | CFLAGS="$CFLAGS -mcpu=7400 -mtune=7400 -mpowerpc-gfxopt" |
a4adb608 MN |
575 | if test $altivec = "no"; then |
576 | echo "WARNING: tuning for PPC74xx but altivec disabled !"; | |
577 | fi | |
e45a2872 | 578 | TUNECPU=ppc7400 |
a4adb608 | 579 | ;; |
8d6625b6 | 580 | G5|g5|970|ppc970|PowerPC970|power4*|Power4*) |
9007f514 | 581 | CFLAGS="$CFLAGS -mcpu=970 -mtune=970 -mpowerpc-gfxopt -mpowerpc64" |
a4adb608 MN |
582 | if test $altivec = "no"; then |
583 | echo "WARNING: tuning for PPC970 but altivec disabled !"; | |
584 | fi | |
585 | TUNECPU=ppc970 | |
9007f514 | 586 | POWERPCMODE="64bits" |
a4adb608 MN |
587 | ;; |
588 | *) | |
589 | echo "WARNING: unknown CPU "$tune", ignored" | |
590 | ;; | |
591 | esac | |
592 | fi | |
593 | ||
cf9d24ad | 594 | # AltiVec flags: The FSF version of GCC differs from the Apple version |
b6e52719 MD |
595 | if test $cpu = "powerpc"; then |
596 | if test $altivec = "yes"; then | |
b2924696 | 597 | if test -n "`$cc -v 2>&1 | grep version | grep Apple`"; then |
b6e52719 MD |
598 | CFLAGS="$CFLAGS -faltivec" |
599 | else | |
600 | CFLAGS="$CFLAGS -maltivec -mabi=altivec" | |
601 | fi | |
602 | fi | |
603 | fi | |
604 | ||
a9a07762 MN |
605 | # See if we have <altivec.h> |
606 | cat > $TMPC << EOF | |
607 | #include <altivec.h> | |
608 | int main( void ) { return 0; } | |
609 | EOF | |
610 | ||
611 | _altivec_h="no" | |
b6e52719 | 612 | if $cc $CFLAGS -o $TMPE $TMPC 2> /dev/null ; then |
a9a07762 MN |
613 | _altivec_h="yes" |
614 | fi | |
615 | ||
ab6c65f6 BF |
616 | # See does our compiler support Motorola AltiVec C API |
617 | if test $altivec = "yes"; then | |
a9a07762 | 618 | if test $_altivec_h = "yes"; then |
ab6c65f6 | 619 | cat > $TMPC << EOF |
a9a07762 | 620 | #include <altivec.h> |
ab6c65f6 BF |
621 | int main(void) { |
622 | vector signed int v1, v2, v3; | |
623 | v1 = vec_add(v2,v3); | |
624 | return 0; | |
625 | } | |
626 | EOF | |
a9a07762 MN |
627 | else |
628 | cat > $TMPC << EOF | |
629 | int main(void) { | |
630 | vector signed int v1, v2, v3; | |
631 | v1 = vec_add(v2,v3); | |
632 | return 0; | |
633 | } | |
634 | EOF | |
635 | fi | |
b6e52719 | 636 | $cc $CFLAGS -o $TMPE $TMPC 2> /dev/null || altivec="no" |
ab6c65f6 BF |
637 | fi |
638 | ||
d46aba26 LS |
639 | # Can only do mmi on mips |
640 | if test $mmi = "default"; then | |
641 | if test $cpu = "mips"; then | |
642 | mmi="yes" | |
643 | else | |
644 | mmi="no" | |
645 | fi | |
646 | fi | |
647 | ||
648 | # See does our compiler support mmi | |
649 | if test $mmi = "yes"; then | |
650 | cat > $TMPC << EOF | |
651 | int main(void) { | |
652 | __asm__ ("lq \$2, 0(\$2)"); | |
653 | return 0; | |
654 | } | |
655 | EOF | |
f3ec2d46 | 656 | $cc -o $TMPE $TMPC 2> /dev/null || mmi="no" |
d46aba26 LS |
657 | fi |
658 | ||
732d9245 | 659 | if test "$mingw32" = "yes" ; then |
732d9245 BE |
660 | v4l="no" |
661 | audio_oss="no" | |
8aa3ee32 | 662 | dv1394="no" |
951bf3e6 | 663 | ffserver="no" |
732d9245 | 664 | network="no" |
951bf3e6 FB |
665 | LIBPREF="" |
666 | LIBSUF=".lib" | |
667 | SLIBPREF="" | |
668 | SLIBSUF=".dll" | |
669 | EXESUF=".exe" | |
670 | prefix="/c/Program Files/FFmpeg" | |
671 | bindir="$prefix" | |
732d9245 BE |
672 | fi |
673 | ||
0f3cb305 FB |
674 | cc="${cross_prefix}${cc}" |
675 | ar="${cross_prefix}${ar}" | |
be7109c1 | 676 | ranlib="${cross_prefix}${ranlib}" |
0f3cb305 FB |
677 | strip="${cross_prefix}${strip}" |
678 | ||
487a54d7 FB |
679 | if test -z "$cross_prefix" ; then |
680 | ||
3d204385 | 681 | # --- |
a3999908 MN |
682 | # big/little endian test |
683 | cat > $TMPC << EOF | |
684 | #include <inttypes.h> | |
685 | int main(int argc, char ** argv){ | |
686 | volatile uint32_t i=0x01234567; | |
687 | return (*((uint8_t*)(&i))) == 0x67; | |
688 | } | |
689 | EOF | |
690 | ||
f3ec2d46 SG |
691 | if $cc -o $TMPE $TMPC 2>/dev/null ; then |
692 | $TMPE && bigendian="yes" | |
a3999908 MN |
693 | else |
694 | echo big/little test failed | |
695 | fi | |
696 | ||
487a54d7 FB |
697 | else |
698 | ||
699 | # if cross compiling, cannot launch a program, so make a static guess | |
700 | if test "$cpu" = "powerpc" -o "$cpu" = "mips" ; then | |
701 | bigendian="yes" | |
702 | fi | |
703 | ||
704 | fi | |
705 | ||
a3999908 | 706 | # --- |
7f965c1c CF |
707 | # *inttypes.h* test |
708 | cat > $TMPC << EOF | |
709 | #include <inttypes.h> | |
710 | int main(int argc, char ** argv){ | |
711 | return 0; | |
712 | } | |
713 | EOF | |
714 | ||
715 | $cc -o $TMPE $TMPC 2>/dev/null || inttypes="no" | |
716 | ||
717 | # --- | |
b5c950c4 MN |
718 | # *int_fast* test |
719 | cat > $TMPC << EOF | |
720 | #include <inttypes.h> | |
721 | int main(int argc, char ** argv){ | |
722 | volatile uint_fast64_t i=0x01234567; | |
723 | return 0; | |
724 | } | |
725 | EOF | |
726 | ||
727 | $cc -o $TMPE $TMPC 2>/dev/null || emu_fast_int="yes" | |
728 | ||
729 | # --- | |
3d204385 NK |
730 | # check availability of some header files |
731 | ||
732 | cat > $TMPC << EOF | |
733 | #include <malloc.h> | |
734 | int main( void ) { return 0; } | |
735 | EOF | |
736 | ||
737 | _memalign=no | |
738 | _malloc_h=no | |
f3ec2d46 | 739 | if $cc -o $TMPE $TMPC 2> /dev/null ; then |
3d204385 NK |
740 | _malloc_h=yes |
741 | _memalign=yes | |
742 | # check for memalign - atmos | |
743 | cat > $TMPC << EOF | |
744 | #include <malloc.h> | |
745 | int main ( void ) { | |
746 | char *string = NULL; | |
747 | string = memalign(64, sizeof(char)); | |
748 | return 0; | |
749 | } | |
750 | EOF | |
f3ec2d46 | 751 | $cc -o $TMPE $TMPC 2> /dev/null || _memalign=no |
3d204385 NK |
752 | fi |
753 | ||
68892110 | 754 | cat > $TMPC << EOF |
5e4639e2 GM |
755 | #include <time.h> |
756 | int main( void ) { localtime_r(NULL, NULL); } | |
757 | EOF | |
758 | ||
759 | localtime_r=no | |
760 | if $cc -o $TMPE $TMPC 2> /dev/null ; then | |
761 | localtime_r=yes | |
762 | fi | |
763 | ||
0147f198 FR |
764 | if test "$zlib" = "yes"; then |
765 | # check for zlib - mmu_man | |
766 | cat > $TMPC << EOF | |
767 | #include <zlib.h> | |
768 | int main ( void ) { | |
769 | if (zlibVersion() != ZLIB_VERSION) | |
770 | puts("zlib version differs !!!"); | |
771 | return 1; | |
772 | return 0; | |
773 | } | |
774 | EOF | |
16806499 | 775 | $cc $CFLAGS -o $TMPE $TMPC -lz 2> /dev/null || zlib="no" |
f3ec2d46 | 776 | # $TMPE 2> /dev/null > /dev/null || zlib="no" |
0147f198 FR |
777 | # XXX: more tests needed - runtime test |
778 | fi | |
779 | if test "$zlib" = "yes"; then | |
780 | extralibs="$extralibs -lz" | |
781 | fi | |
782 | ||
95e2ce4a MN |
783 | # test for lrintf in math.h |
784 | cat > $TMPC << EOF | |
785 | #define _ISOC9X_SOURCE 1 | |
786 | #include <math.h> | |
787 | int main( void ) { return (lrintf(3.999f) > 0)?0:1; } | |
788 | EOF | |
789 | ||
790 | have_lrintf="no" | |
f3ec2d46 | 791 | if $cc $extralibs -o $TMPE $TMPC 2> /dev/null ; then |
95e2ce4a | 792 | have_lrintf="yes" |
f3ec2d46 | 793 | $TMPE 2> /dev/null > /dev/null || have_lrintf="no" |
95e2ce4a MN |
794 | fi |
795 | ||
c13e1abd FH |
796 | _restrict= |
797 | for restrict_keyword in restrict __restrict__ __restrict; do | |
798 | echo "void foo(char * $restrict_keyword p);" > $TMPC | |
799 | if $cc -c -o $TMPO $TMPC 2> /dev/null; then | |
800 | _restrict=$restrict_keyword | |
801 | break; | |
802 | fi | |
803 | done | |
804 | ||
52b41d7f FB |
805 | # test gcc version to see if vector builtins can be used |
806 | # currently only used on i386 for MMX builtins | |
807 | cat > $TMPC << EOF | |
808 | int main(void) { | |
809 | #if __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 2) | |
810 | return 0; | |
811 | #else | |
812 | #error no vector builtins | |
813 | #endif | |
814 | } | |
815 | EOF | |
816 | ||
817 | builtin_vector=no | |
818 | if $cc -o $TMPO $TMPC 2> /dev/null ; then | |
819 | builtin_vector=yes | |
a8721c09 FB |
820 | fi |
821 | ||
822 | # dlopen/dlfcn.h probing | |
823 | ||
824 | cat > $TMPC << EOF | |
825 | #include <dlfcn.h> | |
826 | int main( void ) { return (int) dlopen("foo", 0); } | |
827 | EOF | |
828 | ||
829 | ldl=-ldl | |
830 | ||
cf9d24ad | 831 | if $cc -o $TMPE $TMPC -ldl > /dev/null 2>&1 ; then |
a8721c09 FB |
832 | dlfcn=yes |
833 | dlopen=yes | |
834 | fi | |
835 | ||
cf9d24ad | 836 | if $cc -o $TMPE $TMPC > /dev/null 2>&1 ; then |
a8721c09 FB |
837 | dlfcn=yes |
838 | dlopen=yes | |
839 | ldl="" | |
840 | fi | |
841 | ||
842 | cat > $TMPC << EOF | |
843 | int main( void ) { return (int) dlopen("foo", 0); } | |
844 | EOF | |
845 | ||
cf9d24ad | 846 | if $cc -o $TMPE $TMPC -ldl > /dev/null 2>&1 ; then |
a8721c09 FB |
847 | dlopen=yes |
848 | fi | |
849 | ||
cf9d24ad | 850 | if $cc -o $TMPE $TMPC > /dev/null 2>&1 ; then |
a8721c09 FB |
851 | dlopen=yes |
852 | ldl="" | |
853 | fi | |
854 | ||
855 | if test "$vhook" = "default" ; then | |
856 | vhook="$dlopen" | |
857 | fi | |
858 | ||
a86b921c FB |
859 | ########################################## |
860 | # imlib probe | |
861 | ||
a8721c09 FB |
862 | cat > $TMPC << EOF |
863 | #include <X11/Xlib.h> | |
864 | #include <Imlib2.h> | |
865 | int main( void ) { return (int) imlib_load_font("foo"); } | |
866 | EOF | |
867 | ||
868 | imlib2=no | |
7802d373 | 869 | if $cc -o $TMPE $TMPC -lImlib2 -lm > /dev/null 2>&1 ; then |
a8721c09 | 870 | imlib2=yes |
52b41d7f FB |
871 | fi |
872 | ||
a86b921c FB |
873 | ########################################## |
874 | # freetype probe | |
875 | ||
04511d53 PG |
876 | cat > $TMPC << EOF |
877 | #include <ft2build.h> | |
878 | int main( void ) { return (int) FT_Init_FreeType(0); } | |
879 | EOF | |
880 | ||
881 | freetype2=no | |
69db4e10 | 882 | if test "x$targetos" != "xBeOS" && test "$os2" != "yes"; then |
c3f6b472 | 883 | if freetype-config --version >/dev/null 2>&1 ; then |
cf9d24ad | 884 | if $cc -o $TMPE $TMPC `freetype-config --cflags` `freetype-config --libs` > /dev/null 2>&1 ; then |
dee076fc | 885 | freetype2=yes |
04511d53 | 886 | fi |
dee076fc | 887 | fi |
04511d53 PG |
888 | fi |
889 | ||
a86b921c FB |
890 | ########################################## |
891 | # SDL probe | |
892 | ||
893 | cat > $TMPC << EOF | |
894 | #include <SDL.h> | |
31319a8c | 895 | #undef main /* We don't want SDL to override our main() */ |
a86b921c FB |
896 | int main( void ) { return SDL_Init (SDL_INIT_VIDEO); } |
897 | EOF | |
898 | ||
899 | sdl_too_old=no | |
900 | sdl=no | |
c3f6b472 | 901 | if sdl-config --version >/dev/null 2>&1 ; then |
cf9d24ad | 902 | if $cc -o $TMPE `sdl-config --cflags` $TMPC `sdl-config --libs` > /dev/null 2>&1 ; then |
a86b921c FB |
903 | _sdlversion=`sdl-config --version | sed 's/[^0-9]//g'` |
904 | if test "$_sdlversion" -lt 121 ; then | |
905 | sdl_too_old=yes | |
906 | else | |
907 | sdl=yes | |
908 | fi | |
909 | fi | |
c3f6b472 | 910 | fi |
a86b921c | 911 | |
146ea952 NB |
912 | ########################################## |
913 | # texi2html probe | |
914 | ||
915 | texi2html=no | |
916 | if texi2html -version >/dev/null 2>&1; then | |
917 | texi2html=yes | |
918 | fi | |
919 | ||
b2924696 | 920 | case "`$cc -v 2>&1 | grep version`" in |
cf9d24ad DC |
921 | *gcc*) |
922 | CFLAGS="-Wall $CFLAGS" | |
923 | ;; | |
924 | *) | |
925 | ;; | |
926 | esac | |
927 | ||
94a3401e FB |
928 | if test "$sdl" = "no" ; then |
929 | ffplay=no | |
930 | fi | |
931 | ||
cddf3f45 | 932 | if test "$debug" = "yes"; then |
7906085f | 933 | CFLAGS="-g $CFLAGS" |
cddf3f45 GM |
934 | fi |
935 | ||
936 | if test "$optimize" = "small"; then | |
98ca7790 | 937 | # CFLAGS=${CFLAGS//-O3/-Os} |
553a6284 MN |
938 | CFLAGS="$CFLAGS -Os" |
939 | fi | |
940 | ||
cddf3f45 | 941 | if test "$optimize" = "yes"; then |
b2924696 | 942 | if test -n "`$cc -v 2>&1 | grep xlc`"; then |
cf9d24ad DC |
943 | CFLAGS="$CFLAGS -O5" |
944 | LDFLAGS="$LDFLAGS -O5" | |
945 | else | |
7906085f | 946 | CFLAGS="-O3 $CFLAGS" |
cf9d24ad | 947 | fi |
cddf3f45 GM |
948 | fi |
949 | ||
951bf3e6 FB |
950 | if test x"$bindir" = x""; then |
951 | bindir="${prefix}/bin" | |
952 | fi | |
953 | ||
23a65308 FB |
954 | if test x"$mandir" = x""; then |
955 | mandir="${prefix}/man" | |
956 | fi | |
957 | ||
de6d9b64 | 958 | echo "Install prefix $prefix" |
0f3cb305 | 959 | echo "Source path $source_path" |
de6d9b64 | 960 | echo "C compiler $cc" |
4a908fbc | 961 | echo "make $make" |
a4adb608 | 962 | echo "CPU $cpu ($tune)" |
0f3cb305 | 963 | echo "Big Endian $bigendian" |
7f965c1c | 964 | echo "inttypes.h $inttypes" |
b5c950c4 | 965 | echo "broken inttypes.h $emu_fast_int" |
e41e8342 | 966 | if test $cpu = "x86"; then |
de6d9b64 | 967 | echo "MMX enabled $mmx" |
52b41d7f | 968 | echo "Vector Builtins $builtin_vector" |
e41e8342 FB |
969 | fi |
970 | if test $cpu = "mips"; then | |
d46aba26 | 971 | echo "MMI enabled $mmi" |
e41e8342 FB |
972 | fi |
973 | if test $cpu = "powerpc"; then | |
ab6c65f6 | 974 | echo "AltiVec enabled $altivec" |
e41e8342 | 975 | fi |
de6d9b64 | 976 | echo "gprof enabled $gprof" |
0147f198 | 977 | echo "zlib enabled $zlib" |
a6741398 | 978 | echo "mp3lame enabled $mp3lame" |
81e0d0b4 | 979 | echo "vorbis enabled $vorbis" |
445ad18d ZK |
980 | echo "faad enabled $faad" |
981 | echo "faadbin enabled $faadbin" | |
29d48296 | 982 | echo "faac enabled $faac" |
5cbcf02c | 983 | echo "a52 support $a52" |
57514323 | 984 | echo "a52 dlopened $a52bin" |
23c99253 | 985 | echo "dts support $dts" |
bba9b16c | 986 | echo "pp support $pp" |
cddf3f45 GM |
987 | echo "debug symbols $debug" |
988 | echo "optimize $optimize" | |
bba9b16c | 989 | echo "shared pp $shared_pp" |
47930f09 | 990 | echo "Video hooking $vhook" |
a86b921c FB |
991 | echo "SDL support $sdl" |
992 | if test $sdl_too_old = "yes"; then | |
993 | echo "-> Your SDL version is too old - please upgrade to have FFplay/SDL support" | |
994 | fi | |
1d0d55da | 995 | echo "risky / patent encumbered codecs $risky" |
68892110 PG |
996 | |
997 | if test "$vhook" = "yes" ; then | |
47930f09 | 998 | echo "Imlib2 support $imlib2" |
04511d53 | 999 | echo "freetype support $freetype2" |
68892110 | 1000 | fi |
f80f7964 | 1001 | echo "Sun medialib support" $sunmlib |
9c3d33d6 | 1002 | echo "pthreads support" $pthreads |
bc634f6f ZK |
1003 | echo "AMR-NB float support" $amr_nb |
1004 | echo "AMR-NB fixed support" $amr_nb_fixed | |
d663a1fd | 1005 | echo "AMR-WB float support" $amr_wb |
b2e3c528 MN |
1006 | if test "$gpl" = "no" ; then |
1007 | echo "License: LGPL" | |
1008 | else | |
1009 | echo "License: GPL" | |
1010 | fi | |
de6d9b64 | 1011 | |
980fc7b8 | 1012 | echo "Creating config.mak and config.h" |
de6d9b64 | 1013 | |
980fc7b8 | 1014 | echo "# Automatically generated by configure - do not modify" > config.mak |
045ed63f | 1015 | echo "/* Automatically generated by configure - do not modify */" > $TMPH |
de6d9b64 | 1016 | |
980fc7b8 | 1017 | echo "prefix=$prefix" >> config.mak |
951bf3e6 | 1018 | echo "bindir=$bindir" >> config.mak |
23a65308 | 1019 | echo "mandir=$mandir" >> config.mak |
4a908fbc | 1020 | echo "MAKE=$make" >> config.mak |
980fc7b8 FB |
1021 | echo "CC=$cc" >> config.mak |
1022 | echo "AR=$ar" >> config.mak | |
be7109c1 | 1023 | echo "RANLIB=$ranlib" >> config.mak |
0f3cb305 | 1024 | echo "STRIP=$strip" >> config.mak |
75388c74 MN |
1025 | |
1026 | # SHCFLAGS is a copy of CFLAGS without -mdynamic-no-pic. Used when building | |
1027 | # shared modules on OS/X (vhook/Makefile). | |
1028 | SHCFLAGS=$CFLAGS | |
1029 | if test "$needmdynamicnopic" = yes; then | |
1030 | CFLAGS="$CFLAGS -mdynamic-no-pic" | |
1031 | fi | |
1032 | ||
a9b3f630 | 1033 | echo "OPTFLAGS=$CFLAGS" >> config.mak |
75388c74 | 1034 | echo "SHCFLAGS=$SHCFLAGS">>config.mak |
0f3cb305 | 1035 | echo "LDFLAGS=$LDFLAGS" >> config.mak |
4baca069 | 1036 | echo "FFSLDFLAGS=$FFSLDFLAGS" >> config.mak |
e1707f52 | 1037 | echo "SHFLAGS=$SHFLAGS" >> config.mak |
f3ec2d46 SG |
1038 | echo "LIBPREF=$LIBPREF" >> config.mak |
1039 | echo "LIBSUF=$LIBSUF" >> config.mak | |
1040 | echo "SLIBPREF=$SLIBPREF" >> config.mak | |
1041 | echo "SLIBSUF=$SLIBSUF" >> config.mak | |
951bf3e6 | 1042 | echo "EXESUF=$EXESUF" >> config.mak |
6852ac95 | 1043 | echo "TARGET_OS=$TARGET_OS" >> config.mak |
57514323 | 1044 | if test "$cpu" = "x86" ; then |
980fc7b8 | 1045 | echo "TARGET_ARCH_X86=yes" >> config.mak |
045ed63f | 1046 | echo "#define ARCH_X86 1" >> $TMPH |
0f3cb305 | 1047 | elif test "$cpu" = "armv4l" ; then |
6ed7422a | 1048 | echo "TARGET_ARCH_ARMV4L=yes" >> config.mak |
045ed63f | 1049 | echo "#define ARCH_ARMV4L 1" >> $TMPH |
0f3cb305 | 1050 | elif test "$cpu" = "alpha" ; then |
91d1f1a4 | 1051 | echo "TARGET_ARCH_ALPHA=yes" >> config.mak |
045ed63f | 1052 | echo "#define ARCH_ALPHA 1" >> $TMPH |
35fedfc3 PG |
1053 | elif test "$cpu" = "sparc64" ; then |
1054 | echo "TARGET_ARCH_SPARC64=yes" >> config.mak | |
1055 | echo "#define ARCH_SPARC64 1" >> $TMPH | |
bb476ff3 JM |
1056 | echo "TARGET_ARCH_SPARC=yes" >> config.mak |
1057 | echo "#define ARCH_SPARC 1" >> $TMPH | |
1058 | elif test "$cpu" = "sparc" ; then | |
1059 | echo "TARGET_ARCH_SPARC=yes" >> config.mak | |
1060 | echo "#define ARCH_SPARC 1" >> $TMPH | |
0f3cb305 FB |
1061 | elif test "$cpu" = "powerpc" ; then |
1062 | echo "TARGET_ARCH_POWERPC=yes" >> config.mak | |
1063 | echo "#define ARCH_POWERPC 1" >> $TMPH | |
9007f514 RD |
1064 | if test $POWERPCMODE = "32bits"; then |
1065 | echo "#define POWERPC_MODE_32BITS 1" >> $TMPH | |
1066 | else | |
1067 | echo "#define POWERPC_MODE_64BITS 1" >> $TMPH | |
1068 | fi | |
e45a2872 RD |
1069 | if test "$powerpc_perf" = "yes"; then |
1070 | echo "#define POWERPC_PERFORMANCE_REPORT 1" >> $TMPH | |
1071 | fi | |
d46aba26 LS |
1072 | elif test "$cpu" = "mips" ; then |
1073 | echo "TARGET_ARCH_MIPS=yes" >> config.mak | |
1074 | echo "#define ARCH_MIPS 1" >> $TMPH | |
bdb2e37c AB |
1075 | elif test "$cpu" = "sh4" ; then |
1076 | echo "TARGET_ARCH_SH4=yes" >> config.mak | |
1077 | echo "#define ARCH_SH4 1" >> $TMPH | |
1078 | fi | |
a4adb608 | 1079 | echo "#define TUNECPU $TUNECPU" >> $TMPH |
0f3cb305 FB |
1080 | if test "$bigendian" = "yes" ; then |
1081 | echo "WORDS_BIGENDIAN=yes" >> config.mak | |
1082 | echo "#define WORDS_BIGENDIAN 1" >> $TMPH | |
91d1f1a4 | 1083 | fi |
d2a9bddd MN |
1084 | if test "$inttypes" != "yes" ; then |
1085 | echo "#define EMULATE_INTTYPES 1" >> $TMPH | |
7f965c1c | 1086 | fi |
b5c950c4 | 1087 | if test "$emu_fast_int" = "yes" ; then |
19d053c5 | 1088 | echo "#define EMULATE_FAST_INT 1" >> $TMPH |
b5c950c4 | 1089 | fi |
57514323 | 1090 | if test "$mmx" = "yes" ; then |
980fc7b8 | 1091 | echo "TARGET_MMX=yes" >> config.mak |
045ed63f | 1092 | echo "#define HAVE_MMX 1" >> $TMPH |
e82c5a8c | 1093 | echo "#define __CPU__ 586" >> $TMPH |
de6d9b64 | 1094 | fi |
52b41d7f FB |
1095 | if test "$builtin_vector" = "yes" ; then |
1096 | echo "TARGET_BUILTIN_VECTOR=yes" >> config.mak | |
1097 | echo "#define HAVE_BUILTIN_VECTOR 1" >> $TMPH | |
1098 | fi | |
d46aba26 LS |
1099 | if test "$mmi" = "yes" ; then |
1100 | echo "TARGET_MMI=yes" >> config.mak | |
1101 | echo "#define HAVE_MMI 1" >> $TMPH | |
1102 | fi | |
ab6c65f6 BF |
1103 | if test "$altivec" = "yes" ; then |
1104 | echo "TARGET_ALTIVEC=yes" >> config.mak | |
1105 | echo "#define HAVE_ALTIVEC 1" >> $TMPH | |
db40a39a MN |
1106 | echo "// Enable the next line to use the reference C code instead of AltiVec" >> $TMPH |
1107 | echo "// #define ALTIVEC_USE_REFERENCE_C_CODE 1" >> $TMPH | |
a9a07762 MN |
1108 | if test "$_altivec_h" = "yes" ; then |
1109 | echo "#define HAVE_ALTIVEC_H 1" >> $TMPH | |
1110 | else | |
e67e14d5 | 1111 | echo "#undef HAVE_ALTIVEC_H" >> $TMPH |
a9a07762 | 1112 | fi |
ab6c65f6 | 1113 | fi |
57514323 | 1114 | if test "$gprof" = "yes" ; then |
980fc7b8 | 1115 | echo "TARGET_GPROF=yes" >> config.mak |
045ed63f | 1116 | echo "#define HAVE_GPROF 1" >> $TMPH |
de6d9b64 | 1117 | fi |
5e4639e2 GM |
1118 | if test "$localtime_r" = "yes" ; then |
1119 | echo "#define HAVE_LOCALTIME_R 1" >> $TMPH | |
5e4639e2 | 1120 | fi |
68892110 PG |
1121 | if test "$imlib2" = "yes" ; then |
1122 | echo "HAVE_IMLIB2=yes" >> config.mak | |
1123 | fi | |
04511d53 PG |
1124 | if test "$freetype2" = "yes" ; then |
1125 | echo "HAVE_FREETYPE2=yes" >> config.mak | |
1126 | fi | |
f80f7964 RS |
1127 | if test "$sunmlib" = "yes" ; then |
1128 | echo "HAVE_MLIB=yes" >> config.mak | |
1129 | echo "#define HAVE_MLIB 1" >> $TMPH | |
1130 | extralibs="$extralibs -lmlib" | |
1131 | fi | |
9c3d33d6 MN |
1132 | if test "$pthreads" = "yes" ; then |
1133 | echo "HAVE_PTHREADS=yes" >> config.mak | |
1134 | echo "#define HAVE_PTHREADS 1" >> $TMPH | |
0abd6916 | 1135 | if test $targetos != FreeBSD; then |
12043e1d SS |
1136 | extralibs="$extralibs -lpthread" |
1137 | fi | |
9c3d33d6 | 1138 | fi |
a86b921c FB |
1139 | if test "$sdl" = "yes" ; then |
1140 | echo "CONFIG_SDL=yes" >> config.mak | |
1141 | echo "SDL_LIBS=`sdl-config --libs`" >> config.mak | |
1142 | echo "SDL_CFLAGS=`sdl-config --cflags`" >> config.mak | |
1143 | fi | |
146ea952 NB |
1144 | if test "$texi2html" = "yes"; then |
1145 | echo "BUILD_DOC=yes" >> config.mak | |
1146 | fi | |
95e2ce4a MN |
1147 | if test "$have_lrintf" = "yes" ; then |
1148 | echo "#define HAVE_LRINTF 1" >> $TMPH | |
1149 | fi | |
68892110 PG |
1150 | if test "$vhook" = "yes" ; then |
1151 | echo "BUILD_VHOOK=yes" >> config.mak | |
1152 | echo "#define HAVE_VHOOK 1" >> $TMPH | |
9c938e77 | 1153 | extralibs="$extralibs $ldl" |
68892110 | 1154 | fi |
57514323 | 1155 | if test "$lshared" = "yes" ; then |
0319c531 | 1156 | echo "BUILD_SHARED=yes" >> config.mak |
5cbcf02c | 1157 | echo "PIC=-fPIC" >> config.mak |
0319c531 | 1158 | fi |
ef0bc4c9 | 1159 | echo "EXTRALIBS=$extralibs" >> config.mak |
258207b7 FB |
1160 | version=`grep '#define FFMPEG_VERSION ' $source_path/libavcodec/avcodec.h | |
1161 | cut -d '"' -f 2` | |
1162 | echo "VERSION=$version" >>config.mak | |
d771bcae | 1163 | # if you do not want to use encoders, disable that. |
045ed63f | 1164 | echo "#define CONFIG_ENCODERS 1" >> $TMPH |
d771bcae FB |
1165 | echo "CONFIG_ENCODERS=yes" >> config.mak |
1166 | ||
1167 | # if you do not want to use decoders, disable that. | |
045ed63f | 1168 | echo "#define CONFIG_DECODERS 1" >> $TMPH |
d771bcae FB |
1169 | echo "CONFIG_DECODERS=yes" >> config.mak |
1170 | ||
5cbcf02c FB |
1171 | # AC3 |
1172 | if test "$a52" = "yes" ; then | |
1173 | echo "#define CONFIG_AC3 1" >> $TMPH | |
1174 | echo "CONFIG_AC3=yes" >> config.mak | |
d771bcae | 1175 | |
5cbcf02c FB |
1176 | if test "$a52bin" = "yes" ; then |
1177 | echo "#define CONFIG_A52BIN 1" >> $TMPH | |
1178 | echo "CONFIG_A52BIN=yes" >> config.mak | |
1179 | fi | |
1180 | fi | |
1181 | ||
23c99253 MN |
1182 | # DTS |
1183 | if test "$dts" = "yes" ; then | |
1184 | echo "#define CONFIG_DTS 1" >> $TMPH | |
1185 | echo "CONFIG_DTS=yes" >> config.mak | |
1186 | fi | |
1187 | ||
bba9b16c MN |
1188 | # PP |
1189 | if test "$pp" = "yes" ; then | |
1190 | echo "#define CONFIG_PP 1" >> $TMPH | |
1191 | echo "CONFIG_PP=yes" >> config.mak | |
1192 | ||
1193 | if test "$shared_pp" = "yes" ; then | |
1194 | echo "#define SHARED_PP 1" >> $TMPH | |
1195 | echo "SHARED_PP=yes" >> config.mak | |
1196 | fi | |
1197 | fi | |
1198 | ||
1eb2212e FB |
1199 | # mpeg audio high precision mode |
1200 | if test "$mpegaudio_hp" = "yes" ; then | |
1201 | echo "#define CONFIG_MPEGAUDIO_HP 1" >> $TMPH | |
1202 | fi | |
1203 | ||
5cbcf02c FB |
1204 | if test "$v4l" = "yes" ; then |
1205 | echo "#define CONFIG_VIDEO4LINUX 1" >> $TMPH | |
1206 | echo "CONFIG_VIDEO4LINUX=yes" >> config.mak | |
1207 | fi | |
1208 | ||
8aa3ee32 MK |
1209 | if test "$dv1394" = "yes" ; then |
1210 | echo "#define CONFIG_DV1394 1" >> $TMPH | |
1211 | echo "CONFIG_DV1394=yes" >> config.mak | |
1212 | fi | |
1213 | ||
adbc0510 PG |
1214 | if test "$dlopen" = "yes" ; then |
1215 | echo "#define CONFIG_HAVE_DLOPEN 1" >> $TMPH | |
1216 | fi | |
1217 | ||
1218 | if test "$dlfcn" = "yes" ; then | |
1219 | echo "#define CONFIG_HAVE_DLFCN 1" >> $TMPH | |
1220 | fi | |
1221 | ||
5cbcf02c FB |
1222 | if test "$audio_oss" = "yes" ; then |
1223 | echo "#define CONFIG_AUDIO_OSS 1" >> $TMPH | |
1224 | echo "CONFIG_AUDIO_OSS=yes" >> config.mak | |
57514323 ZK |
1225 | fi |
1226 | ||
dfdfa47c FR |
1227 | if test "$audio_beos" = "yes" ; then |
1228 | echo "#define CONFIG_AUDIO_BEOS 1" >> $TMPH | |
1229 | echo "CONFIG_AUDIO_BEOS=yes" >> config.mak | |
1230 | fi | |
1231 | ||
5cbcf02c FB |
1232 | if test "$network" = "yes" ; then |
1233 | echo "#define CONFIG_NETWORK 1" >> $TMPH | |
1234 | echo "CONFIG_NETWORK=yes" >> config.mak | |
6ed7422a | 1235 | fi |
daf8e955 | 1236 | |
0147f198 FR |
1237 | if test "$zlib" = "yes" ; then |
1238 | echo "#define CONFIG_ZLIB 1" >> $TMPH | |
1239 | echo "CONFIG_ZLIB=yes" >> config.mak | |
1240 | fi | |
1241 | ||
57514323 | 1242 | if test "$mp3lame" = "yes" ; then |
045ed63f | 1243 | echo "#define CONFIG_MP3LAME 1" >> $TMPH |
a6741398 J |
1244 | echo "CONFIG_MP3LAME=yes" >> config.mak |
1245 | fi | |
1246 | ||
81e0d0b4 MH |
1247 | if test "$vorbis" = "yes" ; then |
1248 | echo "#define CONFIG_VORBIS 1" >> $TMPH | |
1249 | echo "CONFIG_VORBIS=yes" >> config.mak | |
1250 | fi | |
1251 | ||
0fc50e58 ZK |
1252 | if test "$faad" = "yes" ; then |
1253 | echo "#define CONFIG_FAAD 1" >> $TMPH | |
1254 | echo "CONFIG_FAAD=yes" >> config.mak | |
1255 | fi | |
1256 | ||
1257 | if test "$faadbin" = "yes" ; then | |
1258 | echo "#define CONFIG_FAADBIN 1" >> $TMPH | |
445ad18d | 1259 | echo "CONFIG_FAADBIN=yes" >> config.mak |
0fc50e58 ZK |
1260 | fi |
1261 | ||
29d48296 MN |
1262 | if test "$faac" = "yes" ; then |
1263 | echo "#define CONFIG_FAAC 1" >> $TMPH | |
1264 | echo "CONFIG_FAAC=yes" >> config.mak | |
1265 | fi | |
1266 | ||
732d9245 BE |
1267 | if test "$mingw32" = "yes" ; then |
1268 | echo "#define CONFIG_WIN32 1" >> $TMPH | |
1269 | echo "CONFIG_WIN32=yes" >> config.mak | |
16806499 MN |
1270 | echo "HAVE_W32THREADS=yes" >> config.mak |
1271 | echo "#define HAVE_W32THREADS 1" >> $TMPH | |
7eea5766 | 1272 | echo "#ifndef __MINGW32__" >> $TMPH |
732d9245 | 1273 | echo "#define __MINGW32__ 1" >> $TMPH |
7eea5766 | 1274 | echo "#endif" >> $TMPH |
3f027ca7 FB |
1275 | fi |
1276 | ||
f3ec2d46 SG |
1277 | if test "$os2" = "yes" ; then |
1278 | echo "#define CONFIG_OS2 1" >> $TMPH | |
1279 | echo "CONFIG_OS2=yes" >> config.mak | |
1280 | fi | |
1281 | ||
6e023978 RS |
1282 | if test "$TARGET_OS" = "SunOS" ; then |
1283 | echo "#define CONFIG_SUNOS 1" >> $TMPH | |
1284 | fi | |
1285 | ||
90cee0c3 MN |
1286 | if test "$darwin" = "yes"; then |
1287 | echo "#define CONFIG_DARWIN 1" >> $TMPH | |
1288 | echo "CONFIG_DARWIN=yes" >> config.mak | |
1289 | fi | |
1290 | ||
57514323 | 1291 | if test "$_malloc_h" = "yes" ; then |
045ed63f | 1292 | echo "#define HAVE_MALLOC_H 1" >> $TMPH |
3d204385 | 1293 | else |
045ed63f | 1294 | echo "#undef HAVE_MALLOC_H" >> $TMPH |
3d204385 NK |
1295 | fi |
1296 | ||
57514323 | 1297 | if test "$_memalign" = "yes" ; then |
045ed63f ZK |
1298 | echo "#define HAVE_MEMALIGN 1" >> $TMPH |
1299 | else | |
1300 | echo "#undef HAVE_MEMALIGN" >> $TMPH | |
1301 | fi | |
1302 | ||
da9b170c MN |
1303 | if test "$memalignhack" = "yes" ; then |
1304 | echo "#define MEMALIGN_HACK 1" >> $TMPH | |
1305 | fi | |
1306 | ||
1307 | ||
26b35efb FR |
1308 | if test "$netserver" = "yes" ; then |
1309 | echo "#define CONFIG_BEOS_NETSERVER 1" >> $TMPH | |
1310 | echo "CONFIG_BEOS_NETSERVER=yes" >> config.mak | |
1311 | fi | |
1312 | ||
4baca069 PG |
1313 | if test "$need_inet_aton" = "yes" ; then |
1314 | echo "NEED_INET_ATON=yes" >> config.mak | |
1315 | fi | |
1316 | ||
57514323 | 1317 | if test "$simpleidct" = "yes" ; then |
045ed63f ZK |
1318 | echo "#define SIMPLE_IDCT 1" >> $TMPH |
1319 | fi | |
1320 | ||
8154d2e0 FB |
1321 | if test "$ffserver" = "yes" ; then |
1322 | echo "#define CONFIG_FFSERVER 1" >> $TMPH | |
1323 | echo "CONFIG_FFSERVER=yes" >> config.mak | |
1324 | fi | |
1325 | ||
a86b921c FB |
1326 | if test "$ffplay" = "yes" ; then |
1327 | echo "CONFIG_FFPLAY=yes" >> config.mak | |
1328 | fi | |
1329 | ||
1d0d55da MN |
1330 | if test "$risky" = "yes" ; then |
1331 | echo "#define CONFIG_RISKY 1" >> $TMPH | |
1332 | echo "CONFIG_RISKY=yes" >> config.mak | |
1333 | fi | |
1334 | ||
b2e3c528 MN |
1335 | if test "$gpl" = "yes" ; then |
1336 | echo "#define CONFIG_GPL 1" >> $TMPH | |
1337 | echo "CONFIG_GPL=yes" >> config.mak | |
1338 | fi | |
1339 | ||
c13e1abd FH |
1340 | echo "#define restrict $_restrict" >> $TMPH |
1341 | ||
bb801c97 MN |
1342 | if test "$optimize" = "small"; then |
1343 | echo "#define always_inline" >> $TMPH | |
1344 | fi | |
1345 | ||
0f3cb305 FB |
1346 | # build tree in object directory if source path is different from current one |
1347 | if test "$source_path_used" = "yes" ; then | |
a382b927 | 1348 | DIRS="libavformat libavcodec libavcodec/alpha libavcodec/armv4l libavcodec/i386 \ |
5f6b58de MR |
1349 | libavcodec/ppc libavcodec/liba52 libavcodec/mlib libavcodec/libpostproc tests vhook" |
1350 | FILES="Makefile libavformat/Makefile libavcodec/Makefile libavcodec/libpostproc/Makefile tests/Makefile vhook/Makefile" | |
0f3cb305 FB |
1351 | for dir in $DIRS ; do |
1352 | mkdir -p $dir | |
1353 | done | |
1354 | for f in $FILES ; do | |
1355 | ln -sf $source_path/$f $f | |
1356 | done | |
1357 | fi | |
1358 | echo "SRC_PATH=$source_path" >> config.mak | |
1359 | ||
d663a1fd MN |
1360 | if test "$amr_wb" = "yes" ; then |
1361 | echo "#define AMR_WB 1" >> $TMPH | |
1362 | echo "AMR_WB=yes" >> config.mak | |
1363 | echo | |
1364 | echo "AMR WB FLOAT NOTICE ! Make sure you have downloaded TS26.204" | |
1365 | echo "V5.1.0 from " | |
1366 | echo "http://www.3gpp.org/ftp/Specs/archive/26_series/26.204/26204-510.zip" | |
1367 | echo "and extracted the source to libavcodec/amrwb_float" | |
1368 | echo | |
1369 | fi | |
1370 | ||
891f64b3 | 1371 | if test "$amr_nb" = "yes" ; then |
1372 | echo "#define AMR_NB 1" >> $TMPH | |
1373 | echo "AMR_NB=yes" >> config.mak | |
1374 | echo | |
bc634f6f ZK |
1375 | if test "$amr_nb_fixed" = "yes" ; then |
1376 | echo "AMR_NB_FIXED=yes" >> config.mak | |
1377 | echo "#define AMR_NB_FIXED 1" >> $TMPH | |
1378 | echo "AMR NB FIXED POINT NOTICE! Make sure you have downloaded TS26.073 " | |
1379 | echo "REL-5 version 5.1.0 from " | |
891f64b3 | 1380 | echo "http://www.3gpp.org/ftp/Specs/latest/Rel-5/26_series/26073-510.zip" |
1381 | echo "and extracted src to libavcodec/amr" | |
bc634f6f ZK |
1382 | echo "You must also add -DMMS_IO and remove -pedantic-errors to/from CFLAGS in libavcodec/amr/makefile." |
1383 | echo "i.e. CFLAGS = -Wall -I. \$(CFLAGS_\$(MODE)) -D\$(VAD) -DMMS_IO" | |
1384 | echo | |
1385 | else | |
1386 | echo "AMR NB FLOAT NOTICE ! Make sure you have downloaded TS26.104" | |
1387 | echo "REL-5 V5.1.0 from " | |
1388 | echo "http://www.3gpp.org/ftp/Specs/latest/Rel-5/26_series/26104-510.zip" | |
1389 | echo "and extracted the source to libavcodec/amr_float" | |
821e46f4 | 1390 | echo "and if u try this on an alpha, u may need to change Word32 to int in amr/typedef.h" |
891f64b3 | 1391 | echo |
1392 | fi | |
1393 | ||
bc634f6f ZK |
1394 | fi |
1395 | ||
a7c02e25 | 1396 | diff $TMPH config.h >/dev/null 2>&1 |
045ed63f ZK |
1397 | if test $? -ne 0 ; then |
1398 | mv -f $TMPH config.h | |
3d204385 | 1399 | else |
045ed63f | 1400 | echo "config.h is unchanged" |
3d204385 NK |
1401 | fi |
1402 | ||
f3ec2d46 | 1403 | rm -f $TMPO $TMPC $TMPE $TMPS $TMPH |