estonian translation
[wmaker-crm.git] / wrlib / configure.in
bloba1ecd05ae797da9693614a7e6daf2c4696b28477
1 dnl
2 dnl autoconf input for WRaster library
3 dnl
5 AC_INIT(raster.c)
6 AM_INIT_AUTOMAKE(wrlib, 0.3)
9 CFLAGS="$CFLAGS -O2"
11 dnl Checks for programs.
12 dnl ===================
13 AC_PROG_CC
14 AC_PROG_MAKE_SET
15 AC_PROG_RANLIB
16 AC_PROG_INSTALL
19 dnl Checks for library functions.
20 dnl ============================
21 AC_PROG_GCC_TRADITIONAL
22 AC_FUNC_MEMCMP
23 AC_FUNC_ALLOCA
24 AC_TYPE_SIGNAL
25 AC_FUNC_VPRINTF
27 AC_PATH_XTRA
29 XCFLAGS="$X_CFLAGS"
31 _XLIBS="$X_LIBS $X_EXTRA_LIBS -lX11"
32 XLIBS="$X_EXTRA_LIBS -lX11"
34 XLFLAGS=$X_LIBS
36 AC_SUBST(XCFLAGS)
37 AC_SUBST(XLFLAGS)
39 dnl Pixmap Support
40 dnl ==============
41 xpm=yes
42 AC_ARG_ENABLE(xpm, 
43 [  --disable-xpm                  disable XPM support through libXpm],
44         xpm=$enableval, xpm=yes)
45         
46 GFXFLAGS=""
47 GFXLIBS=""
49 if test "$xpm" = yes; then
50     AC_CHECK_LIB(Xpm, XpmCreatePixmapFromData,
51                 [GFXFLAGS=-DUSE_XPM GFXLIBS=-lXpm], ,$_XLIBS)
55 dnl test for zlib
56 dnl =============
58 AC_CHECK_LIB(z, gzread, zlib=yes, zlib=no)
61 dnl PNG Support
62 dnl ===========
63 png=yes
64 AC_ARG_ENABLE(png, 
65 [  --disable-png                  disable PNG support through libpng],
66         png=$enableval, png=yes)
67         
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)
72     fi
75 dnl TIFF Support
76 dnl ============
77 tif=yes
78 AC_ARG_ENABLE(tif, 
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)
88 AC_SUBST(GFXFLAGS)
89 AC_SUBST(GFXLIBS)
91 AC_SUBST(XLIBS)
94 if test "${prefix}" = "NONE"; then
95     prefix="/usr/local"
97 if test "${exec_prefix}" = "NONE"; then
98     exec_prefix=$prefix
102 AC_C_CONST
104 AC_OUTPUT(Makefile config.h)