--- psiconv/trunk/configure 2000/07/17 21:12:44 50 +++ psiconv/trunk/configure 2000/12/25 22:25:33 79 @@ -475,7 +475,7 @@ # A filename unique to this package, relative to the directory that # configure is in, which we can look for to find out if srcdir is correct. -ac_unique_file=psiconv +ac_unique_file=lib/psiconv # Find the source files, if location was not specified. if test -z "$srcdir"; then @@ -715,7 +715,7 @@ PACKAGE=psiconv -VERSION=0.6.1 +VERSION=0.8.0 if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; } @@ -1552,60 +1552,65 @@ fi if test x"$IMAGEMAGICK" != xno ; then - echo $ac_n "checking for ConstituteImage in -lMagick""... $ac_c" 1>&6 -echo "configure:1557: checking for ConstituteImage in -lMagick" >&5 -ac_lib_var=`echo Magick'_'ConstituteImage | sed 'y%./+-%__p_%'` -if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + # Extract the first word of "Magick-config", so it can be a program name with args. +set dummy Magick-config; ac_word=$2 +echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +echo "configure:1559: checking for $ac_word" >&5 +if eval "test \"`echo '$''{'ac_cv_prog_IMAGEMAGICK'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else - ac_save_LIBS="$LIBS" -LIBS="-lMagick $LIBS" -cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=yes" + if test -n "$IMAGEMAGICK"; then + ac_cv_prog_IMAGEMAGICK="$IMAGEMAGICK" # Let the user override the test. else - echo "configure: failed program was:" >&5 - cat conftest.$ac_ext >&5 - rm -rf conftest* - eval "ac_cv_lib_$ac_lib_var=no" + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" + ac_dummy="$PATH" + for ac_dir in $ac_dummy; do + test -z "$ac_dir" && ac_dir=. + if test -f $ac_dir/$ac_word; then + ac_cv_prog_IMAGEMAGICK="yes" + break + fi + done + IFS="$ac_save_ifs" + test -z "$ac_cv_prog_IMAGEMAGICK" && ac_cv_prog_IMAGEMAGICK="no" fi -rm -f conftest* -LIBS="$ac_save_LIBS" - fi -if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then - echo "$ac_t""yes" 1>&6 - IMAGEMAGICK=yes +IMAGEMAGICK="$ac_cv_prog_IMAGEMAGICK" +if test -n "$IMAGEMAGICK"; then + echo "$ac_t""$IMAGEMAGICK" 1>&6 else echo "$ac_t""no" 1>&6 -IMAGEMAGICK=no fi if test x"$IMAGEMAGICK" != xno ; then + CFLAGS_OLD="$CFLAGS" + CPPFLAGS_OLD="$CPPFLAGS" + LDFLAGS_OLD="$LDFLAGS" + LIBS_OLD="$LIBS" + CFLAGS="$CFLAGS `Magick-config --cflags`" + CPPFLAGS="$CPPFLAGS `Magick-config --cppflags`" + LDFLAGS="$LDFLAGS `Magick-config --ldflags`" + LIBS="$LIBS `Magick-config --libs`" + echo $ac_n "checking whether GetMagickInfo works""... $ac_c" 1>&6 -echo "configure:1599: checking whether GetMagickInfo works" >&5 +echo "configure:1597: checking whether GetMagickInfo works" >&5 if test "$cross_compiling" = yes; then IMAGEMAGICK=yes else cat > conftest.$ac_ext < - int main(void) { return (NULL == GetMagickInfo(NULL)) } + #include + #include + extern void OpenModules(void); + int main(void) { GetMagickInfo(NULL); + #if defined(HasLTDL) + OpenModules(); + #endif + return (NULL == GetMagickInfo(NULL)); } EOF -if { (eval echo configure:1609: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:1614: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then IMAGEMAGICK=yes else @@ -1618,13 +1623,16 @@ fi echo "$ac_t""$IMAGEMAGICK" 1>&6 - fi - if test x"$IMAGEMAGICK" = xno ; then - echo "configure: warning: ImageMagick support disabled!" 1>&2 + LDFLAGS="$LDFLAGS_OLD" + LIBS="$LIBS_OLD" + if test x"$IMAGEMAGICK" = xno ; then + CFLAGS="$CFLAGS_OLD" + CPPFLAGS="$CPPFLAGS_OLD" + fi fi fi if test x"$IMAGEMAGICK" = xyes ; then - LIB_MAGICK=-lMagick + LIB_MAGICK="`Magick-config --libs` `Magick-config --ldflags`" cat >> confdefs.h <<\EOF #define IMAGEMAGICK 1 EOF @@ -1635,7 +1643,7 @@ echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 -echo "configure:1639: checking how to run the C preprocessor" >&5 +echo "configure:1647: checking how to run the C preprocessor" >&5 # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= @@ -1650,13 +1658,13 @@ # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1660: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1668: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -1667,13 +1675,13 @@ rm -rf conftest* CPP="${CC-cc} -E -traditional-cpp" cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1677: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1685: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -1684,13 +1692,13 @@ rm -rf conftest* CPP="${CC-cc} -nologo -E" cat > conftest.$ac_ext < Syntax Error EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1694: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1702: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then : @@ -1715,12 +1723,12 @@ echo "$ac_t""$CPP" 1>&6 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6 -echo "configure:1719: checking for ANSI C header files" >&5 +echo "configure:1727: checking for ANSI C header files" >&5 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < #include @@ -1728,7 +1736,7 @@ #include EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1732: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1740: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -1745,7 +1753,7 @@ if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat > conftest.$ac_ext < EOF @@ -1763,7 +1771,7 @@ if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat > conftest.$ac_ext < EOF @@ -1784,7 +1792,7 @@ : else cat > conftest.$ac_ext < #define ISLOWER(c) ('a' <= (c) && (c) <= 'z') @@ -1795,7 +1803,7 @@ exit (0); } EOF -if { (eval echo configure:1799: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:1807: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then : else @@ -1822,17 +1830,17 @@ do ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 -echo "configure:1826: checking for $ac_hdr" >&5 +echo "configure:1834: checking for $ac_hdr" >&5 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < EOF ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" -{ (eval echo configure:1836: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } +{ (eval echo configure:1844: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` if test -z "$ac_err"; then rm -rf conftest* @@ -1860,12 +1868,12 @@ echo $ac_n "checking for working const""... $ac_c" 1>&6 -echo "configure:1864: checking for working const" >&5 +echo "configure:1872: checking for working const" >&5 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_compile) 2>&5; }; then +if { (eval echo configure:1926: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then rm -rf conftest* ac_cv_c_const=yes else @@ -1935,12 +1943,12 @@ fi echo $ac_n "checking for size_t""... $ac_c" 1>&6 -echo "configure:1939: checking for size_t" >&5 +echo "configure:1947: checking for size_t" >&5 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext < #if STDC_HEADERS @@ -1970,7 +1978,7 @@ echo $ac_n "checking size of char""... $ac_c" 1>&6 -echo "configure:1974: checking size of char" >&5 +echo "configure:1982: checking size of char" >&5 if eval "test \"`echo '$''{'ac_cv_sizeof_char'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -1978,7 +1986,7 @@ ac_cv_sizeof_char=1 else cat > conftest.$ac_ext < main() @@ -1989,7 +1997,7 @@ exit(0); } EOF -if { (eval echo configure:1993: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:2001: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_sizeof_char=`cat conftestval` else @@ -2009,7 +2017,7 @@ echo $ac_n "checking size of short""... $ac_c" 1>&6 -echo "configure:2013: checking size of short" >&5 +echo "configure:2021: checking size of short" >&5 if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2017,7 +2025,7 @@ ac_cv_sizeof_short=1 else cat > conftest.$ac_ext < main() @@ -2028,7 +2036,7 @@ exit(0); } EOF -if { (eval echo configure:2032: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:2040: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_sizeof_short=`cat conftestval` else @@ -2048,7 +2056,7 @@ echo $ac_n "checking size of int""... $ac_c" 1>&6 -echo "configure:2052: checking size of int" >&5 +echo "configure:2060: checking size of int" >&5 if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2056,7 +2064,7 @@ ac_cv_sizeof_int=2 else cat > conftest.$ac_ext < main() @@ -2067,7 +2075,7 @@ exit(0); } EOF -if { (eval echo configure:2071: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:2079: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_sizeof_int=`cat conftestval` else @@ -2087,7 +2095,7 @@ echo $ac_n "checking size of long""... $ac_c" 1>&6 -echo "configure:2091: checking size of long" >&5 +echo "configure:2099: checking size of long" >&5 if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else @@ -2095,7 +2103,7 @@ ac_cv_sizeof_long=4 else cat > conftest.$ac_ext < main() @@ -2106,7 +2114,7 @@ exit(0); } EOF -if { (eval echo configure:2110: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null +if { (eval echo configure:2118: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null then ac_cv_sizeof_long=`cat conftestval` else @@ -2127,7 +2135,7 @@ echo $ac_n "checking for an 8 bit integer type""... $ac_c" 1>&6 -echo "configure:2131: checking for an 8 bit integer type" >&5 +echo "configure:2139: checking for an 8 bit integer type" >&5 if test $ac_cv_sizeof_char -ge 1 ; then INT_8_BIT=char echo "$ac_t""char" 1>&6 @@ -2145,7 +2153,7 @@ fi echo $ac_n "checking for a 16 bit integer type""... $ac_c" 1>&6 -echo "configure:2149: checking for a 16 bit integer type" >&5 +echo "configure:2157: checking for a 16 bit integer type" >&5 if test $ac_cv_sizeof_char -ge 2 ; then INT_16_BIT=char echo "$ac_t""char" 1>&6 @@ -2163,7 +2171,7 @@ fi echo $ac_n "checking for a 32 bit integer type""... $ac_c" 1>&6 -echo "configure:2167: checking for a 32 bit integer type" >&5 +echo "configure:2175: checking for a 32 bit integer type" >&5 if test $ac_cv_sizeof_char -ge 4 ; then INT_32_BIT=char echo "$ac_t""char" 1>&6 @@ -2185,12 +2193,12 @@ echo $ac_n "checking for vprintf""... $ac_c" 1>&6 -echo "configure:2189: checking for vprintf" >&5 +echo "configure:2197: checking for vprintf" >&5 if eval "test \"`echo '$''{'ac_cv_func_vprintf'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2225: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_vprintf=yes" else @@ -2237,12 +2245,12 @@ if test "$ac_cv_func_vprintf" != yes; then echo $ac_n "checking for _doprnt""... $ac_c" 1>&6 -echo "configure:2241: checking for _doprnt" >&5 +echo "configure:2249: checking for _doprnt" >&5 if eval "test \"`echo '$''{'ac_cv_func__doprnt'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2277: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func__doprnt=yes" else @@ -2292,12 +2300,12 @@ for ac_func in strdup do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:2296: checking for $ac_func" >&5 +echo "configure:2304: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2332: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -2349,12 +2357,12 @@ for ac_func in getopt_long do echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 -echo "configure:2353: checking for $ac_func" >&5 +echo "configure:2361: checking for $ac_func" >&5 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "(cached) $ac_c" 1>&6 else cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +if { (eval echo configure:2389: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then rm -rf conftest* eval "ac_cv_func_$ac_func=yes" else @@ -2594,7 +2602,7 @@ ac_given_srcdir=$srcdir ac_given_INSTALL="$INSTALL" -trap 'rm -fr `echo "Makefile compat/Makefile lib/Makefile psiconv/Makefile lib/general.h formats/Makefile docs/Makefile config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 +trap 'rm -fr `echo "Makefile compat/Makefile lib/Makefile lib/psiconv/Makefile program/Makefile program/psiconv/Makefile lib/psiconv/general.h formats/Makefile docs/Makefile extra/Makefile config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 EOF cat >> $CONFIG_STATUS <> $CONFIG_STATUS <> $CONFIG_STATUS <<\EOF for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then