1999.6.1
by kalebral at gmail
update Copyright strings to a more common format to help with creating the master debian copyright file |
1 |
dnl Copyright (C) 2009 Sun Microsystems, Inc. |
2 |
dnl This file is free software; Sun Microsystems, Inc. |
|
1085.1.4
by Monty Taylor
pandora-build v1 |
3 |
dnl gives unlimited permission to copy and/or distribute it, |
4 |
dnl with or without modifications, as long as this notice is preserved. |
|
5 |
||
6 |
dnl Which version of the canonical setup we're using |
|
2023.3.31
by Monty Taylor
Updated pandora-build files to version 0.171 |
7 |
AC_DEFUN([PANDORA_CANONICAL_VERSION],[0.171])
|
1085.1.4
by Monty Taylor
pandora-build v1 |
8 |
|
9 |
AC_DEFUN([PANDORA_FORCE_DEPEND_TRACKING],[
|
|
1259.2.2
by Monty Taylor
Added option for OSX Fat Binaries. |
10 |
AC_ARG_ENABLE([fat-binaries],
|
11 |
[AS_HELP_STRING([--enable-fat-binaries],
|
|
12 |
[Enable fat binary support on OSX @<:@default=off@:>@])],
|
|
13 |
[ac_enable_fat_binaries="$enableval"],
|
|
14 |
[ac_enable_fat_binaries="no"])
|
|
15 |
||
1085.1.4
by Monty Taylor
pandora-build v1 |
16 |
dnl Force dependency tracking on for Sun Studio builds
|
17 |
AS_IF([test "x${enable_dependency_tracking}" = "x"],[
|
|
18 |
enable_dependency_tracking=yes
|
|
19 |
])
|
|
1259.2.2
by Monty Taylor
Added option for OSX Fat Binaries. |
20 |
dnl If we're building OSX Fat Binaries, we have to turn off -M options |
21 |
AS_IF([test "x${ac_enable_fat_binaries}" = "xyes"],[ |
|
22 |
enable_dependency_tracking=no
|
|
23 |
]) |
|
1085.1.4
by Monty Taylor
pandora-build v1 |
24 |
]) |
25 |
||
1776.2.1
by Monty Taylor
Updated pandora-build files to version 0.155 |
26 |
AC_DEFUN([PANDORA_BLOCK_BAD_OPTIONS],[ |
27 |
AS_IF([test "x${prefix}" = "x"],[ |
|
28 |
AC_MSG_ERROR([--prefix requires an argument]) |
|
29 |
]) |
|
30 |
]) |
|
31 |
||
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
32 |
dnl The standard setup for how we build Pandora projects |
33 |
AC_DEFUN([PANDORA_CANONICAL_TARGET],[ |
|
1085.1.4
by Monty Taylor
pandora-build v1 |
34 |
AC_REQUIRE([PANDORA_FORCE_DEPEND_TRACKING]) |
1085.1.7
by Monty Taylor
pandora-build r0.7 |
35 |
ifdef([m4_define],,[define([m4_define], defn([define]))]) |
36 |
ifdef([m4_undefine],,[define([m4_undefine], defn([undefine]))]) |
|
37 |
m4_define([PCT_ALL_ARGS],[$*]) |
|
1085.1.4
by Monty Taylor
pandora-build v1 |
38 |
m4_define([PCT_REQUIRE_CXX],[no]) |
1085.1.7
by Monty Taylor
pandora-build r0.7 |
39 |
m4_define([PCT_FORCE_GCC42],[no]) |
1273.12.3
by Monty Taylor
pandora-build v0.104 |
40 |
m4_define([PCT_DONT_SUPPRESS_INCLUDE],[no]) |
1992.6.9
by Monty Taylor
Updated pandora-build files to version 0.165 |
41 |
m4_define([PCT_NO_VC_CHANGELOG],[no]) |
1192.3.47
by Monty Taylor
pandora-build v0.79 |
42 |
m4_define([PCT_VERSION_FROM_VC],[no]) |
1192.3.46
by Monty Taylor
pandora-build v0.76 |
43 |
m4_define([PCT_USE_VISIBILITY],[yes]) |
1085.3.4
by Monty Taylor
pandora-build v0.8 |
44 |
m4_foreach([pct_arg],[$*],[ |
1085.1.4
by Monty Taylor
pandora-build v1 |
45 |
m4_case(pct_arg,
|
46 |
[require-cxx], [ |
|
47 |
m4_undefine([PCT_REQUIRE_CXX]) |
|
48 |
m4_define([PCT_REQUIRE_CXX],[yes]) |
|
49 |
], |
|
1085.1.7
by Monty Taylor
pandora-build r0.7 |
50 |
[force-gcc42], [ |
51 |
m4_undefine([PCT_FORCE_GCC42]) |
|
52 |
m4_define([PCT_FORCE_GCC42],[yes]) |
|
1126.6.1
by Monty Taylor
pandora-build v0.58 |
53 |
], |
1192.3.46
by Monty Taylor
pandora-build v0.76 |
54 |
[skip-visibility], [ |
55 |
m4_undefine([PCT_USE_VISIBILITY]) |
|
56 |
m4_define([PCT_USE_VISIBILITY],[no]) |
|
57 |
], |
|
1273.12.3
by Monty Taylor
pandora-build v0.104 |
58 |
[dont-suppress-include], [ |
59 |
m4_undefine([PCT_DONT_SUPPRESS_INCLUDE]) |
|
60 |
m4_define([PCT_DONT_SUPPRESS_INCLUDE],[yes]) |
|
61 |
], |
|
1992.6.9
by Monty Taylor
Updated pandora-build files to version 0.165 |
62 |
[no-vc-changelog], [ |
63 |
m4_undefine([PCT_NO_VC_CHANGELOG]) |
|
64 |
m4_define([PCT_NO_VC_CHANGELOG],[yes]) |
|
65 |
], |
|
1192.3.47
by Monty Taylor
pandora-build v0.79 |
66 |
[version-from-vc], [ |
67 |
m4_undefine([PCT_VERSION_FROM_VC]) |
|
68 |
m4_define([PCT_VERSION_FROM_VC],[yes]) |
|
1085.1.4
by Monty Taylor
pandora-build v1 |
69 |
]) |
70 |
]) |
|
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
71 |
|
1273.12.1
by Monty Taylor
pandora-build v0.100 - Fixes several bugs found by cb1kenobi. Add several thoughts from folks at LCA. |
72 |
AC_CONFIG_MACRO_DIR([m4]) |
73 |
||
1273.12.8
by Monty Taylor
Fixed m4 on solaris. Urg. |
74 |
m4_if(m4_substr(m4_esyscmd(test -d src && echo 0),0,1),0,[ |
1273.12.1
by Monty Taylor
pandora-build v0.100 - Fixes several bugs found by cb1kenobi. Add several thoughts from folks at LCA. |
75 |
AC_CONFIG_HEADERS([src/config.h]) |
76 |
],[ |
|
77 |
AC_CONFIG_HEADERS([config.h]) |
|
78 |
]) |
|
79 |
||
1776.2.1
by Monty Taylor
Updated pandora-build files to version 0.155 |
80 |
PANDORA_BLOCK_BAD_OPTIONS |
81 |
||
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
82 |
# We need to prevent canonical target |
83 |
# from injecting -O2 into CFLAGS - but we won't modify anything if we have |
|
84 |
# set CFLAGS on the command line, since that should take ultimate precedence
|
|
85 |
AS_IF([test "x${ac_cv_env_CFLAGS_set}" = "x"],
|
|
86 |
[CFLAGS=""])
|
|
87 |
AS_IF([test "x${ac_cv_env_CXXFLAGS_set}" = "x"],
|
|
88 |
[CXXFLAGS=""])
|
|
89 |
|
|
90 |
AC_CANONICAL_TARGET
|
|
91 |
|
|
1273.12.3
by Monty Taylor
pandora-build v0.104 |
92 |
m4_if(PCT_DONT_SUPRESS_INCLUDE,yes,[
|
1716.1.1
by Monty Taylor
Added files to the tarball that should be there. Removed some that shouldn't |
93 |
AM_INIT_AUTOMAKE(-Wall -Werror -Wno-portability subdir-objects foreign tar-ustar)
|
1273.12.3
by Monty Taylor
pandora-build v0.104 |
94 |
],[
|
1716.1.1
by Monty Taylor
Added files to the tarball that should be there. Removed some that shouldn't |
95 |
AM_INIT_AUTOMAKE(-Wall -Werror -Wno-portability nostdinc subdir-objects foreign tar-ustar)
|
1273.12.3
by Monty Taylor
pandora-build v0.104 |
96 |
])
|
97 |
||
1093.9.24
by Monty Taylor
Added support for automake 1.11 and silent build rules. |
98 |
m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])])
|
1085.1.4
by Monty Taylor
pandora-build v1 |
99 |
|
1273.12.8
by Monty Taylor
Fixed m4 on solaris. Urg. |
100 |
m4_if(m4_substr(m4_esyscmd(test -d gnulib && echo 0),0,1),0,[
|
1273.12.1
by Monty Taylor
pandora-build v0.100 - Fixes several bugs found by cb1kenobi. Add several thoughts from folks at LCA. |
101 |
gl_EARLY
|
1702.2.1
by Monty Taylor
Removed gnulib and the last usage of normal getopt. |
102 |
],[
|
103 |
PANDORA_EXTENSIONS
|
|
1273.12.1
by Monty Taylor
pandora-build v0.100 - Fixes several bugs found by cb1kenobi. Add several thoughts from folks at LCA. |
104 |
])
|
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
105 |
|
106 |
AC_REQUIRE([AC_PROG_CC])
|
|
1530.5.5
by Monty Taylor
Made sure we order tests in the right way - we want to make sure that we upgrade the gcc version before we test for C++0x support. |
107 |
m4_if(PCT_FORCE_GCC42, [yes], [
|
108 |
AC_REQUIRE([PANDORA_ENSURE_GCC_VERSION])
|
|
109 |
])
|
|
1093.4.1
by Monty Taylor
pandora-build v0.22 - fixes solaris build. |
110 |
AC_REQUIRE([PANDORA_64BIT])
|
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
111 |
|
1992.6.9
by Monty Taylor
Updated pandora-build files to version 0.165 |
112 |
m4_if(PCT_NO_VC_CHANGELOG,yes,[
|
113 |
vc_changelog=no
|
|
114 |
],[
|
|
115 |
vc_changelog=yes
|
|
116 |
])
|
|
1192.3.47
by Monty Taylor
pandora-build v0.79 |
117 |
m4_if(PCT_VERSION_FROM_VC,yes,[
|
2183.1.2
by Monty Taylor
A slew of tiny meaningless changes. |
118 |
PANDORA_VC_INFO_HEADER
|
1273.23.5
by Monty Taylor
Merged in changes fixing VC detection. |
119 |
],[
|
120 |
PANDORA_TEST_VC_DIR
|
|
1843.2.1
by Monty Taylor
Updated pandora-build files to version 0.161 |
121 |
|
122 |
changequote(<<, >>)dnl
|
|
123 |
PANDORA_RELEASE_ID=`echo $VERSION | sed 's/[^0-9]//g'` |
|
124 |
changequote([, ])dnl
|
|
125 |
||
126 |
PANDORA_RELEASE_COMMENT=""
|
|
127 |
AC_DEFINE_UNQUOTED([PANDORA_RELEASE_VERSION],["$VERSION"],
|
|
128 |
[Version of the software])
|
|
129 |
||
130 |
AC_SUBST(PANDORA_RELEASE_COMMENT)
|
|
131 |
AC_SUBST(PANDORA_RELEASE_VERSION)
|
|
132 |
AC_SUBST(PANDORA_RELEASE_ID)
|
|
1192.3.47
by Monty Taylor
pandora-build v0.79 |
133 |
])
|
134 |
PANDORA_VERSION
|
|
135 |
||
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
136 |
dnl Once we can use a modern autoconf, we can use this
|
137 |
dnl AC_PROG_CC_C99
|
|
1093.7.6
by Monty Taylor
pandora-build v0.34 |
138 |
AC_REQUIRE([AC_PROG_CXX])
|
1093.9.23
by Monty Taylor
pandora-build v0.49 |
139 |
PANDORA_EXTENSIONS
|
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
140 |
AM_PROG_CC_C_O
|
141 |
||
1093.4.1
by Monty Taylor
pandora-build v0.22 - fixes solaris build. |
142 |
|
1093.2.2
by mordred
pandora-build v0.18 |
143 |
|
1099.1.12
by Monty Taylor
Rearranged two orderings. |
144 |
PANDORA_PLATFORM
|
145 |
||
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
146 |
PANDORA_LIBTOOL
|
147 |
||
1085.1.4
by Monty Taylor
pandora-build v1 |
148 |
dnl autoconf doesn't automatically provide a fail-if-no-C++ macro |
149 |
dnl so we check c++98 features and fail if we don't have them, mainly |
|
150 |
dnl for that reason
|
|
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
151 |
PANDORA_CHECK_CXX_STANDARD
|
1085.1.4
by Monty Taylor
pandora-build v1 |
152 |
m4_if(PCT_REQUIRE_CXX, [yes], [
|
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
153 |
AS_IF([test "$ac_cv_cxx_stdcxx_98" = "no"],[
|
154 |
AC_MSG_ERROR([No working C++ Compiler has been found. ${PACKAGE} requires a C++ compiler that can handle C++98])
|
|
155 |
])
|
|
156 |
])
|
|
1775.1.2
by Monty Taylor
Updated pandora-build files to version 0.153 |
157 |
PANDORA_CXX_CSTDINT
|
158 |
PANDORA_CXX_CINTTYPES
|
|
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
159 |
|
1273.12.8
by Monty Taylor
Fixed m4 on solaris. Urg. |
160 |
m4_if(m4_substr(m4_esyscmd(test -d gnulib && echo 0),0,1),0,[
|
1126.6.1
by Monty Taylor
pandora-build v0.58 |
161 |
gl_INIT
|
162 |
AC_CONFIG_LIBOBJ_DIR([gnulib])
|
|
163 |
])
|
|
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
164 |
|
1192.3.28
by Monty Taylor
pandora-build v0.72 - Moved remaining hard-coded tests into pandora-build |
165 |
PANDORA_CHECK_C_VERSION
|
166 |
PANDORA_CHECK_CXX_VERSION
|
|
167 |
||
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
168 |
AC_C_BIGENDIAN
|
169 |
AC_C_CONST
|
|
170 |
AC_C_INLINE
|
|
171 |
AC_C_VOLATILE
|
|
1093.2.2
by mordred
pandora-build v0.18 |
172 |
AC_C_RESTRICT
|
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
173 |
|
174 |
AC_HEADER_TIME
|
|
1273.12.3
by Monty Taylor
pandora-build v0.104 |
175 |
AC_STRUCT_TM
|
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
176 |
AC_TYPE_SIZE_T
|
1085.1.4
by Monty Taylor
pandora-build v1 |
177 |
AC_SYS_LARGEFILE
|
1273.12.3
by Monty Taylor
pandora-build v0.104 |
178 |
PANDORA_CLOCK_GETTIME
|
1085.1.4
by Monty Taylor
pandora-build v1 |
179 |
|
1720.1.5
by Monty Taylor
Added libdrizzle to the tree. |
180 |
AC_CHECK_HEADERS(sys/socket.h)
|
181 |
||
1192.3.28
by Monty Taylor
pandora-build v0.72 - Moved remaining hard-coded tests into pandora-build |
182 |
# off_t is not a builtin type
|
183 |
AC_CHECK_SIZEOF(off_t, 4)
|
|
184 |
AS_IF([test "$ac_cv_sizeof_off_t" -eq 0],[
|
|
185 |
AC_MSG_ERROR("${PACKAGE} needs an off_t type.")
|
|
186 |
])
|
|
187 |
||
188 |
AC_CHECK_SIZEOF(size_t)
|
|
189 |
AS_IF([test "$ac_cv_sizeof_size_t" -eq 0],[
|
|
190 |
AC_MSG_ERROR("${PACKAGE} needs an size_t type.")
|
|
191 |
])
|
|
192 |
||
193 |
AC_DEFINE_UNQUOTED([SIZEOF_SIZE_T],[$ac_cv_sizeof_size_t],[Size of size_t as computed by sizeof()])
|
|
194 |
AC_CHECK_SIZEOF(long long)
|
|
195 |
AC_DEFINE_UNQUOTED([SIZEOF_LONG_LONG],[$ac_cv_sizeof_long_long],[Size of long long as computed by sizeof()])
|
|
196 |
AC_CACHE_CHECK([if time_t is unsigned], [ac_cv_time_t_unsigned],[
|
|
197 |
AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
|
|
198 |
[[
|
|
199 |
#include <time.h>
|
|
200 |
]],
|
|
201 |
[[
|
|
202 |
int array[(((time_t)-1) > 0) ? 1 : -1];
|
|
203 |
]])
|
|
204 |
],[
|
|
205 |
ac_cv_time_t_unsigned=yes
|
|
206 |
],[
|
|
207 |
ac_cv_time_t_unsigned=no
|
|
208 |
])
|
|
209 |
])
|
|
210 |
AS_IF([test "$ac_cv_time_t_unsigned" = "yes"],[
|
|
211 |
AC_DEFINE([TIME_T_UNSIGNED], 1, [Define to 1 if time_t is unsigned])
|
|
212 |
])
|
|
213 |
||
1955.3.1
by Monty Taylor
Removed the need for getrusage.h by doing a define check and an AC_DEFINE in |
214 |
AC_CACHE_CHECK([if system defines RUSAGE_THREAD], [ac_cv_rusage_thread],[
|
215 |
AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
|
|
216 |
[[
|
|
217 |
#include <sys/time.h>
|
|
218 |
#include <sys/resource.h>
|
|
219 |
]],[[
|
|
220 |
int x= RUSAGE_THREAD;
|
|
221 |
]])
|
|
222 |
],[
|
|
223 |
ac_cv_rusage_thread=yes
|
|
224 |
],[
|
|
225 |
ac_cv_rusage_thread=no
|
|
226 |
])
|
|
227 |
])
|
|
228 |
AS_IF([test "$ac_cv_rusage_thread" = "no"],[
|
|
229 |
AC_DEFINE([RUSAGE_THREAD], [RUSAGE_SELF],
|
|
230 |
[Define if system doesn't define]) |
|
231 |
]) |
|
232 |
||
1241.12.5
by Monty Taylor
Replace hand-rolled libm check with the standard autoconf one. |
233 |
AC_CHECK_LIBM |
1643.1.12
by Monty Taylor
Updated pandora-build files to version 0.136 |
234 |
dnl Bug on FreeBSD - LIBM check doesn't set the damn variable |
235 |
AC_SUBST([LIBM]) |
|
1192.3.46
by Monty Taylor
pandora-build v0.76 |
236 |
|
237 |
AC_CHECK_FUNC(setsockopt, [], [AC_CHECK_LIB(socket, setsockopt)]) |
|
238 |
AC_CHECK_FUNC(bind, [], [AC_CHECK_LIB(bind, bind)]) |
|
239 |
||
240 |
||
241 |
||
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
242 |
PANDORA_OPTIMIZE |
1085.1.7
by Monty Taylor
pandora-build r0.7 |
243 |
|
1192.3.28
by Monty Taylor
pandora-build v0.72 - Moved remaining hard-coded tests into pandora-build |
244 |
AC_LANG_PUSH(C++) |
245 |
# Test whether madvise() is declared in C++ code -- it is not on some |
|
246 |
# systems, such as Solaris |
|
247 |
AC_CHECK_DECLS([madvise], [], [], [AC_INCLUDES_DEFAULT[ |
|
248 |
#if HAVE_SYS_MMAN_H
|
|
249 |
#include <sys/types.h>
|
|
250 |
#include <sys/mman.h>
|
|
251 |
#endif
|
|
252 |
]]) |
|
253 |
AC_LANG_POP() |
|
254 |
||
255 |
PANDORA_HAVE_GCC_ATOMICS |
|
256 |
||
1192.3.46
by Monty Taylor
pandora-build v0.76 |
257 |
m4_if(PCT_USE_VISIBILITY,[yes],[ |
1724.1.1
by Monty Taylor
Rearranged how we set -fvisibility, allowing us to turn it on on a |
258 |
PANDORA_ENABLE_VISIBILITY
|
1992.6.9
by Monty Taylor
Updated pandora-build files to version 0.165 |
259 |
],[ |
260 |
PANDORA_CHECK_VISIBILITY
|
|
1192.3.46
by Monty Taylor
pandora-build v0.76 |
261 |
]) |
1090.3.5
by Monty Taylor
pandora-build v0.12 |
262 |
|
263 |
PANDORA_HEADER_ASSERT |
|
1085.1.7
by Monty Taylor
pandora-build r0.7 |
264 |
|
1085.1.4
by Monty Taylor
pandora-build v1 |
265 |
PANDORA_WARNINGS(PCT_ALL_ARGS) |
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
266 |
|
267 |
PANDORA_ENABLE_DTRACE |
|
268 |
||
1093.2.1
by Monty Taylor
pandora-build v0.16 |
269 |
AC_LIB_PREFIX |
270 |
PANDORA_HAVE_BETTER_MALLOC |
|
271 |
||
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
272 |
AC_CHECK_PROGS([DOXYGEN], [doxygen]) |
273 |
AC_CHECK_PROGS([PERL], [perl]) |
|
1273.12.9
by Monty Taylor
Merged up latest pandora-build. |
274 |
AC_CHECK_PROGS([DPKG_GENSYMBOLS], [dpkg-gensymbols], [:]) |
1823.5.1
by Monty Taylor
Updated pandora-build files to version 0.157 |
275 |
AC_CHECK_PROGS([LCOV], [lcov], [echo lcov not found]) |
276 |
AC_CHECK_PROGS([LCOV_GENHTML], [genhtml], [echo genhtml not found]) |
|
277 |
||
1731.5.2
by Monty Taylor
Added sphinx to the build. |
278 |
AC_CHECK_PROGS([SPHINXBUILD], [sphinx-build], [:]) |
1800.2.1
by Monty Taylor
Made sure that sphinx-build can handle man builder. |
279 |
AS_IF([test "x${SPHINXBUILD}" != "x:"],[ |
280 |
AC_CACHE_CHECK([if sphinx is new enough],[ac_cv_recent_sphinx],[ |
|
281 |
|
|
282 |
${SPHINXBUILD} -Q -C -b man -d conftest.d . . >/dev/null 2>&1
|
|
283 |
AS_IF([test $? -eq 0],[ac_cv_recent_sphinx=yes], |
|
284 |
[ac_cv_recent_sphinx=no]) |
|
285 |
rm -rf conftest.d |
|
286 |
]) |
|
287 |
]) |
|
1273.12.9
by Monty Taylor
Merged up latest pandora-build. |
288 |
|
289 |
AM_CONDITIONAL(HAVE_DPKG_GENSYMBOLS,[test "x${DPKG_GENSYMBOLS}" != "x:"]) |
|
1731.5.2
by Monty Taylor
Added sphinx to the build. |
290 |
AM_CONDITIONAL(HAVE_SPHINX,[test "x${SPHINXBUILD}" != "x:"]) |
1800.1.8
by Monty Taylor
Fixed a typo. |
291 |
AM_CONDITIONAL(HAVE_RECENT_SPHINX,[test "x${ac_cv_recent_sphinx}" = "xyes"]) |
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
292 |
|
1667.4.10
by Monty Taylor
Updated pandora-build files to version 0.138 |
293 |
m4_if(m4_substr(m4_esyscmd(test -d po && echo 0),0,1),0, [ |
294 |
AM_PO_SUBDIRS
|
|
295 |
IT_PROG_INTLTOOL([0.35],[no-xml]) |
|
1667.4.12
by Monty Taylor
Fixed gettext on solaris. |
296 |
|
1667.4.10
by Monty Taylor
Updated pandora-build files to version 0.138 |
297 |
GETTEXT_PACKAGE=$PACKAGE |
1677.1.1
by Monty Taylor
Fixed the solaris intltool issue. |
298 |
AC_CHECK_LIB(intl, libintl_gettext) |
1667.4.10
by Monty Taylor
Updated pandora-build files to version 0.138 |
299 |
AC_SUBST([GETTEXT_PACKAGE]) |
1719.1.1
by Monty Taylor
_actually_ make OSX work with no intltool. Sorry. |
300 |
AS_IF([test "x${USE_NLS}" = "xyes" -a "x${pandora_have_intltool}" = "xyes"], |
1719.1.2
by Monty Taylor
Ok. FFS. |
301 |
[AC_DEFINE([ENABLE_NLS],[1],[Turn on language support]) |
302 |
AC_CONFIG_FILES([po/Makefile.in]) |
|
1720.1.5
by Monty Taylor
Added libdrizzle to the tree. |
303 |
]) |
1667.4.10
by Monty Taylor
Updated pandora-build files to version 0.138 |
304 |
]) |
1719.1.2
by Monty Taylor
Ok. FFS. |
305 |
AM_CONDITIONAL(BUILD_PO,[test "x${USE_NLS}" = "xyes" -a "x${pandora_have_intltool}" = "xyes"]) |
1273.12.1
by Monty Taylor
pandora-build v0.100 - Fixes several bugs found by cb1kenobi. Add several thoughts from folks at LCA. |
306 |
|
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
307 |
AS_IF([test "x${gl_LIBOBJS}" != "x"],[ |
308 |
AS_IF([test "$GCC" = "yes"],[ |
|
1273.12.1
by Monty Taylor
pandora-build v0.100 - Fixes several bugs found by cb1kenobi. Add several thoughts from folks at LCA. |
309 |
AM_CPPFLAGS="-isystem \${top_srcdir}/gnulib -isystem \${top_builddir}/gnulib ${AM_CPPFLAGS}"
|
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
310 |
],[ |
1273.12.1
by Monty Taylor
pandora-build v0.100 - Fixes several bugs found by cb1kenobi. Add several thoughts from folks at LCA. |
311 |
AM_CPPFLAGS="-I\${top_srcdir}/gnulib -I\${top_builddir}/gnulib ${AM_CPPFLAGS}"
|
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
312 |
]) |
313 |
]) |
|
1273.12.8
by Monty Taylor
Fixed m4 on solaris. Urg. |
314 |
m4_if(m4_substr(m4_esyscmd(test -d src && echo 0),0,1),0,[ |
1126.6.1
by Monty Taylor
pandora-build v0.58 |
315 |
AM_CPPFLAGS="-I\$(top_srcdir)/src -I\$(top_builddir)/src ${AM_CPPFLAGS}"
|
1273.12.1
by Monty Taylor
pandora-build v0.100 - Fixes several bugs found by cb1kenobi. Add several thoughts from folks at LCA. |
316 |
],[ |
317 |
AM_CPPFLAGS="-I\$(top_srcdir) -I\$(top_builddir) ${AM_CPPFLAGS}"
|
|
1126.6.1
by Monty Taylor
pandora-build v0.58 |
318 |
]) |
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
319 |
|
1093.9.14
by Monty Taylor
pandora-build v0.43 Added -pipe to CFLAGS |
320 |
PANDORA_USE_PIPE |
321 |
||
1720.1.5
by Monty Taylor
Added libdrizzle to the tree. |
322 |
AH_TOP([ |
323 |
#ifndef __CONFIG_H__
|
|
324 |
#define __CONFIG_H__
|
|
325 |
||
1720.1.7
by Monty Taylor
Fixed the ICC missing header and the new config.h foo. |
326 |
/* _SYS_FEATURE_TESTS_H is Solaris, _FEATURES_H is GCC */
|
327 |
#if defined( _SYS_FEATURE_TESTS_H) || defined(_FEATURES_H)
|
|
1720.1.5
by Monty Taylor
Added libdrizzle to the tree. |
328 |
#error "You should include config.h as your first include file"
|
329 |
#endif
|
|
330 |
||
2173.2.1
by Monty Taylor
Fixes incorrect usage of include |
331 |
#include <config/top.h>
|
1720.1.5
by Monty Taylor
Added libdrizzle to the tree. |
332 |
]) |
333 |
mkdir -p config |
|
334 |
cat > config/top.h.stamp <<EOF_CONFIG_TOP |
|
335 |
||
336 |
#if defined(i386) && !defined(__i386__) |
|
337 |
#define __i386__ |
|
338 |
#endif
|
|
339 |
||
340 |
#if defined(_FILE_OFFSET_BITS) |
|
341 |
# undef _FILE_OFFSET_BITS |
|
342 |
#endif
|
|
343 |
EOF_CONFIG_TOP
|
|
344 |
||
345 |
diff config/top.h.stamp config/top.h >/dev/null 2>&1 || mv config/top.h.stamp config/top.h |
|
346 |
rm -f config/top.h.stamp |
|
347 |
||
348 |
AH_BOTTOM([ |
|
349 |
#if defined(__cplusplus)
|
|
350 |
# include CSTDINT_H
|
|
351 |
# include CINTTYPES_H
|
|
352 |
#else
|
|
353 |
# include <stdint.h>
|
|
354 |
# include <inttypes.h>
|
|
355 |
#endif
|
|
356 |
||
357 |
#if !defined(HAVE_ULONG) && !defined(__USE_MISC)
|
|
1992.6.9
by Monty Taylor
Updated pandora-build files to version 0.165 |
358 |
# define HAVE_ULONG 1
|
1720.1.5
by Monty Taylor
Added libdrizzle to the tree. |
359 |
typedef unsigned long int ulong;
|
360 |
#endif
|
|
361 |
||
362 |
/* To hide the platform differences between MS Windows and Unix, I am
|
|
363 |
* going to use the Microsoft way and #define the Microsoft-specific
|
|
364 |
* functions to the unix way. Microsoft use a separate subsystem for sockets,
|
|
365 |
* but Unix normally just use a filedescriptor on the same functions. It is
|
|
366 |
* a lot easier to map back to the unix way with macros than going the other
|
|
367 |
* way without side effect ;-)
|
|
368 |
*/
|
|
369 |
#ifdef TARGET_OS_WINDOWS
|
|
370 |
#define random() rand()
|
|
371 |
#define srandom(a) srand(a)
|
|
372 |
#define get_socket_errno() WSAGetLastError()
|
|
373 |
#else
|
|
374 |
#define INVALID_SOCKET -1
|
|
375 |
#define SOCKET_ERROR -1
|
|
376 |
#define closesocket(a) close(a)
|
|
377 |
#define get_socket_errno() errno
|
|
378 |
#endif
|
|
379 |
||
1929.1.39
by Monty Taylor
Added implicit_cast<> and down_cast<> to the code. |
380 |
#if defined(__cplusplus)
|
1929.1.41
by Monty Taylor
Added one more thing to the header to make down_cast work on debug builds. |
381 |
# if defined(DEBUG)
|
382 |
# include <cassert>
|
|
383 |
# include <cstddef>
|
|
384 |
# endif
|
|
1929.1.39
by Monty Taylor
Added implicit_cast<> and down_cast<> to the code. |
385 |
template<typename To, typename From>
|
386 |
inline To implicit_cast(From const &f) {
|
|
387 |
return f;
|
|
388 |
}
|
|
389 |
template<typename To, typename From> // use like this: down_cast<T*>(foo);
|
|
390 |
inline To down_cast(From* f) { // so we only accept pointers
|
|
391 |
// Ensures that To is a sub-type of From *. This test is here only
|
|
392 |
// for compile-time type checking, and has no overhead in an
|
|
393 |
// optimized build at run-time, as it will be optimized away
|
|
394 |
// completely.
|
|
395 |
if (false) {
|
|
396 |
implicit_cast<From*, To>(0);
|
|
397 |
}
|
|
398 |
||
399 |
#if defined(DEBUG)
|
|
400 |
assert(f == NULL || dynamic_cast<To>(f) != NULL); // RTTI: debug mode only!
|
|
401 |
#endif
|
|
402 |
return static_cast<To>(f);
|
|
403 |
}
|
|
404 |
#endif /* defined(__cplusplus) */
|
|
405 |
||
1720.1.5
by Monty Taylor
Added libdrizzle to the tree. |
406 |
#endif /* __CONFIG_H__ */
|
407 |
]) |
|
1093.9.14
by Monty Taylor
pandora-build v0.43 Added -pipe to CFLAGS |
408 |
|
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
409 |
AM_CFLAGS="${AM_CFLAGS} ${CC_WARNINGS} ${CC_PROFILING} ${CC_COVERAGE}" |
410 |
AM_CXXFLAGS="${AM_CXXFLAGS} ${CXX_WARNINGS} ${CC_PROFILING} ${CC_COVERAGE}" |
|
411 |
||
412 |
AC_SUBST([AM_CFLAGS]) |
|
413 |
AC_SUBST([AM_CXXFLAGS]) |
|
414 |
AC_SUBST([AM_CPPFLAGS]) |
|
1259.2.2
by Monty Taylor
Added option for OSX Fat Binaries. |
415 |
AC_SUBST([AM_LDFLAGS]) |
1085.1.3
by Monty Taylor
Split out warnings - start using the pandora build system. |
416 |
|
417 |
]) |