3 if test x"$1" = x"-h" -o x"$1" = x"--help" ; then
5 echo "Usage: ./configure [options]"
7 echo "available options:"
9 echo " --help print this message"
10 echo " --enable-avis-input enables avisynth input (win32 only)"
11 echo " --enable-mp4-output enables mp4 output (using gpac)"
12 echo " --extra-cflags=ECFLAGS add ECFLAGS to CFLAGS"
13 echo " --extra-ldflags=ELDFLAGS add ELDFLAGS to LDFLAGS"
14 echo " --enable-debug adds -g, doesn't strip"
24 CFLAGS="-Wall -I. -O4 -funroll-loops -D__X264__"
34 CFLAGS="$CFLAGS -DHAVE_MALLOC_H"
38 LDFLAGS="$LDFLAGS -lm -lmx"
42 LDFLAGS="$LDFLAGS -lm"
46 CFLAGS="$CFLAGS -DHAVE_MALLOC_H"
47 LDFLAGS="$LDFLAGS -lm"
51 CFLAGS="$CFLAGS -mno-cygwin"
52 LDFLAGS="$LDFLAGS -mno-cygwin"
53 ASFLAGS="-f win32 -DPREFIX"
57 ASFLAGS="-f win32 -DPREFIX"
60 echo "Unknown system $UNAMES, edit the configure"
67 i386|i486|i586|i686|BePC)
69 CFLAGS="$CFLAGS -DHAVE_MMXEXT -DHAVE_SSE2"
74 "Power Macintosh"|ppc)
78 CFLAGS="$CFLAGS -faltivec"
80 CFLAGS="$CFLAGS -maltivec -mabi=altivec"
84 echo "Unknown platform $UNAMEM, edit the configure"
89 CFLAGS="$CFLAGS -DARCH_$ARCH -DSYS_$SYS"
96 if [ $SYS = CYGWIN -o $SYS = MINGW ]; then
97 CFLAGS="$CFLAGS -DAVIS_INPUT"
98 LDFLAGS="$LDFLAGS -lvfw32"
103 CFLAGS="$CFLAGS -DMP4_OUTPUT"
104 LDFLAGS="$LDFLAGS -lm4systems_static"
105 if [ $SYS = CYGWIN -o $SYS = MINGW ]; then
106 LDFLAGS="$LDFLAGS -lwinmm"
110 --extra-cflags=*) CFLAGS="$CFLAGS ${opt#--extra-cflags=}"
112 --extra-ldflags=*) LDFLAGS="$LDFLAGS ${opt#--extra-ldflags=}"
119 echo "Unknown option $opt, ignored"
124 if [ "$debug" != "yes" ]; then
129 cat > config.mak << EOF
139 echo "Platform: $ARCH"
141 echo "avis input: $avis_input"
142 echo "mp4 output: $mp4_output"
145 echo "You can run 'make' now."