1 | dnl Process this file with autoconf to produce a configure script.
|
---|
2 | AC_INIT(lib/text_t.h)
|
---|
3 |
|
---|
4 | PACKAGE=gsdl
|
---|
5 | VERSION=2.0
|
---|
6 | AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE")
|
---|
7 | AC_DEFINE_UNQUOTED(VERSION, "$VERSION")
|
---|
8 | AC_SUBST(PACKAGE)
|
---|
9 | AC_SUBST(VERSION)
|
---|
10 |
|
---|
11 | USE_FASTCGI=0
|
---|
12 | if test USE_FASTCGI = 1; then
|
---|
13 | AC_DEFINE(USE_FASTCGI)
|
---|
14 | AC_SUBST(USE_FASTCGI)
|
---|
15 | fi
|
---|
16 |
|
---|
17 | dnl Checks for programs.
|
---|
18 | AC_PROG_CC
|
---|
19 | AC_PROG_CXX
|
---|
20 | dnl AC_PROG_INSTALL
|
---|
21 | AC_PROG_LN_S
|
---|
22 | AC_PROG_MAKE_SET
|
---|
23 | AC_PROG_RANLIB
|
---|
24 |
|
---|
25 | dnl Checks for libraries.
|
---|
26 | dnl Replace `main' with a function in -lg:
|
---|
27 | AC_CHECK_LIB(g, main)
|
---|
28 | dnl Replace `main' with a function in -lgdbm:
|
---|
29 | AC_CHECK_LIB(gdbm, main)
|
---|
30 | dnl Replace `main' with a function in -lm:
|
---|
31 | AC_CHECK_LIB(m, main)
|
---|
32 | dnl Replace `main' with a function in -lstdc:
|
---|
33 | AC_CHECK_LIB(stdc, main)
|
---|
34 |
|
---|
35 | dnl Checks for header files.
|
---|
36 | AC_HEADER_STDC
|
---|
37 | AC_CHECK_HEADERS(fcntl.h)
|
---|
38 |
|
---|
39 | dnl Checks for typedefs, structures, and compiler characteristics.
|
---|
40 | AC_C_CONST
|
---|
41 | AC_HEADER_TIME
|
---|
42 |
|
---|
43 |
|
---|
44 | dnl
|
---|
45 | dnl Check if the STL library has any known faults;
|
---|
46 | dnl In GCC 2.7.2.x series, some STL library headers are missing
|
---|
47 | dnl a file called "new" which is referred to by other headers
|
---|
48 | dnl (eg. vector/vector.h); if this applies, then all use of the
|
---|
49 | dnl STL will cause a compile fail, so we'd better let the user
|
---|
50 | dnl know now, before things really go wrong!
|
---|
51 | dnl
|
---|
52 | AC_LANG_CPLUSPLUS
|
---|
53 | success=no
|
---|
54 | AC_MSG_CHECKING("whether STL library has known faults")
|
---|
55 |
|
---|
56 | dnl - first shot, try simple good old vector on its own
|
---|
57 | AC_TRY_COMPILE(
|
---|
58 | [#include <vector>
|
---|
59 | ],
|
---|
60 | [],
|
---|
61 | success=yes,
|
---|
62 | )
|
---|
63 |
|
---|
64 | dnl - try using the .h equivalent
|
---|
65 | if test $success = "no"; then
|
---|
66 | AC_TRY_COMPILE(
|
---|
67 | [#include <vector.h>
|
---|
68 | ],
|
---|
69 | [],
|
---|
70 | success="yes",
|
---|
71 | )
|
---|
72 | fi
|
---|
73 |
|
---|
74 | dnl - now try for the objectspace headers
|
---|
75 | if test $success = "no"; then
|
---|
76 | AC_TRY_COMPILE(
|
---|
77 | [#include <ospace\\std\\vector>
|
---|
78 | ],
|
---|
79 | [],
|
---|
80 | success="yes",
|
---|
81 | )
|
---|
82 | fi
|
---|
83 |
|
---|
84 | if test $success = yes; then
|
---|
85 | AC_MSG_RESULT("no")
|
---|
86 | else
|
---|
87 | AC_MSG_RESULT("yes")
|
---|
88 | AC_MSG_ERROR("STL Broken - new not found in vector header file")
|
---|
89 | fi
|
---|
90 |
|
---|
91 | gsdlos=`uname | tr A-Z a-z`
|
---|
92 | AC_SUBST(gsdlos)
|
---|
93 |
|
---|
94 | dnl Checks for library functions.
|
---|
95 | AC_FUNC_VPRINTF
|
---|
96 |
|
---|
97 | AC_OUTPUT(src/hashfile/Makefile src/colservr/Makefile src/recpt/Makefile src/txt2db/Makefile src/db2txt/Makefile lib/Makefile collect/cstr/src/recpt/Makefile collect/niupepa/src/recpt/Makefile Makefile)
|
---|
98 |
|
---|
99 |
|
---|
100 |
|
---|
101 |
|
---|