diff options
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 84 |
1 files changed, 44 insertions, 40 deletions
diff --git a/configure.in b/configure.in index 7aaf7c8..cf4a7e7 100644 --- a/configure.in +++ b/configure.in @@ -167,7 +167,6 @@ dnl AC_CHECK_LIB(m,ceil) AC_CHECK_LIB(nsl,xdr_int) dnl ...for Solaris and hdf4 AC_CHECK_LIB(coug,main) dnl ...for ASCI/Red -AC_CHECK_LIB(jpeg,main) dnl ...required for linking hdf4 apps dnl ---------------------------------------------------------------------- dnl Check for system header files. @@ -268,45 +267,6 @@ case $HSIZET in esac dnl ---------------------------------------------------------------------- -dnl Is the GNU zlib present? It has a header file `zlib.h' and a library -dnl `-lz' and their locations might be specified with the `--enable-zlib' -dnl command-line switch. The value is an include path and/or a library path. -dnl If the library path is specified then it must be preceded by a comma. -dnl - -AC_ARG_WITH(zlib,[ --with-zlib=INC,LIB Use the GNU zlib compression], - ,withval=yes) -case $withval in - yes) - AC_CHECK_HEADERS(zlib.h) - AC_CHECK_LIB(z, compress) - ;; - no) - AC_MSG_CHECKING(for GNU zlib) - AC_MSG_RESULT(suppressed) - ;; - *) - zlib_inc="`echo $withval |cut -f1 -d,`" - if test "X" != "$zlib_inc"; then - saved_CPPFLAGS="$CPPFLAGS" - CPPFLAGS="$CPPFLAGS -I$zlib_inc" - AC_CHECK_HEADERS(zlib.h,,CPPFLAGS="$saved_CPPFLAGS") - else - AC_CHECK_HEADERS(zlib.h) - fi - - zlib_lib="`echo $withval |cut -f2 -d, -s`" - if test "X" != "$zlb_lib"; then - saved_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS -L$zlib_lib" - AC_CHECK_LIB(z, compress,,LDFLAGS="$saved_LDFLAGS") - else - AC_CHECK_LIB(z, compress) - fi - ;; -esac - -dnl ---------------------------------------------------------------------- dnl Is HDF4 present? If so then we can compile the h5toh4 converter. We dnl assume h5toh4 can be compiled and then prove otherwise when we don't find dnl a header file or library. @@ -320,6 +280,8 @@ AC_ARG_WITH(hdf4,[ --with-hdf4=INC,LIB Use the HDF4 library],,withval=[/usr case $withval in yes) AC_CHECK_HEADERS(mfhdf.h,,unset H5TOH4 TESTH5TOH4) + AC_CHECK_LIB(z,main,,unset H5TOH4 TESTH5TOH4) + AC_CHECK_LIB(jpeg,main,,unset H5TOH4 TESTH5TOH4) AC_CHECK_LIB(df,main,,unset H5TOH4 TESTH5TOH4) AC_CHECK_LIB(mfhdf,main,,unset H5TOH4 TESTH5TOH4) ;; @@ -345,15 +307,57 @@ case $withval in if test "X" != "$hdf4_lib"; then saved_LDFLAGS="$LDFLAGS" LDFLAGS="$LDFLAGS -L$hdf4_lib" + AC_CHECK_LIB(z,main,,unset H5TOH4 TESTH5TOH4) + AC_CHECK_LIB(jpeg,main,,unset H5TOH4 TESTH5TOH4) AC_CHECK_LIB(df,main,,unset H5TOH4 TESTH5TOH4) AC_CHECK_LIB(mfhdf,main,,unset H5TOH4 TESTH5TOH4) else + AC_CHECK_LIB(z,main,,unset H5TOH4 TESTH5TOH4) + AC_CHECK_LIB(jpeg,main,,unset H5TOH4 TESTH5TOH4) AC_CHECK_LIB(df,main) AC_CHECK_LIB(mfhdf,main) fi ;; esac +dnl ---------------------------------------------------------------------- +dnl Is the GNU zlib present? It has a header file `zlib.h' and a library +dnl `-lz' and their locations might be specified with the `--enable-zlib' +dnl command-line switch. The value is an include path and/or a library path. +dnl If the library path is specified then it must be preceded by a comma. +dnl + +AC_ARG_WITH(zlib,[ --with-zlib=INC,LIB Use the GNU zlib compression], + ,withval=yes) +case $withval in + yes) + AC_CHECK_HEADERS(zlib.h) + AC_CHECK_LIB(z, compress) + ;; + no) + AC_MSG_CHECKING(for GNU zlib) + AC_MSG_RESULT(suppressed) + ;; + *) + zlib_inc="`echo $withval |cut -f1 -d,`" + if test "X" != "$zlib_inc"; then + saved_CPPFLAGS="$CPPFLAGS" + CPPFLAGS="$CPPFLAGS -I$zlib_inc" + AC_CHECK_HEADERS(zlib.h,,CPPFLAGS="$saved_CPPFLAGS") + else + AC_CHECK_HEADERS(zlib.h) + fi + + zlib_lib="`echo $withval |cut -f2 -d, -s`" + if test "X" != "$zlb_lib"; then + saved_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -L$zlib_lib" + AC_CHECK_LIB(z, compress,,LDFLAGS="$saved_LDFLAGS") + else + AC_CHECK_LIB(z, compress) + fi + ;; +esac dnl ---------------------------------------------------------------------- dnl How does one figure out the local time zone? Anyone know of a |