From: Loren Merritt Date: Tue, 12 Apr 2005 17:33:10 +0000 (+0000) Subject: Configure tweaks. Allow avis-input in mingw. Turn off debug by default. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a1b9531707b835e6934cadfb78249149f6351d7e;p=libx264 Configure tweaks. Allow avis-input in mingw. Turn off debug by default. git-svn-id: svn://svn.videolan.org/x264/trunk@198 df754926-b1dd-0310-bc7b-ec298dee348c --- diff --git a/configure b/configure index 74f06b27..f7bb9ce6 100755 --- a/configure +++ b/configure @@ -7,19 +7,21 @@ echo "" echo "available options:" echo "" echo " --help print this message" -echo " --enable-avis-input enables avisynth input (cygwin only)" +echo " --enable-avis-input enables avisynth input (win32 only)" echo " --enable-mp4-output enables mp4 output (using gpac)" echo " --extra-cflags=ECFLAGS add ECFLAGS to CFLAGS" echo " --extra-ldflags=ELDFLAGS add ELDFLAGS to LDFLAGS" +echo " --enable-debug adds -g, doesn't strip" echo "" exit 1 fi -avis_input="off" -mp4_output="off" +avis_input="no" +mp4_output="no" +debug="no" CC="gcc" -CFLAGS="-g -Wall -I. -O4 -funroll-loops -D__X264__" +CFLAGS="-Wall -I. -O4 -funroll-loops -D__X264__" LDFLAGS="" AS="nasm" @@ -50,8 +52,8 @@ case "$UNAMES" in LDFLAGS="$LDFLAGS -mno-cygwin" ASFLAGS="-f win32 -DPREFIX" ;; - MINGW32*) - SYS="MINGW32" + MINGW*) + SYS="MINGW" ASFLAGS="-f win32 -DPREFIX" ;; *) @@ -91,10 +93,10 @@ CFLAGS="$CFLAGS -DARCH_$ARCH -DSYS_$SYS" for opt do case "$opt" in --enable-avis-input) - if [ $SYS = CYGWIN ]; then + if [ $SYS = CYGWIN -o $SYS = MINGW ]; then CFLAGS="$CFLAGS -DAVIS_INPUT" LDFLAGS="$LDFLAGS -lvfw32" - avis_input="on" + avis_input="yes" fi ;; --enable-mp4-output) @@ -103,18 +105,26 @@ for opt do if [ $SYS = CYGWIN -o $SYS = MINGW ]; then LDFLAGS="$LDFLAGS -lwinmm" fi - mp4_output="on" + mp4_output="yes" ;; --extra-cflags=*) CFLAGS="$CFLAGS ${opt#--extra-cflags=}" ;; --extra-ldflags=*) LDFLAGS="$LDFLAGS ${opt#--extra-ldflags=}" ;; + --enable-debug) + CFLAGS="$CFLAGS -g" + debug="yes" + ;; *) echo "Unknown option $opt, ignored" ;; esac done +if [ "$debug" != "yes" ]; then + CFLAGS="$CFLAGS -s" +fi + rm -f config.mak cat > config.mak << EOF ARCH=$ARCH @@ -130,6 +140,7 @@ echo "Platform: $ARCH" echo "System: $SYS" echo "avis input: $avis_input" echo "mp4 output: $mp4_output" +echo "debug: $debug" echo echo "You can run 'make' now."