[MPlayer-cvslog] r20663 - trunk/configure

reimar subversion at mplayerhq.hu
Sat Nov 4 12:57:03 CET 2006


Author: reimar
Date: Sat Nov  4 12:57:03 2006
New Revision: 20663

Modified:
   trunk/configure

Log:
Extended/reworked fontconfig test to work without pkg-config with versions
that need -lz


Modified: trunk/configure
==============================================================================
--- trunk/configure	(original)
+++ trunk/configure	Sat Nov  4 12:57:03 2006
@@ -5403,16 +5403,16 @@
     
 }
 EOF
-  _fontconfig=yes
-  if cc_check -lfontconfig ; then
-    _ld_fontconfig="-lfontconfig"
-  elif cc_check -lfontconfig -lexpat -lfreetype ; then
-    _ld_fontconfig="-lfontconfig -lexpat -lfreetype"
-  elif cc_check `$_pkg_config --silence-errors --cflags --libs fontconfig` ; then
-    _inc_extra="$_inc_extra `$_pkg_config --cflags fontconfig`"
-    _ld_fontconfig=`$_pkg_config --libs fontconfig`
-  else
-    _fontconfig=no
+  _fontconfig=no
+  for _ld_tmp in "" "-lexpat -lfreetype" "-lexpat -lfreetype -lz" ; do
+    _ld_tmp="-lfontconfig $_ld_tmp"
+    cc_check $_ld_tmp && _fontconfig=yes && _ld_fontconfig="$_ld_tmp" && break
+  done
+  if test "$_fontconfig" = no && $_pkg_config --exists fontconfig ; then
+    _inc_tmp=`$_pkg_config --cflags fontconfig`
+    _ld_tmp=`$_pkg_config --libs fontconfig`
+    cc_check $_inc_tmp $_ld_tmp && _fontconfig=yes \
+      && _ld_fontconfig="$_ld_tmp" && _inc_extra="$_inc_extra $_inc_tmp"
   fi
 fi
 if test "$_fontconfig" = yes ; then



More information about the MPlayer-cvslog mailing list