1151497Sru# Autoconf configuration file for groff. 2151497Sru# Copyright (C) 1989-1995, 2001, 2002, 2003, 2004, 2005 3151497Sru# Free Software Foundation, Inc. 4151497Sru# 5151497Sru# This file is part of groff. 6151497Sru# 7151497Sru# groff is free software; you can redistribute it and/or modify it under 8151497Sru# the terms of the GNU General Public License as published by the Free 9151497Sru# Software Foundation; either version 2, or (at your option) any later 10151497Sru# version. 11151497Sru# 12151497Sru# groff is distributed in the hope that it will be useful, but WITHOUT ANY 13151497Sru# WARRANTY; without even the implied warranty of MERCHANTABILITY or 14151497Sru# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 15151497Sru# for more details. 16151497Sru# 17151497Sru# You should have received a copy of the GNU General Public License along 18151497Sru# with groff; see the file COPYING. If not, write to the Free Software 19151497Sru# Foundation, 51 Franklin St - Fifth Floor, Boston, MA 02110-1301, USA. 20151497Sru# 21151497Sru# Process this file with autoconf to produce a configure script. 22151497Sru 2379543SruAC_INIT 24151497SruAC_PREREQ(2.59) 25151497Sru 26151497SruAC_CONFIG_HEADERS([src/include/config.h:src/include/config.hin]) 27114402SruAC_CONFIG_SRCDIR([src/roff/groff/groff.cpp]) 28151497Sru 29151497Sru# checks for programs 3079543SruAC_PROG_CC 3179543SruAC_PROG_CXX 3279543SruGROFF_CXX_CHECK 3379543SruGROFF_EBCDIC 3479543SruGROFF_OS390 35151497SruGROFF_X11 36151497SruGROFF_APPRESDIR_OPTION 37151497SruGROFF_APPRESDIR_DEFAULT 3879543SruGROFF_PRINT 39151497SruAC_PATH_PROG([PERLPATH], [perl], [/usr/bin/perl]) 4079543SruGROFF_PROG_YACC 4179543SruAC_PROG_RANLIB 4279543SruGROFF_INSTALL_SH 43104862SruGROFF_INSTALL_INFO 4479543SruAC_PROG_INSTALL 4579543SruAC_PROG_LN_S 46151497Sru 47151497Sru# use a dummy substitution if no csh hack is necessary to avoid errors 48151497Sru# with non-GNU sed programs 49151497SruGROFF_CSH_HACK([SH_SCRIPT_SED_CMD='1s/.*/:/'], [SH_SCRIPT_SED_CMD='1s/a/a/']) 50151497SruAC_SUBST([SH_SCRIPT_SED_CMD]) 51151497Sru 52151497Sru# checks for headers 53151497SruAC_CHECK_HEADERS([stdlib.h unistd.h dirent.h limits.h sys/dir.h \ 54151497Sru string.h strings.h math.h sys/time.h direct.h process.h]) 5579543SruGROFF_ISC_SYSV3 5679543SruGROFF_POSIX 57151497Sru 58151497Sru# checks for header stuff 5979543SruGROFF_SRAND 60151497SruGROFF_NEED_DECLARATION([gettimeofday]) 61151497SruGROFF_NEED_DECLARATION([hypot]) 62151497SruGROFF_NEED_DECLARATION([popen]) 63151497SruGROFF_NEED_DECLARATION([pclose]) 64151497SruGROFF_NEED_DECLARATION([putenv]) 65151497SruGROFF_NEED_DECLARATION([rand]) 66151497SruGROFF_NEED_DECLARATION([snprintf]) 67151497SruGROFF_NEED_DECLARATION([srand]) 68151497SruGROFF_NEED_DECLARATION([strcasecmp]) 69151497SruGROFF_NEED_DECLARATION([strncasecmp]) 70151497SruGROFF_NEED_DECLARATION([vfprintf]) 71151497SruGROFF_NEED_DECLARATION([vsnprintf]) 7279543SruGROFF_SYS_NERR 7379543SruGROFF_SYS_ERRLIST 7479543SruGROFF_OSFCN_H 7579543SruGROFF_LIMITS_H 76104862SruGROFF_INTTYPES_H 77151497Sru 78151497Sru# checks for typedefs 79104862SruGROFF_UNSIGNED_LONG_LONG 80104862SruGROFF_UINTMAX_T 8179543SruGROFF_TIME_T 82151497SruGROFF_TYPE_SIGNAL 8379543SruGROFF_STRUCT_EXCEPTION 84151497Sru 85151497Sru# checks for libraries 86151497SruGROFF_LIBC 8779543SruGROFF_LIBM 88151497Sru 89151497Sru# checks for functions 9079543SruAC_FUNC_MMAP 9179543Srusaved_libs="$LIBS" 92151497SruLIBS="$LIBS $LIBC $LIBM" 93151497SruAC_REPLACE_FUNCS([fmod getcwd putenv snprintf strcasecmp \ 94151497Sru strerror strncasecmp strtol]) 95151497Sru# vsnprintf is in the same source file as snprintf 96151497SruAC_CHECK_FUNCS([vsnprintf], [], [AC_LIBOBJ([snprintf])]) 9779543SruLIBS="$saved_libs" 98151497SruAC_CHECK_FUNCS([gettimeofday isatty kill rename setlocale strsep]) 9979543SruGROFF_MKSTEMP 100151497SruAC_CHECK_DECLS([sys_siglist]) 101151497Sru 102151497Sru# checks for compiler characteristics 10379543SruGROFF_ARRAY_DELETE 10479543SruGROFF_TRADITIONAL_CPP 105151497Sru 106151497Sru# checks for operating system services 10779543SruGROFF_WCOREFLAG 108151497Sru 109151497Sru# other random stuff 11079543SruGROFF_BROKEN_SPOOLER_FLAGS 11179543SruGROFF_PAGE 11279543SruGROFF_G 11379543SruGROFF_TMAC 114151497SruGROFF_TARGET_PATH_SEPARATOR 115104862SruGROFF_HTML_PROGRAMS 116151497SruGROFF_PDFDOC_PROGRAMS 117114402SruGROFF_PNMTOPS_NOSETPAGE 118151497Sru 119151497SruAC_CONFIG_FILES([stamp-h], [echo timestamp > stamp-h]) 120151497SruAC_CONFIG_FILES([Makefile doc/Makefile src/utils/xtotroff/Makefile]) 121151497SruAC_CONFIG_FILES([contrib/gdiffmk/tests/runtests], 122151497Sru [chmod +x contrib/gdiffmk/tests/runtests]) 123151497SruAC_CONFIG_FILES([test-groff], [chmod +x test-groff]) 12479543SruAC_OUTPUT 125104862Sru 126151497SruGROFF_APPRESDIR_CHECK 127