[Mplayer-cvslog] CVS: main configure,1.555,1.556

Atmosfear atmos4 at mplayerhq.hu
Mon Sep 2 20:43:21 CEST 2002


Update of /cvsroot/mplayer/main
In directory mail:/var/tmp.root/cvs-serv19813

Modified Files:
	configure 
Log Message:
allow to specify freetype-config and restrict to freetype 2.1.x+


Index: configure
===================================================================
RCS file: /cvsroot/mplayer/main/configure,v
retrieving revision 1.555
retrieving revision 1.556
diff -u -r1.555 -r1.556
--- configure	1 Sep 2002 23:26:37 -0000	1.555
+++ configure	2 Sep 2002 18:43:01 -0000	1.556
@@ -247,10 +247,12 @@
   --with-reallibdir=DIR    RealPlayer DLL files in DIR
   --with-xvidcore=PATH     path to XviD libcore.a (e.g. /opt/lib/libcore.a)
   --with-sdl-config=PATH   path to sdl*-config (e.g. /opt/bin/sdl-config)
+  --with-freetype-config=PATH  path to freetype-config
+                           (e.g. /opt/bin/freetype-config)
   --with-gtk-config=PATH   path to gtk*-config (e.g. /opt/bin/gtk-config)
   --with-glib-config=PATH  path to glib*-config (e.g. /opt/bin/glib-config)
   --with-dvdnav-config=PATH  path to dvdnav-config
-  --with-livelibdir=DIR       path to LIVE.COM Streaming Media libraries
+  --with-livelibdir=DIR    path to LIVE.COM Streaming Media libraries
 
 EOF
     exit 0
@@ -1232,6 +1234,9 @@
   --with-sdl-config=*)
     _sdlconfig=`echo $ac_option | cut -d '=' -f 2`
     ;;
+  --with-freetype-config=*)
+    _freetypeconfig=`echo $ac_option | cut -d '=' -f 2`
+    ;;
   --with-gtk-config=*)
     _gtkconfig=`echo $ac_option | cut -d '=' -f 2`
     ;;
@@ -3239,14 +3244,15 @@
 fi
 echores "$_cdparanoia"
 
-echocheck "freetype 2"
+echocheck "freetype >= 2.1"
 if test "$_freetype" = yes ; then
-    if ( freetype-config --version ) >/dev/null 2>&1 ; then
+    test -z "$_freetypeconfig" && _freetypeconfig='freetype-config'
+    if ( $_freetypeconfig --version ) >/dev/null 2>&1 ; then
 	cat > $TMPC << EOF
 #include <stdio.h>
 #include <freetype/freetype.h>
-#if !(FREETYPE_MAJOR >= 2)
-#error "Need FreeType 2.0 or newer"
+#if !((FREETYPE_MAJOR >= 2) && (FREETYPE_MINOR >= 1))
+#error "Need FreeType 2.1 or newer"
 #endif
 int main()
 {
@@ -3257,7 +3263,6 @@
 	printf("Couldn't initialize freetype2 lib, err code: %d\n",err);
 	exit(err);
     }
-#if (FREETYPE_MINOR >= 1)
     FT_Library_Version(library,&major,&minor,&patch); // in v2.1.0+ only :(((
     printf("freetype2  header version: %d.%d.%d  library version: %d.%d.%d\n",
 	FREETYPE_MAJOR,FREETYPE_MINOR,FREETYPE_PATCH,
@@ -3266,20 +3271,19 @@
 	printf("Library and header version mismatch! Fix it in your distribution!\n");
 	exit(1);
     }
-#endif
     return 0;
 }
 EOF
 	_freetype=no
-	cc_check `freetype-config --cflags` `freetype-config --libs` && ( $TMPO >> "$TMPLOG" ) && _freetype=yes
+	cc_check `$_freetypeconfig --cflags` `$_freetypeconfig --libs` && ( $TMPO >> "$TMPLOG" ) && _freetype=yes
     else
 	_freetype=no
     fi
 fi
 if test "$_freetype" = yes ; then
     _def_freetype='#define HAVE_FREETYPE'
-    _inc_freetype=`freetype-config --cflags`
-    _ld_freetype=`freetype-config --libs`
+    _inc_freetype=`$_freetypeconfig --cflags`
+    _ld_freetype=`$_freetypeconfig --libs`
 else
     _def_freetype='#undef HAVE_FREETYPE'
 fi




More information about the MPlayer-cvslog mailing list