source: trunk/gsdl/src/mgpp/configure.in@ 857

Last change on this file since 857 was 857, checked in by sjboddie, 23 years ago

fixed config stuff

  • Property svn:executable set to *
  • Property svn:keywords set to Author Date Id Revision
File size: 2.9 KB
Line 
1dnl Process this file with autoconf to produce a configure script.
2AC_INIT(text/MGQuery.cpp)
3AC_CONFIG_HEADER(config.h)
4AC_ARG_PROGRAM
5
6dnl
7PACKAGE=mgpp
8VERSION=1.3
9
10AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
11AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
12AC_SUBST(PACKAGE)
13AC_SUBST(VERSION)
14
15dnl Checks for programs.
16AC_PROG_CXX
17AC_PROG_AWK
18AC_PROG_YACC
19AC_PROG_CC
20AC_PROG_INSTALL
21AC_PROG_LN_S
22AC_PROG_MAKE_SET
23AC_PROG_RANLIB
24
25dnl Checks for typedefs, structures, and compiler characteristics.
26AC_AIX
27AC_ISC_POSIX
28AC_MINIX
29fp_C_PROTOTYPES
30AC_C_CONST
31AC_TYPE_OFF_T
32AC_TYPE_SIZE_T
33AC_HEADER_TIME
34AC_STRUCT_TM
35
36dnl --- This should be in the stdc checking -----------------
37if test "$ac_cv_prog_cc_stdc" = '-Xc'; then
38dnl The Pyramids running SMP_DC.OSx on MIPS r3000 chips with
39dnl /usr/opt/cc3.11/bin/cc treat -Xc as full ANSI mode - no POSIX or
40dnl XOPEN extensions (like popen).
41dnl Unfortunately -D_{XOPEN,POSIX}_SOURCE can't provide all that mg
42dnl needs. So drop back to -Xa
43AC_TRY_COMPILE(
44[#include <stdio.h>
45], [ FILE *rubbish = popen("yes", "r"); ],,
46[CC="`echo $CC | sed 's/-Xc/-Xa/'`" ac_cv_prog_cc_stdc='-Xa'])
47fi
48dnl ----------------------
49
50
51dnl Checks for libraries.
52dnl Replace `main' with a function in -lm:
53AC_CHECK_LIB(m, main)
54
55dnl Checks for header files.
56AC_HEADER_DIRENT
57AC_HEADER_STDC
58AC_CHECK_HEADERS(fcntl.h limits.h sys/time.h unistd.h string.h memory.h sys/procfs.h)
59AC_EGREP_HEADER(fread, stdio.h, AC_DEFINE(HAVE_FREAD_DECL))
60AC_EGREP_HEADER(fgetc, stdio.h, AC_DEFINE(HAVE_FGETC_DECL))
61AC_EGREP_HEADER(pr_brksize, sys/procfs.h, AC_DEFINE(HAVE_PR_BRKSIZE))
62
63dnl Checks for library functions.
64AC_FUNC_ALLOCA
65AC_PROG_GCC_TRADITIONAL
66AC_TYPE_SIGNAL
67AC_FUNC_VPRINTF
68AC_CHECK_FUNCS(ftime select strftime strtol getrusage times mallinfo setbuffer getpagesize strerror)
69AC_REPLACE_FUNCS(ftruncate strstr strcasecmp)
70
71
72# *** Custom checking (based on GNU tar configure.in) ***
73# ---------------------------------------------------------------------------
74AC_MSG_CHECKING(for HP-UX needing gmalloc)
75if test "`(uname -s) 2> /dev/null`" = 'HP-UX'; then
76 AC_MSG_RESULT(yes)
77 LIBOBJS="$LIBOBJS gmalloc.o"
78 AC_DEFINE(HAVE_VALLOC)
79else
80 AC_MSG_RESULT(no)
81 AC_CHECK_FUNCS(valloc)
82fi
83
84fp_WITH_DMALLOC
85fp_WITH_REGEX
86fp_WITH_GNU_READLINE
87
88# ---------------------------------------------------------------------------
89if test "$ac_cv_func_alloca" = 'no'; then
90dnl support functions for alloca.c
91 LIBOBJS="$LIBOBJS xmalloc.o error.o"
92fi
93
94
95# ---------------------------------------------------------------------------
96# see if the user wants to override use of long long
97AC_ARG_ENABLE(override-longlong,
98[ --enable-override-longlong
99 overide use of long long with GCC],
100 AC_DEFINE(DISABLE_LONG_LONG))
101
102# ---------------------------------------------------------------------------
103
104AC_OUTPUT([Makefile text/Makefile src/images/Makefile
105 scripts/Makefile lib/Makefile docs/Makefile test/Makefile],
106[test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h])
Note: See TracBrowser for help on using the repository browser.