1 dnl Process this file with autoconf to produce a configure script.
2 AC_INIT(GNU Enscript, 1.6.4, bug-enscript@gnu.org)
3 AC_CONFIG_SRCDIR([src/gsint.h])
8 AM_CONFIG_HEADER(config.h)
10 AC_REVISION($Revision: 1.1.1.1 $)
23 AC_HAVE_HEADERS(string.h stdlib.h unistd.h stdarg.h math.h pwd.h)
24 AC_HAVE_HEADERS(sys/types.h sys/stat.h)
26 dnl Check some functions.
27 AC_CHECK_FUNCS(strchr getcwd)
28 AC_REPLACE_FUNCS(strerror memmove memcpy strtoul)
31 dnl -lsun is needed on IRIX-4.0 to get the user passwd entry through
32 dnl the yellow pages / NIS.
33 AC_CHECK_LIB(sun, main)
35 dnl Find out where the gethostname() is.
36 AC_CHECK_FUNC(gethostname, , [
37 AC_CHECK_LIB(nsl, gethostname, LIBS="$LIBS -lnsl", [
38 AC_CHECK_LIB(socket, gethostname)
47 [ --enable-debug enable debugging], [
48 echo enabling debugging
49 if test -n "$GCC"; then
50 CFLAGS="$CFLAGS -Wall"
54 dnl Define the default output media.
57 [ --with-media(=MEDIA) use output media Letter (MEDIA), default is A4],
58 if test "X$withval" != "Xno"; then
59 if test "X$withval" = "Xyes"; then
60 ac_cv_value_media='Letter'
62 ac_cv_value_media=$withval
65 ac_cv_value_media=${MEDIA-A4}
67 ac_cv_value_media=${MEDIA-A4}
69 MEDIA=$ac_cv_value_media
72 dnl Find the printer spooler command.
74 AC_CHECK_PROG(SPOOLER, lpr, lpr)
75 AC_CHECK_PROG(SPOOLER, lp, lp)
77 dnl user can overwrite this
79 [ --with-spooler=SPOOLER set the printer spooler command],
80 if test "X$withval" != "Xno"; then
85 dnl If SPOOLER is still empty, set it to `lpr'. After this, we should
86 dnl be able to compile enscript on HURD.
87 if test "X$SPOOLER" = "X"; then
91 dnl The PostScript language level.
94 [ --with-ps-level=LEVEL set the PostScript language level to LEVEL],
95 if test "X$withval" != "Xno"; then
101 dnl Internationalization.
102 ALL_LINGUAS="de es fi fr nl ru sl"
105 dnl Path separator character.
106 AC_DEFINE_UNQUOTED(PATH_SEPARATOR, ':')
107 AC_DEFINE_UNQUOTED(PATH_SEPARATOR_STR, ":")
115 AC_PATH_PROG(PERL, perl)
122 AC_CONFIG_FILES([Makefile po/Makefile.in m4/Makefile intl/Makefile po/Makefile \
132 states/tests/Makefile \
135 AC_CONFIG_COMMANDS([default],[[ echo timestamp > stamp-h ]], [[]])
140 echo "Enscript is now configured to your system with the following"
141 echo "user-definable options. Please, check that they are correct and"
142 echo "match to your system's properties."
144 echo "Option Change with configure's option Current value"
145 echo "---------------------------------------------------------"
146 echo "Media --with-media=MEDIA $MEDIA"
147 echo "Spooler --with-spooler=SPOOLER $SPOOLER"
148 echo "PS level --with-ps-level=LEVEL $PSLEVEL"