From eaa20ab6512e69a3f7cac0b8a7c840c430e5eb51 Mon Sep 17 00:00:00 2001 From: reinelt <> Date: Tue, 29 Jul 2003 04:56:13 +0000 Subject: [lcd4linux @ 2003-07-29 04:56:13 by reinelt] disable Raster driver automagically if gd.h not found --- configure.in | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) (limited to 'configure.in') diff --git a/configure.in b/configure.in index 0950092..452695d 100644 --- a/configure.in +++ b/configure.in @@ -20,6 +20,9 @@ AC_CHECK_CURSES # Checks for X11 AC_PATH_XTRA +# check for gd.h +AC_CHECK_HEADERS(gd/gd.h gd.h, [has_gd=true], [has_gd=false]) + # drivers AC_MSG_CHECKING([which drivers to compile]) AC_ARG_WITH( @@ -172,14 +175,22 @@ if test "$PALMPILOT" = "yes"; then fi if test "$PNG" = "yes"; then - RASTER="yes" - AC_DEFINE(WITH_PNG,1,[junk]) - DRVLIBS="$DRVLIBS -lgd" + if test "$has_gd" = "true"; then + RASTER="yes" + AC_DEFINE(WITH_PNG,1,[junk]) + DRVLIBS="$DRVLIBS -lgd" + else + AC_MSG_WARN(gd.h not found: PNG driver disabled) + fi fi if test "$PPM" = "yes"; then - RASTER="yes" - AC_DEFINE(WITH_PPM,1,[junk]) + if test "$has_gd" = "true"; then + RASTER="yes" + AC_DEFINE(WITH_PPM,1,[junk]) + else + AC_MSG_WARN(gd.h not found: PNG driver disabled) + fi fi if test "$SIN" = "yes"; then @@ -237,7 +248,6 @@ AC_CHECK_HEADERS([fcntl.h malloc.h netdb.h netinet/in.h stdlib.h string.h sys/io AC_CHECK_HEADERS(sys/io.h asm/io.h) AC_CHECK_HEADERS(linux/parport.h linux/ppdev.h) AC_CHECK_HEADERS(linux/dvb/frontend.h) -AC_CHECK_HEADERS(gd/gd.h gd.h) AC_CHECK_HEADERS(net/if_ppp.h) AC_CHECK_HEADERS(asm/msr.h) -- cgit v1.2.3