changeset 35612:488b3fea696d

Allow libmng autodetection to test for "-lmng" and "-lmng -ljpeg". Patch by Josh, joshf87 live com
author cehoyos
date Sat, 22 Dec 2012 17:53:30 +0000
parents a4741058bb40
children 4bcf4d38c8ad
files configure
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/configure	Sat Dec 22 13:17:19 2012 +0000
+++ b/configure	Sat Dec 22 17:53:30 2012 +0000
@@ -5004,12 +5004,14 @@
 echocheck "MNG support"
 if test "$_mng" = auto ; then
   _mng=no
-  return_statement_check libmng.h 'const char * p_ver = mng_version_text()' '!p_ver || p_ver[0] == 0' -lmng -lz && _mng=yes
+  for mnglibs in '-lmng -lz' '-lmng -ljpeg -lz' ; do
+    return_statement_check libmng.h 'const char * p_ver = mng_version_text()' '!p_ver || p_ver[0] == 0' $mnglibs && _mng=yes
+  done
 fi
 echores "$_mng"
 if test "$_mng" = yes ; then
   def_mng='#define CONFIG_MNG 1'
-  extra_ldflags="$extra_ldflags -lmng -lz"
+  extra_ldflags="$extra_ldflags $mnglibs"
   vomodules="mng $vomodules"
 else
   def_mng='#undef CONFIG_MNG'