[MPlayer-dev-eng] [PATCH] make configure use the right faad.h

jb13 jb13 at gomerbud.com
Thu Sep 25 21:39:50 CEST 2003


this patch make's configure use the internal faad.h if their, else the system
one, and it fixes the sed command, it would always return 1n, where n is the
minor number
-------------- next part --------------
--- configure-old	Thu Sep 25 11:29:46 2003
+++ configure	Thu Sep 25 11:45:32 2003
@@ -4360,14 +4360,26 @@
   return 0;
 }
 EOF
-  if cc_check $_inc_faad $_ld_faad -lm && "$TMPO" >> "$TMPLOG" ; then
-    _faad_version=`"$TMPO"`
-    _faad_tempversion=`"$TMPO" | sed -e 's/^\([0-9]\{1,\}\)\.\([0-9]\{1,\}\).*/\1\2/'`
-    _def_faad_version="#define FAADVERSION $_faad_tempversion"
-    echores "$_faad_version"
+  if test "$_faad_local" = no ; then
+    if cc_check $_inc_faad $_ld_faad -lm && "$TMPO" >> "$TMPLOG" ; then
+      _faad_version=`"$TMPO"`
+      _faad_tempversion=`"$TMPO" | sed -e 's/\.//' -e 's/ .*//'`
+      _def_faad_version="#define FAADVERSION $_faad_tempversion"
+      echores "$_faad_version"
+    else
+      _faad=no
+      echores "failed to get version"
+    fi
   else
-    _faad=no
-    echores "failed to get version"
+    if cc_check -I- $_inc_faad && "$TMPO" >> "$TMPLOG" ; then
+      _faad_version=`"$TMPO"`
+      _faad_tempversion=`"$TMPO" | sed -e 's/\.//' -e 's/ .*//'`
+      _def_faad_version="#define FAADVERSION $_faad_tempversion"
+      echores "$_faad_version"
+    else
+      _faad=no
+      echores "failed to get version"
+    fi
   fi
 fi
 


More information about the MPlayer-dev-eng mailing list