summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-11-04 11:57:03 +0000
committerreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-11-04 11:57:03 +0000
commitee1ee5aa19ef713c6e88d9e05a48deaae60b6490 (patch)
treeafc2ae34f76497fd7c60ba3ce9cb0014877decdc /configure
parent3a0f1fa219cd345c8f9a8807f5be4716cf590d38 (diff)
downloadmpv-ee1ee5aa19ef713c6e88d9e05a48deaae60b6490.tar.bz2
mpv-ee1ee5aa19ef713c6e88d9e05a48deaae60b6490.tar.xz
Extended/reworked fontconfig test to work without pkg-config with versions
that need -lz git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@20663 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure20
1 files changed, 10 insertions, 10 deletions
diff --git a/configure b/configure
index ae23bb5666..76a840b002 100755
--- a/configure
+++ b/configure
@@ -5403,16 +5403,16 @@ int main()
}
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