configure.ac revision 1.2
1# Autoconf configuration file for groff. 2# Copyright (C) 1989-1995, 2001, 2002, 2003, 2004, 2005 3# Free Software Foundation, Inc. 4# 5# This file is part of groff. 6# 7# groff is free software; you can redistribute it and/or modify it under 8# the terms of the GNU General Public License as published by the Free 9# Software Foundation; either version 2, or (at your option) any later 10# version. 11# 12# groff is distributed in the hope that it will be useful, but WITHOUT ANY 13# WARRANTY; without even the implied warranty of MERCHANTABILITY or 14# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 15# for more details. 16# 17# You should have received a copy of the GNU General Public License along 18# with groff; see the file COPYING. If not, write to the Free Software 19# Foundation, 51 Franklin St - Fifth Floor, Boston, MA 02110-1301, USA. 20# 21# Process this file with autoconf to produce a configure script. 22 23AC_INIT 24AC_PREREQ(2.59) 25 26AC_CONFIG_HEADERS([src/include/config.h:src/include/config.hin]) 27AC_CONFIG_SRCDIR([src/roff/groff/groff.cpp]) 28 29# checks for programs 30AC_PROG_CC 31AC_PROG_CXX 32GROFF_CXX_CHECK 33GROFF_EBCDIC 34GROFF_OS390 35GROFF_X11 36GROFF_APPRESDIR_OPTION 37GROFF_APPRESDIR_DEFAULT 38GROFF_PRINT 39AC_PATH_PROG([PERLPATH], [perl], [/usr/bin/perl]) 40GROFF_PROG_YACC 41AC_PROG_RANLIB 42GROFF_INSTALL_SH 43GROFF_INSTALL_INFO 44AC_PROG_INSTALL 45AC_PROG_LN_S 46 47SH_SCRIPT_SED_CMD="1s,/bin/sh,${CONFIG_SHELL}," 48AC_SUBST([SH_SCRIPT_SED_CMD]) 49 50# checks for headers 51AC_CHECK_HEADERS([stdlib.h unistd.h dirent.h limits.h sys/dir.h \ 52 string.h strings.h math.h sys/time.h direct.h process.h]) 53GROFF_ISC_SYSV3 54GROFF_POSIX 55 56# checks for header stuff 57GROFF_SRAND 58GROFF_NEED_DECLARATION([gettimeofday]) 59GROFF_NEED_DECLARATION([hypot]) 60GROFF_NEED_DECLARATION([popen]) 61GROFF_NEED_DECLARATION([pclose]) 62GROFF_NEED_DECLARATION([putenv]) 63GROFF_NEED_DECLARATION([rand]) 64GROFF_NEED_DECLARATION([snprintf]) 65GROFF_NEED_DECLARATION([srand]) 66GROFF_NEED_DECLARATION([strcasecmp]) 67GROFF_NEED_DECLARATION([strncasecmp]) 68GROFF_NEED_DECLARATION([vfprintf]) 69GROFF_NEED_DECLARATION([vsnprintf]) 70GROFF_SYS_NERR 71GROFF_SYS_ERRLIST 72GROFF_OSFCN_H 73GROFF_LIMITS_H 74GROFF_INTTYPES_H 75 76# checks for typedefs 77GROFF_UNSIGNED_LONG_LONG 78GROFF_UINTMAX_T 79GROFF_TIME_T 80GROFF_TYPE_SIGNAL 81GROFF_STRUCT_EXCEPTION 82 83# checks for libraries 84GROFF_LIBC 85GROFF_LIBM 86 87# checks for functions 88AC_FUNC_MMAP 89saved_libs="$LIBS" 90LIBS="$LIBS $LIBC $LIBM" 91AC_REPLACE_FUNCS([fmod getcwd putenv snprintf strcasecmp \ 92 strerror strncasecmp strtol]) 93# vsnprintf is in the same source file as snprintf 94AC_CHECK_FUNCS([vsnprintf], [], [AC_LIBOBJ([snprintf])]) 95LIBS="$saved_libs" 96AC_CHECK_FUNCS([gettimeofday isatty kill rename setlocale strsep]) 97GROFF_MKSTEMP 98AC_CHECK_DECLS([sys_siglist]) 99 100# checks for compiler characteristics 101GROFF_ARRAY_DELETE 102GROFF_TRADITIONAL_CPP 103 104# checks for operating system services 105GROFF_WCOREFLAG 106 107# other random stuff 108GROFF_BROKEN_SPOOLER_FLAGS 109GROFF_PAGE 110GROFF_G 111GROFF_TMAC 112GROFF_TARGET_PATH_SEPARATOR 113GROFF_HTML_PROGRAMS 114GROFF_PDFDOC_PROGRAMS 115GROFF_PNMTOPS_NOSETPAGE 116 117AC_CONFIG_FILES([stamp-h], [echo timestamp > stamp-h]) 118AC_CONFIG_FILES([Makefile doc/Makefile src/utils/xtotroff/Makefile]) 119AC_CONFIG_FILES([contrib/gdiffmk/tests/runtests], 120 [chmod +x contrib/gdiffmk/tests/runtests]) 121AC_CONFIG_FILES([test-groff], [chmod +x test-groff]) 122AC_OUTPUT 123 124GROFF_APPRESDIR_CHECK 125