2 dnl autoconf input for WRaster library
6 AM_INIT_AUTOMAKE(wrlib, 0.3)
11 dnl Checks for programs.
12 dnl ===================
19 dnl Checks for library functions.
20 dnl ============================
21 AC_PROG_GCC_TRADITIONAL
31 _XLIBS="$X_LIBS $X_EXTRA_LIBS -lX11"
32 XLIBS="$X_EXTRA_LIBS -lX11"
43 [ --disable-xpm disable XPM support through libXpm],
44 xpm=$enableval, xpm=yes)
49 if test "$xpm" = yes; then
50 AC_CHECK_LIB(Xpm, XpmCreatePixmapFromData,
51 [GFXFLAGS=-DUSE_XPM GFXLIBS=-lXpm], ,$_XLIBS)
58 AC_CHECK_LIB(z, gzread, zlib=yes, zlib=no)
65 [ --disable-png disable PNG support through libpng],
66 png=$enableval, png=yes)
68 if test "$png" = yes; then
69 if test "$zlib" = yes; then
70 AC_CHECK_LIB(png, png_get_valid, [GFXFLAGS="$GFXFLAGS -DUSE_PNG"
71 GFXLIBS="$GFXLIBS -lpng -lz"], , -lz -lm)
79 [ --disable-tiff disable use of TIFF images through libtiff],
80 tif=$enableval, tif=yes)
82 if test "$tif" = yes; then
83 AC_CHECK_LIB(tiff, TIFFGetVersion,
84 [GFXFLAGS="$GFXFLAGS -DUSE_TIFF" GFXLIBS="$GFXLIBS -ltiff"],, -lm)
94 if test "${prefix}" = "NONE"; then
97 if test "${exec_prefix}" = "NONE"; then
104 AC_OUTPUT(Makefile config.h)