]>
Commit | Line | Data |
---|---|---|
0cbdf24b | 1 | dnl RRDtool AutoConf script ... |
37fc6638 | 2 | dnl --------------------------- |
43f53d99 | 3 | dnl $Id$ |
37fc6638 TO |
4 | dnl |
5 | dnl Created by Jeff Allen, Tobi Oetiker, Blair Zajac | |
6 | dnl | |
8b65ac0e | 7 | dnl Inspiration from http://autoconf-archive.cryp.to |
0cbdf24b | 8 | |
cdab6835 | 9 | dnl tell automake the this script is for rrdtool |
777e0070 | 10 | |
b0400c71 TO |
11 | dnl Minimum Autoconf version required. |
12 | AC_PREREQ(2.59) | |
13 | ||
7f1747cb TO |
14 | dnl the official version number is |
15 | dnl a.b.c | |
0033ee5d | 16 | AC_INIT([rrdtool],m4_esyscmd([tr -d '\n' < VERSION])) |
6f1c8623 | 17 | AC_CONFIG_AUX_DIR(conftools) |
777e0070 | 18 | |
777e0070 | 19 | |
5606e705 TO |
20 | dnl for the linker to understand which versions the library are compatible with |
21 | dnl each other we must keep a separate library version cout of the format c:r:a. | |
22 | dnl - if only implementation changed but all interfaces are kept, do r++ | |
23 | dnl - if only functionality was added do c++,r=0,a++ | |
24 | dnl - if any functionality was removed do c++,r=0,a=0. | |
777e0070 TO |
25 | dnl |
26 | dnl see http://sourceware.org/autobook/autobook/autobook_91.html | |
0cbdf24b | 27 | dnl |
003a907f | 28 | LIBVERS=11:0:3 |
777e0070 TO |
29 | AC_SUBST(LIBVERS) |
30 | ||
45319c55 | 31 | AC_CANONICAL_TARGET |
b0400c71 | 32 | m4_version_prereq(2.60, [AC_USE_SYSTEM_EXTENSIONS], [#]) |
a23d18c1 | 33 | AM_INIT_AUTOMAKE |
58cc8383 | 34 | AM_MAINTAINER_MODE |
a23d18c1 TO |
35 | # Enable silent build rules by default, requires at least |
36 | # Automake-1.11. Disable by either passing --disable-silent-rules to | |
37 | # configure or passing V=1 to make | |
38 | m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) | |
b68117e0 | 39 | AC_CONFIG_HEADERS([src/rrd_config.h]) |
c862de08 | 40 | AC_CONFIG_MACRO_DIR([m4]) |
37fc6638 TO |
41 | |
42 | dnl all our local stuff like install scripts and include files | |
43 | dnl is in there | |
cdab6835 | 44 | |
37fc6638 TO |
45 | |
46 | dnl determine the type of system we are running on | |
37fc6638 | 47 | |
37fc6638 TO |
48 | AC_SUBST(VERSION) |
49 | ||
f9178759 | 50 | AC_PREFIX_DEFAULT( /opt/rrdtool-$PACKAGE_VERSION ) |
dea555a3 | 51 | |
cdab6835 TO |
52 | dnl At the TOP of the HEADER |
53 | ||
54 | AH_TOP([ | |
7fd68343 TO |
55 | #ifndef RRD_CONFIG_H |
56 | #define RRD_CONFIG_H | |
738d50c4 | 57 | |
cdab6835 TO |
58 | /* IEEE can be prevented from raising signals with fpsetmask(0) */ |
59 | #undef MUST_DISABLE_FPMASK | |
60 | ||
61 | /* IEEE math only works if SIGFPE gets actively set to IGNORE */ | |
cdab6835 TO |
62 | #undef MUST_DISABLE_SIGFPE |
63 | ||
64 | /* realloc does not support NULL as argument */ | |
65 | #undef NO_NULL_REALLOC | |
965d0f77 | 66 | |
0cbdf24b | 67 | /* lets enable madvise defines in NetBSD */ |
e1005301 TO |
68 | #if defined(__NetBSD__) |
69 | # if !defined(_NETBSD_SOURCE) | |
70 | # define _NETBSD_SOURCE | |
71 | # endif | |
72 | #endif | |
73 | ||
738d50c4 | 74 | ]) |
cdab6835 TO |
75 | |
76 | AH_BOTTOM([ | |
77 | ||
738d50c4 | 78 | #ifdef MUST_HAVE_MALLOC_MALLOC_H |
3a44ef8a TO |
79 | # include <malloc/malloc.h> |
80 | #endif | |
81 | ||
c238ca48 | 82 | #include "rrd_config_bottom.h" |
f6d0c1c8 | 83 | |
f6d0c1c8 | 84 | #endif |
cdab6835 TO |
85 | ]) |
86 | ||
b672fc87 TO |
87 | dnl Process Special Options |
88 | dnl ----------------------------------- | |
37fc6638 | 89 | |
b672fc87 | 90 | dnl How the vertical axis label is printed |
0cbdf24b | 91 | AC_ARG_VAR(RRDGRAPH_YLEGEND_ANGLE, |
9c4e67d9 | 92 | [Vertical label angle: -90.0 (default) or 90.0]) |
b672fc87 | 93 | AC_DEFINE_UNQUOTED(RRDGRAPH_YLEGEND_ANGLE,${RRDGRAPH_YLEGEND_ANGLE:-90.0}, |
9c4e67d9 | 94 | [Vertical label angle: -90.0 (default) or 90.0]) |
a89dc4f8 | 95 | |
deaef079 GZ |
96 | AC_ARG_ENABLE(docs,AS_HELP_STRING([--disable-docs],[disable building documentation]), |
97 | [],[enable_docs=yes]) | |
98 | ||
e24e014c FB |
99 | AC_ARG_ENABLE(examples,AS_HELP_STRING([--disable-examples],[disable building of examples]), |
100 | [],[enable_examples=yes]) | |
101 | ||
38fb0ad1 FB |
102 | AC_ARG_ENABLE(rrdcached,AS_HELP_STRING([--disable-rrdcached],[disable building of rrdcached]), |
103 | [],[enable_rrdcached=yes]) | |
104 | ||
a76b432b | 105 | AC_ARG_ENABLE(rrdcgi,AS_HELP_STRING([--disable-rrdcgi],[disable building of rrdcgi]), |
b672fc87 | 106 | [],[enable_rrdcgi=yes]) |
a89dc4f8 | 107 | |
52018ea3 | 108 | AC_ARG_ENABLE(rrd_graph,AS_HELP_STRING([--disable-rrd_graph],[disable all rrd_graph functions]), |
0586762b | 109 | [enable_rrdcgi=$enableval],[enable_rrd_graph=yes]) |
52018ea3 | 110 | |
91ce7bd4 FB |
111 | AC_ARG_ENABLE(rrd_restore,AS_HELP_STRING([--disable-rrd_restore],[disable rrd_restore XML import functions]), |
112 | [],[enable_rrd_restore=yes]) | |
113 | ||
deaef079 | 114 | AM_CONDITIONAL(BUILD_DOCS,[test $enable_docs != no]) |
e24e014c | 115 | AM_CONDITIONAL(BUILD_EXAMPLES,[test $enable_examples != no]) |
e6c92e00 | 116 | AM_CONDITIONAL(BUILD_RRDCGI,[test $enable_rrdcgi != no]) |
38fb0ad1 | 117 | AM_CONDITIONAL(BUILD_RRDCACHED,[test $enable_rrdcached != no]) |
e6c92e00 TO |
118 | |
119 | ||
52018ea3 TO |
120 | if test $enable_rrd_graph != no; then |
121 | AC_DEFINE([HAVE_RRD_GRAPH], [], [is rrd_graph supported by this install]) | |
122 | fi | |
123 | ||
91ce7bd4 FB |
124 | if test $enable_rrd_restore != no; then |
125 | AC_DEFINE([HAVE_RRD_RESTORE], [], [is rrd_restore supported by this install]) | |
126 | fi | |
127 | ||
f3d2fe14 TO |
128 | dnl Check if we run on a system that has fonts |
129 | AC_ARG_WITH(rrd-default-font, | |
130 | [ --with-rrd-default-font=[OPTIONS] set the full path to your default font.], | |
131 | [RRD_DEFAULT_FONT=$withval],[ | |
132 | if test -d ${WINDIR:-nodir}/cour.ttf ; then | |
133 | RRD_DEFAULT_FONT=`cd $WINDIR;pwd`/cour.ttf | |
134 | else | |
00009660 | 135 | RRD_DEFAULT_FONT='"DejaVu Sans Mono,Bitstream Vera Sans Mono,monospace,Courier"' |
f3d2fe14 TO |
136 | fi |
137 | ]) | |
138 | ||
b672fc87 TO |
139 | dnl Use mmap in rrd_update instead of seek+write |
140 | AC_ARG_ENABLE([mmap], | |
a76b432b | 141 | AS_HELP_STRING([--disable-mmap],[disable mmap in rrd_update, use seek+write instead]), |
b672fc87 TO |
142 | [], |
143 | [enable_mmap=yes]) | |
1e48a62f | 144 | |
8c9a864d | 145 | AC_ARG_ENABLE(pthread,AS_HELP_STRING([--disable-pthread],[disable multithread support]), |
b672fc87 TO |
146 | [],[enable_pthread=yes]) |
147 | ||
0033ee5d TO |
148 | AC_ARG_ENABLE([flock], |
149 | AS_HELP_STRING([--disable-flock],[disable file locking]), | |
150 | [], | |
151 | [enable_flock=yes]) | |
b5e33bfe | 152 | if test x$enable_flock != xyes; then |
0033ee5d TO |
153 | AC_DEFINE([DISABLE_FLOCK], [], [disable flock calls in rrdtool]) |
154 | fi | |
155 | ||
81ff9dac | 156 | AC_ARG_ENABLE(static-programs, |
a76b432b | 157 | AS_HELP_STRING([--enable-static-programs],[Build static programs]), |
81ff9dac TO |
158 | [case "${enableval}" in |
159 | yes) staticprogs=yes ;; | |
160 | no) staticprogs=no ;; | |
161 | *) AC_MSG_ERROR(bad value ${enableval} for --enable-static-programs) ;; | |
162 | esac],[staticprogs=no]) | |
163 | AM_CONDITIONAL(STATIC_PROGRAMS,[test "x$staticprogs" = "xyes"]) | |
b672fc87 TO |
164 | |
165 | ||
166 | CONFIGURE_PART(Audit Compilation Environment) | |
167 | ||
168 | ||
169 | dnl Check for the compiler and static/shared library creation. | |
b672fc87 | 170 | AC_PROG_CPP |
c2f7bec9 TO |
171 | AC_PROG_CC |
172 | AM_PROG_CC_C_O | |
b672fc87 TO |
173 | AC_PROG_LIBTOOL |
174 | ||
1e48a62f TO |
175 | dnl Try to detect/use GNU features |
176 | CFLAGS="$CFLAGS -D_GNU_SOURCE" | |
177 | ||
c8386f39 | 178 | dnl check for -Werror separately |
c862de08 | 179 | dnl (quite a few autotool checks do not work with -Werror; also, the |
b98afd17 TO |
180 | dnl check for -Werror fails after checking and adding the other flags) |
181 | AC_CACHE_CHECK([if gcc likes the -Werror flag], rd_cv_gcc_flag__Werror, | |
182 | [AC_COMPILE_IFELSE( | |
183 | [AC_LANG_PROGRAM([[]], [[return 0 ]])], | |
184 | [rd_cv_gcc_flag__Werror="yes"], | |
185 | [rd_cv_gcc_flag__Werror="no"])]) | |
186 | if test "x$rd_cv_gcc_flag__Werror" = "xyes"; then | |
187 | WERROR="-Werror" | |
188 | else | |
189 | WERROR="" | |
190 | fi | |
191 | AC_SUBST(WERROR) | |
192 | ||
f6d0c1c8 TO |
193 | dnl which flags does the compiler support? |
194 | if test "x$GCC" = "xyes"; then | |
f07117d5 | 195 | for flag in -fno-strict-aliasing -Wall -std=gnu99 -pedantic -Wundef -Wshadow -Wpointer-arith -Wcast-align -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline -Wold-style-definition -W; do |
f6d0c1c8 | 196 | oCFLAGS="$CFLAGS" |
be7203e9 TO |
197 | CFLAGS="$CFLAGS $flag" |
198 | cachename=rd_cv_gcc_flag_`echo $flag|sed 's/[[^A-Za-z]]/_/g'` | |
199 | AC_CACHE_CHECK([if gcc likes the $flag flag], $cachename, | |
200 | [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[return 0 ]])],[eval $cachename=yes],[eval $cachename=no])]) | |
201 | if eval test \$$cachename = no; then | |
f6d0c1c8 | 202 | CFLAGS="$oCFLAGS" |
be7203e9 TO |
203 | fi |
204 | done | |
205 | fi | |
206 | ||
737d2959 | 207 | AC_TYPE_LONG_LONG_INT |
b672fc87 | 208 | |
f3d2fe14 TO |
209 | AC_SUBST(RRD_DEFAULT_FONT) |
210 | ||
b672fc87 | 211 | CONFIGURE_PART(Checking for Header Files) |
0cbdf24b | 212 | |
a89dc4f8 TO |
213 | dnl Checks for header files. |
214 | AC_HEADER_STDC | |
215 | AC_HEADER_DIRENT | |
cc773897 | 216 | AC_CHECK_HEADERS(langinfo.h stdint.h inttypes.h libgen.h features.h sys/stat.h sys/types.h fcntl.h fp_class.h malloc.h unistd.h ieeefp.h math.h sys/times.h sys/param.h sys/resource.h signal.h float.h stdio.h stdlib.h errno.h string.h ctype.h grp.h pwd.h glob.h) |
a89dc4f8 TO |
217 | |
218 | dnl Checks for typedefs, structures, and compiler characteristics. | |
219 | AC_C_CONST | |
220 | AC_HEADER_TIME | |
221 | AC_STRUCT_TM | |
37fc6638 | 222 | |
0cbdf24b | 223 | dnl figure out 'stuff' about |
a9fb671a | 224 | HW_FUNC_VA_COPY |
f67fab60 TO |
225 | HW_FUNC_VSNPRINTF |
226 | HW_FUNC_SNPRINTF | |
227 | HW_FUNC_VASPRINTF | |
228 | HW_FUNC_ASPRINTF | |
229 | ||
58cc8383 TO |
230 | CONFIGURE_PART(Test Library Functions) |
231 | ||
a89dc4f8 | 232 | dnl Checks for libraries. |
bca16bd4 TO |
233 | AC_CHECK_FUNC(acos, , AC_CHECK_LIB(m, acos)) |
234 | AC_CHECK_FUNC(round, , AC_CHECK_LIB(m, round)) | |
a89dc4f8 | 235 | |
a1938ec6 | 236 | |
505bfff7 | 237 | |
31b49791 | 238 | dnl add pic flag in any case this makes sure all our code is relocatable |
b3f6be4f TO |
239 | dnl eval `./libtool --config | grep pic_flag=` |
240 | dnl CFLAGS="$CFLAGS $pic_flag" | |
31b49791 | 241 | |
b672fc87 | 242 | |
31b49791 TO |
243 | dnl Checks for library functions. |
244 | AC_FUNC_STRFTIME | |
245 | AC_FUNC_VPRINTF | |
246 | ||
247 | AC_C_BIGENDIAN | |
248 | ||
0cbdf24b | 249 | dnl for each function found we get a definition in config.h |
31b49791 TO |
250 | dnl of the form HAVE_FUNCTION |
251 | ||
71bc8365 | 252 | AC_CHECK_FUNCS(nl_langinfo tzset fsync mbstowcs opendir readdir chdir chroot getgid getuid setgid setuid strndup strerror snprintf vsnprintf vasprintf fpclass class fp_class isnan memmove strchr mktime getrusage gettimeofday getpwnam getgrnam get_current_dir_name) |
f4f9f9c4 TO |
253 | |
254 | AC_FUNC_STRERROR_R | |
58cc8383 TO |
255 | |
256 | CONFIGURE_PART(Map/Fadvis/Madvise checking) | |
257 | ||
258 | dnl Could use these to know if we need to provide a prototype | |
259 | dnl AC_CHECK_DECLS(fdatasync, [], [], [#include <unistd.h>]) | |
260 | ||
261 | dnl check for fdatasync. Solaris has fdatasync in the librt | |
262 | ||
263 | AC_CHECK_FUNCS(fdatasync, [], AC_CHECK_LIB(rt, fdatasync, [LIBS="${LIBS} -lrt"; AC_DEFINE(HAVE_FDATASYNC)],[])) | |
264 | dnl if there is no fdatasync we may get lucky with fsync | |
265 | AC_CHECK_FUNCS(fsync) | |
31b49791 | 266 | |
86ad0116 TO |
267 | dnl check for socket and nsl solaris again ... we need this for the new rrd_daemon stuff |
268 | ||
6ca55fcf WS |
269 | dnl link with ws2_32 (Winsock2 library) in case of MinGW or MinGW-w64 builds |
270 | case "${target}" in | |
271 | *mingw*) LIBS="${LIBS} -lws2_32";; | |
272 | esac | |
86ad0116 TO |
273 | AC_CHECK_FUNCS(socket, [], AC_CHECK_LIB(socket, socket, [LIBS="${LIBS} -lsocket"; AC_DEFINE(HAVE_SOCKET)],[])) |
274 | AC_CHECK_FUNCS(getaddrinfo, [], AC_CHECK_LIB(nsl, getaddrinfo, [LIBS="${LIBS} -lnsl"; AC_DEFINE(HAVE_GETADDRINFO)],[])) | |
4213cef2 | 275 | AC_CHECK_FUNCS(sigwaitinfo, [], AC_CHECK_LIB(rt, sigwaitinfo, [LIBS="${LIBS} -lrt"; AC_DEFINE(HAVE_SIGWAITINFO)],[])) |
965d0f77 | 276 | |
f6d0c1c8 TO |
277 | dnl XXX: dunno about windows.. add AC_CHECK_FUNCS(munmap) there too? |
278 | if test "x$enable_mmap" = "xyes"; then | |
72b4ce71 | 279 | case "$host" in |
f6d0c1c8 TO |
280 | *cygwin*) |
281 | # the normal mmap test does not work in cygwin | |
282 | AC_CHECK_FUNCS(mmap) | |
283 | if test "x$ac_cv_func_mmap" = "xyes"; then | |
284 | ac_cv_func_mmap_fixed_mapped=yes | |
285 | fi | |
286 | ;; | |
287 | *) | |
288 | AC_CHECK_HEADERS(sys/mman.h) | |
289 | AC_FUNC_MMAP | |
61370c60 | 290 | AC_CHECK_FUNCS(mmap munmap) |
d085bb80 | 291 | AC_CHECK_DECLS(madvise, [], [], [#ifdef HAVE_SYS_MMAN_H |
f6d0c1c8 TO |
292 | # include <sys/mman.h> |
293 | #endif]) | |
294 | if test "x$ac_cv_have_decl_madvise" = "xyes"; | |
295 | then | |
296 | AC_CHECK_FUNCS(madvise) | |
297 | else | |
298 | AC_CHECK_FUNCS(posix_madvise) | |
299 | if test "x$ac_cv_func_posix_madvise" != "xyes"; then | |
300 | AC_MSG_WARN([madvise() nor posix_madvise() found.]) | |
301 | fi | |
302 | fi | |
303 | ;; | |
72b4ce71 | 304 | esac |
f6d0c1c8 TO |
305 | if test "x$ac_cv_func_mmap" != "xyes"; |
306 | then | |
307 | AC_MSG_ERROR([--enable-mmap requested but mmap() was not detected]) | |
1e48a62f | 308 | dnl enable_mmap="no" |
f6d0c1c8 | 309 | fi |
965d0f77 TO |
310 | fi |
311 | ||
bf11519c TO |
312 | dnl can we use posix_fadvise |
313 | AC_CHECK_DECLS(posix_fadvise, [], [], [#define _XOPEN_SOURCE 600 | |
1e48a62f | 314 | #include <fcntl.h>]) |
bf11519c TO |
315 | AC_CHECK_FUNCS(posix_fadvise) |
316 | ||
2597f442 TO |
317 | dnl can we use posix_fallocate |
318 | AC_CHECK_FUNCS(posix_fallocate) | |
319 | ||
58cc8383 TO |
320 | CONFIGURE_PART(Libintl Processing) |
321 | ||
0d76c044 | 322 | AM_GNU_GETTEXT_VERSION(0.17) |
4d53064a | 323 | AM_GNU_GETTEXT(external) |
29046a7c | 324 | |
b672fc87 | 325 | CONFIGURE_PART(IEEE Math Checks) |
0cbdf24b | 326 | |
f6d0c1c8 | 327 | |
31b49791 TO |
328 | dnl actual code to check if this works |
329 | AC_CHECK_FUNCS(fpclassify, , | |
330 | [AC_MSG_CHECKING(for fpclassify with <math.h>) | |
9742cdcb TO |
331 | AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <math.h> |
332 | volatile int x;volatile float f; ]], [[x = fpclassify(f)]])],[AC_MSG_RESULT(yes) | |
2c08b353 | 333 | AC_DEFINE(HAVE_FPCLASSIFY)],[AC_MSG_RESULT(no)])]) |
f6d0c1c8 | 334 | |
31b49791 TO |
335 | AC_CHECK_FUNCS(isinf, , |
336 | [AC_MSG_CHECKING(for isinf with <math.h>) | |
9742cdcb TO |
337 | AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <math.h> |
338 | volatile int x;volatile float f; ]], [[x = isinf(f)]])],[AC_MSG_RESULT(yes) | |
31b49791 TO |
339 | AC_DEFINE(HAVE_ISINF)],[AC_MSG_RESULT(no)])]) |
340 | ||
f6d0c1c8 | 341 | dnl finite is BSD, isfinite is C99, so prefer the latter |
738d50c4 | 342 | AC_CACHE_CHECK([whether isfinite is broken],[ac_cv_have_broken_isfinite],[ |
f6d0c1c8 TO |
343 | AC_TRY_RUN([ |
344 | #ifdef HAVE_MATH_H | |
345 | #include <math.h> | |
346 | #endif | |
347 | #ifdef HAVE_FLOAT_H | |
348 | #include <float.h> | |
349 | #endif | |
350 | int main () | |
351 | { | |
352 | #ifdef isfinite | |
353 | #ifdef LDBL_MAX | |
354 | if (!isfinite(LDBL_MAX)) return 1; | |
355 | #endif | |
356 | #ifdef DBL_MAX | |
357 | if (!isfinite(DBL_MAX)) return 1; | |
358 | #endif | |
359 | #endif | |
360 | return 0; | |
738d50c4 | 361 | }],[ac_cv_have_broken_isfinite=no],[ac_cv_have_broken_isfinite=yes],[ |
f6d0c1c8 | 362 | case "${target}" in |
738d50c4 | 363 | hppa*-*-hpux*) ac_cv_have_broken_isfinite=yes ;; |
7f58a869 TO |
364 | *-solaris2.8) ac_cv_have_broken_isfinite=yes ;; |
365 | *-solaris2.9) ac_cv_have_broken_isfinite=yes ;; | |
738d50c4 | 366 | *) ac_cv_have_broken_isfinite=no ;; |
f6d0c1c8 TO |
367 | esac]) |
368 | ]) | |
738d50c4 TO |
369 | |
370 | dnl the test does not seem to work on solaris 2.8 | |
371 | dnl so lets fix this by hand | |
372 | case "${target}" in | |
7f58a869 TO |
373 | *-solaris2.8) ac_cv_have_broken_isfinite=yes ;; |
374 | *-solaris2.9) ac_cv_have_broken_isfinite=yes ;; | |
738d50c4 TO |
375 | esac |
376 | ||
377 | if test "x$ac_cv_have_broken_isfinite" = "xno"; then | |
f6d0c1c8 TO |
378 | AC_DEFINE(HAVE_ISFINITE) |
379 | else | |
738d50c4 TO |
380 | AC_CHECK_FUNCS(finite,[], |
381 | [AC_CHECK_FUNCS(isfinite,[], | |
382 | [AC_MSG_CHECKING(for isfinite with <math.h>) | |
383 | AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <math.h> | |
f6d0c1c8 TO |
384 | volatile int x;volatile float f; ]],[[x = isfinite(f)]])],[AC_MSG_RESULT(yes) |
385 | AC_DEFINE(HAVE_ISFINITE)],[AC_MSG_RESULT(no)])])]) | |
0cbdf24b | 386 | fi |
f6d0c1c8 | 387 | |
31b49791 TO |
388 | AC_FULL_IEEE |
389 | ||
b672fc87 | 390 | CONFIGURE_PART(Resolve Portability Issues) |
1b0379de | 391 | |
2e6d4a7a TO |
392 | GC_TIMEZONE() |
393 | ||
00bc333f TO |
394 | |
395 | AC_CACHE_CHECK(whether sigwait has 2 arguments, | |
396 | ac_cv_libc_sigwait, | |
397 | AC_TRY_COMPILE([ | |
398 | #define _POSIX_PTHREAD_SEMANTICS | |
399 | #include <stdio.h> | |
400 | #include <signal.h>], | |
401 | [sigset_t sigs; int signo; sigwait(&sigs, &signo);], | |
402 | AC_DEFINE(HAVE_SIGWAIT,1,[have two argument posix sigwait]) | |
403 | AC_MSG_RESULT(yes) | |
404 | , | |
0cbdf24b | 405 | AC_MSG_RESULT(no) |
00bc333f TO |
406 | ) |
407 | ) | |
408 | ||
505bfff7 | 409 | |
dcc2ea02 TO |
410 | CHECK_FOR_WORKING_MS_ASYNC |
411 | ||
52326128 TO |
412 | dnl do we have nl_langinfo(_NL_TIME_WEEK_1STDAY) |
413 | AC_CHECK_FUNCS(_NL_TIME_WEEK_1STDAY, , | |
414 | [AC_MSG_CHECKING([for nl_langinfo(_NL_TIME_WEEK_1STDAY) with langinfo.h]) | |
415 | AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <langinfo.h>]], [[nl_langinfo(_NL_TIME_WEEK_1STDAY)]])],[AC_MSG_RESULT(yes) | |
416 | AC_DEFINE(HAVE__NL_TIME_WEEK_1STDAY)],[AC_MSG_RESULT(no)])]) | |
417 | ||
b672fc87 | 418 | dnl what does realloc do if it gets called with a NULL pointer |
1b0379de | 419 | |
b672fc87 TO |
420 | AC_CACHE_CHECK([if realloc can deal with NULL], rd_cv_null_realloc, |
421 | [AC_RUN_IFELSE([AC_LANG_SOURCE([[#include <stdlib.h> | |
422 | int main(void){ | |
423 | char *x = NULL; | |
424 | x = realloc (x,10); | |
425 | if (x==NULL) return 1; | |
426 | return 0; | |
427 | }]])],[rd_cv_null_realloc=yes],[rd_cv_null_realloc=nope],[:])]) | |
8b65ac0e | 428 | |
b672fc87 TO |
429 | if test x"$rd_cv_null_realloc" = xnope; then |
430 | AC_DEFINE(NO_NULL_REALLOC) | |
8b65ac0e TO |
431 | fi |
432 | ||
31b49791 | 433 | AC_LANG_PUSH(C) |
f6537a47 | 434 | dnl solaris has some odd defines it needs in order to properly compile ctime_r |
8b65ac0e TO |
435 | AC_MSG_CHECKING([if ctime_r need special care to act posixly correct]) |
436 | AC_LINK_IFELSE( | |
c5794b2d | 437 | [AC_LANG_PROGRAM( |
8b65ac0e | 438 | [[#include <time.h>]], |
c5794b2d | 439 | [[ctime_r(NULL,NULL,0)]])], |
8b65ac0e TO |
440 | [ CPPFLAGS="$CPPFLAGS -D_POSIX_PTHREAD_SEMANTICS" |
441 | AC_LINK_IFELSE( | |
c5794b2d | 442 | [AC_LANG_PROGRAM( |
8b65ac0e | 443 | [[#include <time.h>]], |
c5794b2d | 444 | [[ctime_r(NULL,NULL)]])], |
8b65ac0e TO |
445 | [AC_MSG_RESULT([yes, this seems to be solaris style])], |
446 | [AC_MSG_ERROR([Can't figure how to compile ctime_r])] | |
447 | ) | |
0cbdf24b | 448 | ], |
8b65ac0e | 449 | [ AC_LINK_IFELSE( |
c5794b2d | 450 | [AC_LANG_PROGRAM( |
603de9af | 451 | [[#ifdef __MINGW32__ |
9f705650 | 452 | #define _POSIX_THREAD_SAFE_FUNCTIONS 200112L |
603de9af WS |
453 | #endif |
454 | #include <time.h>]], | |
c5794b2d | 455 | [[ctime_r(NULL,NULL)]])], |
d05f6777 | 456 | [AC_MSG_RESULT(no)], |
8b65ac0e TO |
457 | [AC_MSG_ERROR([Can't figure how to compile ctime_r])] |
458 | ) | |
0cbdf24b | 459 | ] |
8b65ac0e | 460 | ) |
31b49791 | 461 | AC_LANG_POP(C) |
8b65ac0e TO |
462 | |
463 | dnl Check for pthreads | |
464 | dnl http://autoconf-archive.cryp.to/acx_pthread.m4 | |
0cbdf24b | 465 | |
bdfab891 TO |
466 | AC_SUBST(MULTITHREAD_CFLAGS) |
467 | AC_SUBST(MULTITHREAD_LDFLAGS) | |
468 | ||
0cbdf24b | 469 | if test $enable_pthread != no; then |
8b65ac0e TO |
470 | ACX_PTHREAD([ |
471 | MULTITHREAD_CFLAGS=$PTHREAD_CFLAGS | |
472 | MULTITHREAD_LDFLAGS=$PTHREAD_LIBS | |
473 | ], | |
474 | []) | |
bdfab891 | 475 | fi |
8b65ac0e | 476 | |
e15ce81d TO |
477 | dnl since we use lots of *_r functions all over the code we better |
478 | dnl make sure they are known | |
479 | ||
480 | if test "x$x_rflag" != "xno"; then | |
481 | CPPFLAGS="$CPPFLAGS $x_rflag" | |
482 | fi | |
8b65ac0e | 483 | |
bdfab891 | 484 | AM_CONDITIONAL(BUILD_MULTITHREAD,[test $enable_pthread != no]) |
b672fc87 TO |
485 | |
486 | AC_LANG_PUSH(C) | |
487 | dnl see if we have to include malloc/malloc.h | |
488 | AC_MSG_CHECKING([do we need malloc/malloc.h]) | |
489 | AC_LINK_IFELSE( | |
c5794b2d | 490 | [AC_LANG_PROGRAM( |
b672fc87 | 491 | [[#include <stdlib.h>]], |
c5794b2d | 492 | [[malloc(1)]])], |
b672fc87 TO |
493 | [ AC_MSG_RESULT([nope, works out of the box]) ], |
494 | [ AC_LINK_IFELSE( | |
c5794b2d | 495 | [AC_LANG_PROGRAM( |
b672fc87 TO |
496 | [[#include <stdlib.h> |
497 | #include <malloc/malloc.h>]], | |
c5794b2d SH |
498 | [[malloc(1)]])], |
499 | [AC_DEFINE([MUST_HAVE_MALLOC_MALLOC_H]) | |
b672fc87 | 500 | AC_MSG_RESULT([yes we do])], |
6d14fd1d | 501 | [AC_MSG_ERROR([Can not figure how to compile malloc])] |
b672fc87 | 502 | ) |
0cbdf24b | 503 | ] |
b672fc87 | 504 | ) |
5b2062c9 | 505 | AC_LANG_POP(C) |
57e9361a | 506 | |
c86055b9 | 507 | dnl is time_t 32 of 64 bit ? |
7a78d1a6 | 508 | AC_CHECK_SIZEOF([time_t]) |
b672fc87 | 509 | |
e10fd700 JMV |
510 | AC_CHECK_SIZEOF([long int]) |
511 | ||
c9808db5 | 512 | CONFIGURE_PART(Find 3rd-Party Libraries) |
b672fc87 | 513 | |
2609eb28 TO |
514 | have_libdbi=no |
515 | ||
620ae61e JŠ |
516 | AC_ARG_ENABLE(libdbi,AS_HELP_STRING([--disable-libdbi],[do not build in support for libdbi]), |
517 | [], | |
518 | [enable_libdbi=yes]) | |
519 | ||
520 | AS_IF([test "x$enable_libdbi" != xno], [ | |
0cbdf24b | 521 | AC_CHECK_HEADER(dbi/dbi.h, [ |
b5167667 TO |
522 | AC_CHECK_LIB(dbi, dbi_initialize, [ |
523 | AC_DEFINE(HAVE_LIBDBI,[1],[have got libdbi installed]) | |
4c0ff24a | 524 | LIBS="${LIBS} -ldbi" |
b5167667 TO |
525 | have_libdbi=yes |
526 | ]) | |
527 | ]) | |
311f41ad | 528 | ]) |
2609eb28 | 529 | |
311f41ad | 530 | AM_CONDITIONAL(BUILD_LIBDBI,[test $have_libdbi != no]) |
b672fc87 | 531 | |
e0ec619b SB |
532 | have_librados=no |
533 | ||
620ae61e JŠ |
534 | AC_ARG_ENABLE(librados,AS_HELP_STRING([--disable-librados],[do not build in support for librados]), |
535 | [], | |
536 | [enable_librados=yes]) | |
537 | ||
538 | AS_IF([test "x$enable_librados" != xno], [ | |
e0ec619b SB |
539 | AC_CHECK_HEADER(rados/librados.h, [ |
540 | AC_DEFINE(HAVE_LIBRADOS,[1],[have got librados installed]) | |
541 | LIBS="${LIBS} -lrados" | |
542 | have_librados=yes | |
543 | ]) | |
544 | ]) | |
545 | ||
546 | AM_CONDITIONAL(BUILD_LIBRADOS,[test $have_librados != no]) | |
547 | ||
b5167667 TO |
548 | have_libwrap=no |
549 | ||
620ae61e JŠ |
550 | AC_ARG_ENABLE(libwrap, AS_HELP_STRING([--disable-libwrap], [do not build in support for libwrap (tcp wrapper)]), |
551 | [], | |
552 | [enable_libwrap=yes]) | |
553 | ||
554 | AS_IF([test "x$enable_libwrap" != xno], [ | |
0cbdf24b | 555 | AC_CHECK_HEADER(tcpd.h,[ |
b5167667 TO |
556 | AC_CHECK_FUNCS(hosts_access, [ |
557 | AC_DEFINE(HAVE_LIBWRAP,[1],[have got libwrap installed]) | |
0cbdf24b TO |
558 | have_libwrap=yes |
559 | ], | |
b5167667 TO |
560 | [ |
561 | AC_CHECK_LIB(wrap, hosts_access, [ | |
562 | AC_DEFINE(HAVE_LIBWRAP,[1],[have got libwrap installed]) | |
563 | LIBS="${LIBS} -lwrap" | |
564 | have_libwrap=yes | |
565 | ]) | |
566 | ]) | |
567 | ]) | |
568 | ]) | |
569 | ||
570 | ||
571 | AM_CONDITIONAL(BUILD_LIBWRAP,[test $have_libwrap != no]) | |
b672fc87 | 572 | |
52018ea3 TO |
573 | AM_CONDITIONAL(BUILD_RRDGRAPH,[test $enable_rrd_graph != no]) |
574 | ||
91ce7bd4 FB |
575 | AM_CONDITIONAL(BUILD_RRDRESTORE,[test $enable_rrd_restore != no]) |
576 | ||
cef27b4d | 577 | EX_CHECK_ALL(glib-2.0, glib_check_version, glib.h, glib-2.0, 2.28.7, ftp://ftp.gtk.org/pub/glib/2.28/, "") |
58cc8383 | 578 | |
e35d4604 | 579 | AC_CACHE_CHECK([whether we need to include gthreads for g_thread_init], |
580 | [ac_cv_glibc_g_thread_init], | |
581 | [AC_TRY_COMPILE([#include <glib.h>], | |
582 | [#if !GLIB_CHECK_VERSION(2, 32, 0) | |
583 | # error "glib needs g_thread_init" | |
584 | #endif], | |
585 | [AC_MSG_RESULT(no)], | |
586 | [EX_CHECK_ALL(gthread-2.0, g_thread_init, glib.h, gthread-2.0, x.x.x, "", "") | |
587 | AC_MSG_RESULT(yes)])]) | |
588 | ||
0da4ceb3 TO |
589 | AC_CHECK_FUNC(g_regex_new,[ |
590 | AC_DEFINE(HAVE_G_REGEX_NEW,[1],[our glib has g_regex_new]) | |
591 | ],[ | |
be6bc22d TO |
592 | AC_MSG_CHECKING(if pcre is available to supply the missing regex support in glib) |
593 | AC_MSG_RESULT(checking now ...) | |
594 | EX_CHECK_ALL(pcre, pcre_compile, pcre.h, pcre, x.x.x, [get a newer glib and you will not need pcre at all],"") | |
8743b41d | 595 | AC_CHECK_FUNC(pcre_compile,[ |
0da4ceb3 TO |
596 | AC_DEFINE(HAVE_PCRE_COMPILE,[1],[we have pcre to replace missing regexp support form glib]) |
597 | ],[ | |
598 | AC_MSG_ERROR([you need either glib with g_regex support or libpcre to compile rrdtool.]) | |
599 | ]) | |
be6bc22d TO |
600 | ]) |
601 | ||
602 | ||
603 | ||
6d14fd1d TO |
604 | CORE_LIBS="$LIBS" |
605 | ||
52018ea3 | 606 | if test $enable_rrd_graph != no; then |
74538d88 | 607 | dnl EX_CHECK_ALL(z, zlibVersion, zlib.h, zlib, 1.2.5, http://zlib.net/, "") |
a2e41a7f | 608 | EX_CHECK_ALL(png, png_access_version_number, png.h, libpng, 1.4.8, ftp://ftp.simplesystems.org/pub/libpng/png/src/, "") |
74538d88 TO |
609 | dnl EX_CHECK_ALL(freetype, FT_Init_FreeType, ft2build.h, freetype2, 2.4.6, http://download.savannah.gnu.org/releases/freetype/, /usr/include/freetype2) |
610 | dnl EX_CHECK_ALL(fontconfig, FcInit, fontconfig.h, fontconfig, 2.8.0, http://www.freedesktop.org/software/fontconfig/release/, /usr/include) | |
be6bc22d | 611 | dnl EX_CHECK_ALL(cairo, cairo_font_options_create, cairo.h, cairo-png, 1.10.2, http://cairographics.org/releases/, "") |
5daf953b FB |
612 | dnl EX_CHECK_ALL(cairo, cairo_svg_surface_create, cairo-svg.h, cairo-svg, 1.10.2, http://cairographics.org/releases/, "") |
613 | dnl EX_CHECK_ALL(cairo, cairo_pdf_surface_create, cairo-pdf.h, cairo-pdf, 1.10.2, http://cairographics.org/releases/, "") | |
614 | dnl EX_CHECK_ALL(cairo, cairo_ps_surface_create, cairo-ps.h, cairo-ps, 1.10.2, http://cairographics.org/releases/, "") | |
6b50901a | 615 | EX_CHECK_ALL(pangocairo-1.0, pango_cairo_context_set_font_options, pango/pango.h, pangocairo, 1.28.4, http://ftp.gnome.org/pub/GNOME/sources/pango/1.28, "") |
a9f00dfb | 616 | EX_CHECK_ALL(gobject-2.0, g_object_unref, glib-object.h, gobject-2.0, 2.58.1, https://download.gnome.org/sources/glib/2.58/, "") |
52018ea3 | 617 | |
bcba7428 | 618 | AC_CHECK_FUNCS(pango_font_map_create_context) |
52018ea3 | 619 | fi |
91ce7bd4 FB |
620 | |
621 | if test $enable_rrd_restore != no; then | |
a89aa806 | 622 | EX_CHECK_ALL(xml2, xmlParseFile, libxml/parser.h, libxml-2.0, 2.7.8, http://xmlsoft.org/downloads.html, "") |
91ce7bd4 | 623 | fi |
b672fc87 TO |
624 | |
625 | if test "$EX_CHECK_ALL_ERR" = "YES"; then | |
626 | AC_MSG_ERROR([Please fix the library issues listed above and try again.]) | |
627 | fi | |
628 | ||
3c041eea WS |
629 | dnl Sort and remove duplicate entries in LIBS before assigning to ALL_LIBS |
630 | ALL_LIBS=$(echo "$LIBS"|tr -s " " "\n"|sort -u|tr "\n" " ") | |
6d14fd1d TO |
631 | LIBS= |
632 | ||
633 | AC_SUBST(CORE_LIBS) | |
634 | AC_SUBST(ALL_LIBS) | |
b672fc87 TO |
635 | |
636 | CONFIGURE_PART(Prep for Building Language Bindings) | |
0cbdf24b | 637 | |
13b1511c JMV |
638 | dnl Allow "if enable_rpath" in Makefile.am |
639 | AM_CONDITIONAL(ENABLE_RPATH,[test "x$enable_rpath" = "xyes"]) | |
640 | ||
51e629f8 | 641 | dnl Check for Perl and friends |
2d974270 | 642 | PATH=$PATH:/usr/perl5/bin |
51e629f8 | 643 | export PATH |
37fc6638 | 644 | AC_PATH_PROG(PERL, perl, no) |
51e629f8 TO |
645 | AC_PATH_PROG(POD2MAN, pod2man, no) |
646 | AC_PATH_PROG(POD2HTML, pod2html, no) | |
647 | ||
29ae1780 TO |
648 | dnl for testing a numerical version number comes handy |
649 | dnl the released version are | |
650 | dnl a.bccc | |
651 | dnl the devel versions will be something like | |
652 | dnl a.b999yymmddhh | |
653 | NUMVERS=m4_esyscmd([perl -ne 'my @x=split /\./;printf "%d.%d%03d", @x' VERSION]) | |
654 | AC_SUBST(NUMVERS) | |
f3d2fe14 | 655 | |
a76b432b | 656 | AC_ARG_ENABLE(perl,AS_HELP_STRING([--disable-perl],[do not build the perl modules]), |
f3d2fe14 TO |
657 | [],[enable_perl=yes]) |
658 | ||
659 | ||
e57de196 TO |
660 | AC_ARG_VAR(PERLCC, [C compiler for Perl modules]) |
661 | AC_ARG_VAR(PERLCCFLAGS, [CC flags for Perl modules]) | |
662 | AC_ARG_VAR(PERLLD, [Linker for Perl modules]) | |
663 | AC_ARG_VAR(PERLLDFLAGS, [LD flags for Perl modules]) | |
f4b13c4e | 664 | |
f3d2fe14 | 665 | if test "x$PERL" = "xno" -o x$enable_perl = xno; then |
37fc6638 TO |
666 | COMP_PERL= |
667 | else | |
12bf1a88 | 668 | COMP_PERL="perl-piped perl-shared" |
4b73bd05 TO |
669 | AC_MSG_CHECKING(for the perl version you are running) |
670 | PERL_VERSION=`$PERL -MConfig -e 'print $Config{version}'` | |
671 | AC_MSG_RESULT($PERL_VERSION) | |
f4b13c4e TO |
672 | if test -z "$PERLCC"; then |
673 | AC_MSG_CHECKING(for the C compiler perl wants to use to build its modules) | |
674 | perlcc=`$PERL -MConfig -e 'print $Config{cc}'` | |
675 | AC_MSG_RESULT($perlcc) | |
676 | if test ! -x "$perlcc"; then | |
b608503b | 677 | AC_PATH_PROG(PERL_CC, ${perlcc}, no) |
f4b13c4e TO |
678 | if test "$PERL_CC" = "no"; then |
679 | AC_MSG_WARN([ | |
680 | I would not find the Compiler ($perlcc) that was originally used to compile | |
681 | your perl binary. You should either make sure that this compiler is | |
682 | available on your system, pick an other compiler and set PERLCC | |
683 | appropriately, or use a different perl setup that was compiled locally. | |
684 | ||
685 | I will disable the compilation of the RRDs perl module for now. | |
4b73bd05 | 686 | ]) |
12bf1a88 | 687 | COMP_PERL="perl-piped" |
f4b13c4e | 688 | fi |
0cbdf24b | 689 | fi |
a6e2fe4a | 690 | fi |
37fc6638 | 691 | fi |
b672fc87 | 692 | |
4b73bd05 TO |
693 | AC_MSG_CHECKING(Perl Modules to build) |
694 | AC_MSG_RESULT(${COMP_PERL:-No Perl Modules will be built}) | |
695 | ||
e933aae6 VK |
696 | # Use reproducible build date and time |
697 | if test "$SOURCE_DATE_EPOCH"; then | |
e59f703b | 698 | DATE_FMT="%b %d %Y %H:%M:%S" |
e933aae6 VK |
699 | BUILD_DATE=$(LC_ALL=C date -u -d "@$SOURCE_DATE_EPOCH" "+$DATE_FMT") |
700 | AC_DEFINE_UNQUOTED([BUILD_DATE], ["$BUILD_DATE"], [Use reproducible build date]) | |
701 | fi | |
702 | ||
4b73bd05 | 703 | # Options to pass when configuring perl module |
e7d79940 | 704 | langpref=$prefix |
c862de08 | 705 | test "$langpref" = '$(DESTDIR)NONE' && langpref='$(DESTDIR)'$ac_default_prefix |
e7d79940 | 706 | test "$langpref" = "NONE" && langpref=$ac_default_prefix |
4936b460 | 707 | |
ce493cbc | 708 | PERL_MAKE_OPTIONS="PREFIX=$langpref INSTALL_BASE= LIB=$langpref/lib/perl/$PERL_VERSION" |
4b73bd05 TO |
709 | |
710 | dnl pass additional perl options when generating Makefile from Makefile.PL | |
711 | AC_ARG_ENABLE(perl-site-install, | |
a76b432b | 712 | AS_HELP_STRING([--enable-perl-site-install],[by default the rrdtool perl modules are installed together with rrdtool in $prefix/lib/perl. You have to put a 'use lib qw($prefix/lib/perl)' into your scripts when you want to use them. When you set this option the perl modules will get installed wherever your perl setup thinks it is best.]), |
4b73bd05 TO |
713 | [PERL_MAKE_OPTIONS=],[]) |
714 | ||
f4b13c4e TO |
715 | if test ! -z "$PERLCC"; then |
716 | PERL_MAKE_OPTIONS="$PERL_MAKE_OPTIONS CC=$PERLCC" | |
717 | ||
718 | if test ! -z "$PERLCCFLAGS"; then | |
719 | PERL_MAKE_OPTIONS="$PERL_MAKE_OPTIONS CCFLAGS=$PERLCCFLAGS" | |
720 | fi | |
0cbdf24b | 721 | |
f4b13c4e TO |
722 | if test -z "$PERLLD"; then |
723 | PERLLD=$PERLCC | |
724 | fi | |
725 | PERL_MAKE_OPTIONS="$PERL_MAKE_OPTIONS LD=$PERLLD" | |
0cbdf24b | 726 | |
f4b13c4e TO |
727 | if test ! -z "$PERLLDFLAGS"; then |
728 | PERL_MAKE_OPTIONS="$PERL_MAKE_OPTIONS LDFLAGS=$PERLLDFLAGS" | |
729 | fi | |
730 | fi | |
0cbdf24b | 731 | |
4b73bd05 TO |
732 | AC_ARG_WITH(perl-options, |
733 | [ --with-perl-options=[OPTIONS] options to pass on command-line when | |
734 | generating Makefile from Makefile.PL. If you set this | |
735 | option, interesting things may happen unless you know | |
736 | what you are doing!], | |
737 | [PERL_MAKE_OPTIONS=$withval]) | |
738 | ||
739 | AC_SUBST(PERL_MAKE_OPTIONS) | |
740 | AC_SUBST(PERL) | |
37fc6638 | 741 | AC_SUBST(COMP_PERL) |
4b73bd05 | 742 | AC_SUBST(PERL_VERSION) |
37fc6638 | 743 | |
6d14fd1d TO |
744 | dnl Check for Ruby. |
745 | AC_PATH_PROG(RUBY, ruby, no) | |
746 | ||
a76b432b | 747 | AC_ARG_ENABLE(ruby,AS_HELP_STRING([--disable-ruby],[do not build the ruby modules]), |
6d14fd1d TO |
748 | [],[enable_ruby=yes]) |
749 | ||
b07a3abc | 750 | AC_MSG_CHECKING(if ruby modules can be built) |
6d14fd1d TO |
751 | |
752 | if test "x$RUBY" = "xno" -o x$enable_ruby = xno; then | |
753 | COMP_RUBY= | |
b07a3abc | 754 | AC_MSG_RESULT(No .. Ruby not found or disabled) |
6d14fd1d | 755 | else |
b07a3abc TO |
756 | if $RUBY -e 'require "mkmf"' >/dev/null 2>&1; then |
757 | COMP_RUBY="ruby" | |
758 | AC_MSG_RESULT(YES) | |
759 | else | |
760 | COMP_RUBY= | |
0cbdf24b TO |
761 | AC_MSG_RESULT(Ruby found but mkmf is missing! Install the -dev package) |
762 | fi | |
6d14fd1d TO |
763 | fi |
764 | ||
6d14fd1d TO |
765 | dnl pass additional ruby options when generating Makefile from Makefile.PL |
766 | AC_ARG_ENABLE(ruby-site-install, | |
a76b432b | 767 | AS_HELP_STRING([--enable-ruby-site-install],[by default the rrdtool ruby modules are installed together with rrdtool in $prefix/lib/ruby. You have to add $prefix/lib/ruby/$ruby_version/$sitearch to your $: variable for ruby to find the RRD.so file.]), |
e7d79940 | 768 | [RUBY_MAKE_OPTIONS=],[RUBY_MAKE_OPTIONS="sitedir=$langpref/lib/ruby"]) |
6d14fd1d | 769 | |
0cbdf24b | 770 | |
6d14fd1d TO |
771 | AC_ARG_WITH(ruby-options, |
772 | [ --with-ruby-options=[OPTIONS] options to pass on command-line when | |
773 | generating Makefile from extconf.rb. If you set this | |
774 | option, interesting things may happen unless you know | |
775 | what you are doing!], | |
776 | [RUBY_MAKE_OPTIONS=$withval]) | |
777 | ||
778 | AC_SUBST(RUBY_MAKE_OPTIONS) | |
779 | AC_SUBST(RUBY) | |
780 | AC_SUBST(COMP_RUBY) | |
1181b81a | 781 | AM_CONDITIONAL(BUILD_RUBY,[test $enable_ruby = "yes"]) |
6d14fd1d | 782 | |
e7d79940 TO |
783 | dnl Check for Lua. |
784 | AC_PATH_PROG(LUA, lua, no) | |
785 | ||
a76b432b | 786 | AC_ARG_ENABLE(lua,AS_HELP_STRING([--disable-lua],[do not build the lua modules]), |
e7d79940 TO |
787 | [],[enable_lua=yes]) |
788 | ||
e7d79940 | 789 | COMP_LUA= |
b4cc220b TO |
790 | if test "$LUA" = "no" -o "$enable_lua" = "no"; then |
791 | enable_lua=no | |
e7d79940 | 792 | else |
b4cc220b TO |
793 | AC_MSG_CHECKING(for lua >= 5.0) |
794 | read LUA_MAJOR LUA_MINOR LUA_POINT <<LUA_EOF | |
795 | $($LUA -v 2>&1 | cut -f2 -d' ' | sed -e 's/\./ /g') | |
796 | LUA_EOF | |
797 | if test 0$LUA_MAJOR -lt 5; then | |
798 | AC_MSG_RESULT([no, version found is $LUA_MAJOR.$LUA_MINOR]) | |
799 | else | |
800 | AC_MSG_RESULT([$LUA_MAJOR.$LUA_MINOR found]) | |
71c7ff72 TO |
801 | lua_vdot=$LUA_MAJOR.$LUA_MINOR |
802 | lua_vndot=$LUA_MAJOR$LUA_MINOR | |
b4cc220b | 803 | lua_version=$LUA_MAJOR.$LUA_MINOR.$LUA_POINT |
71c7ff72 TO |
804 | AC_CHECK_HEADERS(lua$lua_vndot/lua.h, |
805 | [AC_CHECK_HEADERS(lua$lua_vndot/lualib.h, | |
806 | [AC_CHECK_HEADER(lua$lua_vndot/lauxlib.h, | |
807 | [lua_headerdir=lua$lua_vndot], | |
b4cc220b TO |
808 | [])], |
809 | [])], | |
71c7ff72 TO |
810 | [AC_CHECK_HEADERS(lua$lua_vdot/lua.h, |
811 | [AC_CHECK_HEADERS(lua$lua_vdot/lualib.h, | |
812 | [AC_CHECK_HEADER(lua$lua_vdot/lauxlib.h, | |
813 | [lua_headerdir=lua$lua_vdot], | |
b4cc220b TO |
814 | [])], |
815 | [])], | |
816 | [AC_CHECK_HEADERS(lua.h, | |
817 | [AC_CHECK_HEADERS(lualib.h, | |
818 | [AC_CHECK_HEADER(lauxlib.h, | |
819 | [lua_headerdir=""], | |
820 | [lua_headerdir="no"])], | |
821 | [])], | |
822 | [])])]) | |
823 | ||
824 | if test "$lua_headerdir" = "no"; then | |
825 | enable_lua=no | |
826 | else | |
827 | COMP_LUA=lua | |
e7d79940 | 828 | fi |
e7d79940 | 829 | |
b4cc220b TO |
830 | if test "$COMP_LUA" != "lua"; then |
831 | enable_lua=no | |
71c7ff72 | 832 | AC_MSG_WARN([Lua $lua_vdot found but not lua.h, lualib.h and lauxlib.h! Please install the -dev packages for Lua $lua_vdot]) |
b4cc220b TO |
833 | else |
834 | # OK, headers found, let's check the libraries (LIBS is not used) | |
835 | LIBS= | |
836 | lua_havelib=no | |
837 | LUA_HAVE_COMPAT51=DONT_HAVE_COMPAT51 | |
7af5f762 YR |
838 | RRD_SEARCH_LIBS(lua_call, [#include <${lua_headerdir:+$lua_headerdir/}lua.h>], [0, 0, 0], lua$lua_vdot lua$lua_vndot lua, |
839 | [AC_SEARCH_LIBS(luaL_openlibs, lua$lua_vdot lua$lua_vndot lua, | |
71c7ff72 TO |
840 | [lua_havelib=LUA$lua_vndot], |
841 | [AC_SEARCH_LIBS(luaL_module, lualib$lua_vndot lualib$lua_vdot lualib, | |
842 | [lua_havelib=$lua_vndot; $LUA -l compat-5.1 2>/dev/null; | |
843 | test "$?" = "0" && LUA_HAVE_COMPAT51=HAVE_COMPAT51], | |
844 | [AC_SEARCH_LIBS(luaL_openlib, lualib$lua_vdot lualib$lua_vndot lualib, | |
845 | [lua_havelib=$lua_vndot], | |
b4cc220b TO |
846 | [COMP_LUA=], [-lm])], [-lm])], [-lm])], |
847 | [COMP_LUA=], [-lm]) | |
848 | lua_libs=$LIBS | |
849 | LIBS= | |
850 | ||
851 | # Options to pass when configuring Lua module | |
852 | if test "$lua_havelib" != "no"; then | |
71c7ff72 TO |
853 | # OK, headers and libs found. Try to set lua flags |
854 | # and modules installation dirs with pkg-config | |
b4cc220b | 855 | if test "$PKGCONFIG" != "no"; then |
71c7ff72 | 856 | if test "$lua_vndot" = "50"; then |
b4cc220b TO |
857 | lua_pkg_prefix=lualib |
858 | else | |
859 | lua_pkg_prefix=lua | |
860 | fi | |
861 | # try with dot, without dot and finally without version | |
71c7ff72 TO |
862 | for f in $lua_pkg_prefix$lua_vdot $lua_pkg_prefix$lua_vndot $lua_pkg_prefix; do |
863 | lua_exec_prefix=`$PKGCONFIG --variable=prefix $f 2>/dev/null` | |
864 | # same binaries? | |
0cbdf24b | 865 | if test "$lua_exec_prefix/bin/lua" = "$LUA"; then |
71c7ff72 TO |
866 | # OK, found CFLAGS. Get Lua LFLAGS and modules install dir |
867 | LUA_CFLAGS=`$PKGCONFIG --cflags $f 2>/dev/null` | |
868 | LUA_LFLAGS=`$PKGCONFIG --libs $f 2>/dev/null` | |
869 | LUA_INSTALL_CMOD=`$PKGCONFIG --variable=INSTALL_CMOD $f 2>/dev/null` | |
870 | LUA_INSTALL_LMOD=`$PKGCONFIG --variable=INSTALL_LMOD $f 2>/dev/null` | |
871 | break | |
b4cc220b TO |
872 | fi |
873 | done | |
874 | fi | |
e7d79940 | 875 | |
9cda1be4 | 876 | LUA_RRD_LIBDIR="$libdir/lua/$lua_vdot" |
71c7ff72 TO |
877 | # if lua 5.0 can't find compat-5.1, force installation of |
878 | # compat-5.1.lua together with RRDtool. | |
879 | if test "$lua_vdot" = "5.0" -a "$LUA_HAVE_COMPAT51" != "HAVE_COMPAT51"; then | |
0cbdf24b | 880 | lua_need_compat51=1 |
71c7ff72 | 881 | LUA_INSTALL_LMOD="$LUA_RRD_LIBDIR" |
b4cc220b | 882 | fi |
71c7ff72 TO |
883 | |
884 | # if not set with pkg-config, use default values in src packages compat-5.1, lua 5.1 | |
885 | if test "$LUA_CFLAGS" = ""; then | |
886 | AC_MSG_WARN(Setting Lua include and lib flags to defaults in compat-5.1 and lua 5.1 sources) | |
887 | LUA_CFLAGS="-I/usr/local/include -I/usr/local/include/lua -I/usr/local/include/lua/$lua_vdot" | |
888 | LUA_LFLAGS="-L/usr/local/lib -L/usr/local/lib/lua -L/usr/local/lib/lua/$lua_vdot $lua_libs" | |
889 | LUA_INSTALL_CMOD="/usr/local/lib/lua/$lua_vdot" | |
b4cc220b | 890 | fi |
e7d79940 | 891 | |
b4cc220b | 892 | dnl pass additional lua options |
71c7ff72 TO |
893 | dnl if lua-site-install is not set, overwrite LUA_INSTALL_CMOD already |
894 | dnl found and install together with RRDtool, under $langpref. | |
b4cc220b | 895 | AC_ARG_ENABLE(lua-site-install, |
a76b432b | 896 | AS_HELP_STRING([--enable-lua-site-install],[by default the lua module is installed together with rrdtool in $prefix/lib/lua/$lua_version. You have to add $prefix/lib/lua/$lua_version/?.so to package.cpath for lua to find 'rrd.so'. For lua 5.0 you may also need to change LUA_PATH to the same dir, to require 'compat-5.1'. When you set this option the lua modules will get installed wherever your Lua setup thinks it is best. WARNING: if you set this option, system lua modules compat-5.1.lua and rrd.so, if any, may be overwritten.]), |
b4cc220b | 897 | [], |
71c7ff72 | 898 | [LUA_INSTALL_CMOD="$LUA_RRD_LIBDIR"; LUA_INSTALL_LMOD="$LUA_RRD_LIBDIR"]) |
b4cc220b | 899 | |
71c7ff72 | 900 | LUA_DEFINES="-DLUA$lua_vndot -D$LUA_HAVE_COMPAT51" |
b4cc220b TO |
901 | AC_SUBST(LUA) |
902 | AC_SUBST(COMP_LUA) | |
b4cc220b | 903 | AC_SUBST(LUA_INSTALL_CMOD) |
71c7ff72 | 904 | AC_SUBST(LUA_INSTALL_LMOD) |
b4cc220b TO |
905 | AC_SUBST(LUA_CFLAGS) |
906 | AC_SUBST(LUA_LFLAGS) | |
71c7ff72 | 907 | AC_SUBST(LUA_DEFINES) |
b4cc220b TO |
908 | else |
909 | enable_lua=no | |
910 | AC_MSG_RESULT([Lua headers found but not the libraries! Please reinstall the dev packages for Lua $LUA_MAJOR.$LUA_MINOR]) | |
911 | fi | |
912 | fi | |
913 | fi | |
914 | fi | |
71c7ff72 TO |
915 | dnl If Lua 5.0, we need compat-5.1. Add ours unless already |
916 | dnl integrated as in Debian/Ubuntu 5.0 -dev packages. | |
917 | AM_CONDITIONAL(LUA_NEED_OUR_COMPAT51, | |
918 | [test "$lua_vdot" = "5.0" -a "$LUA_HAVE_COMPAT51" != "HAVE_COMPAT51"]) | |
919 | AM_CONDITIONAL(LUA_SITE_CINSTALL, [test "$LUA_INSTALL_CMOD" != "$LUA_RRD_LIBDIR"]) | |
920 | AM_CONDITIONAL(LUA_SITE_LINSTALL, [test "$LUA_INSTALL_LMOD" != "$LUA_RRD_LIBDIR"]) | |
921 | AM_CONDITIONAL(LUA50, [test "$lua_vndot" = "50"]) | |
922 | AM_CONDITIONAL(BUILD_LUA, [test "$enable_lua" = "yes"]) | |
6d14fd1d | 923 | |
cf5a9eb4 TO |
924 | enable_tcl_site=no |
925 | ||
a76b432b | 926 | AC_ARG_ENABLE(tcl,AS_HELP_STRING([--disable-tcl],[do not build the tcl modules]), |
e93d17d9 | 927 | [],[enable_tcl=yes]) |
965d0f77 | 928 | |
e93d17d9 TO |
929 | if test "$enable_tcl" = "yes"; then |
930 | dnl Check for Tcl. | |
931 | withval="" | |
932 | AC_ARG_WITH(tcllib,[ --with-tcllib=DIR location of the tclConfig.sh]) | |
933 | enable_tcl=no | |
3973781b | 934 | for dir in $withval /usr/lib /usr/lib64 /usr/local/lib /usr/lib/tcl8.4 /usr/lib/tcl8.3 ; do |
d363449b TO |
935 | AC_MSG_CHECKING(for tclConfig.sh in $dir) |
936 | if test -f "$dir/tclConfig.sh" ; then | |
937 | tcl_config=$dir/tclConfig.sh | |
e93d17d9 | 938 | enable_tcl=yes |
37fc6638 TO |
939 | AC_MSG_RESULT(yes) |
940 | break | |
d363449b | 941 | else |
37fc6638 | 942 | AC_MSG_RESULT(no) |
d363449b TO |
943 | fi |
944 | done | |
37fc6638 | 945 | |
e93d17d9 | 946 | if test "$enable_tcl" = "no"; then |
777e0070 | 947 | AC_MSG_WARN([tclConfig.sh not found - Tcl interface will not be built]) |
e93d17d9 | 948 | else |
37fc6638 | 949 | . $tcl_config |
d363449b | 950 | TCL_PACKAGE_DIR="$TCL_PACKAGE_PATH/tclrrd$VERSION" |
6d0ed52e TO |
951 | if test -n "$TCL_INC_DIR"; then |
952 | TCL_INCLUDE_SPEC="$TCL_INCLUDE_SPEC -I$TCL_INC_DIR" | |
953 | fi | |
e93d17d9 | 954 | fi |
fa922b40 | 955 | AC_ARG_ENABLE(tcl-site,AS_HELP_STRING([--enable-tcl-site],[install the tcl extension in the tcl tree]), |
cf5a9eb4 TO |
956 | [],[enable_tcl_site=yes]) |
957 | ||
37fc6638 TO |
958 | fi |
959 | ||
e93d17d9 | 960 | AM_CONDITIONAL(BUILD_TCL, test "$enable_tcl" = "yes" ) |
cf5a9eb4 | 961 | AM_CONDITIONAL(BUILD_TCL_SITE, test "$enable_tcl_site" = "yes" ) |
37fc6638 | 962 | |
58cc8383 | 963 | |
37fc6638 TO |
964 | AC_SUBST(TCL_PREFIX) |
965 | AC_SUBST(TCL_SHLIB_CFLAGS) | |
966 | AC_SUBST(TCL_SHLIB_LD) | |
967 | AC_SUBST(TCL_SHLIB_SUFFIX) | |
968 | AC_SUBST(TCL_PACKAGE_PATH) | |
969 | AC_SUBST(TCL_LD_SEARCH_FLAGS) | |
0fc6019b | 970 | AC_SUBST(TCL_STUB_LIB_SPEC) |
d363449b TO |
971 | AC_SUBST(TCL_VERSION) |
972 | AC_SUBST(TCL_PACKAGE_DIR) | |
6d0ed52e | 973 | AC_SUBST(TCL_INCLUDE_SPEC) |
37fc6638 | 974 | |
a76b432b | 975 | AC_ARG_ENABLE(python,AS_HELP_STRING([--disable-python],[do not build the python modules]), |
e93d17d9 TO |
976 | [],[enable_python=yes]) |
977 | ||
978 | if test "$enable_python" = "yes"; then | |
3f437d5c | 979 | dnl Check for python |
e93d17d9 TO |
980 | AM_PATH_PYTHON(2.3,[],[enable_python=no]) |
981 | AM_CHECK_PYTHON_HEADERS(,[enable_python=no;AC_MSG_WARN(could not find Python headers)]) | |
982 | fi | |
37fc6638 | 983 | |
7a83911d TO |
984 | if test x$enable_python = xno; then |
985 | COMP_PYTHON= | |
986 | else | |
987 | COMP_PYTHON="python" | |
988 | fi | |
989 | ||
990 | AC_SUBST(COMP_PYTHON) | |
1181b81a | 991 | AM_CONDITIONAL(BUILD_PYTHON,[test $enable_python = "yes"]) |
37fc6638 | 992 | |
deaef079 GZ |
993 | if test $enable_docs != no; then |
994 | ||
37fc6638 | 995 | dnl Check for nroff |
654651f7 TO |
996 | AC_ARG_VAR(NROFF, [path to the local nroff version]) |
997 | AC_PATH_PROGS(NROFF, [gnroff nroff]) | |
998 | if test x$NROFF = x; then | |
999 | AC_MSG_ERROR([I need a copy of *nroff to format the documentation]) | |
1000 | fi | |
1001 | AC_ARG_VAR(TROFF, [path to the local troff version]) | |
1002 | AC_PATH_PROGS(TROFF, [groff troff]) | |
1003 | if test x$TROFF = x; then | |
1004 | AC_MSG_ERROR([I need a copy of *troff to format the documentation]) | |
1005 | fi | |
37fc6638 | 1006 | |
f4b13c4e TO |
1007 | AC_ARG_VAR(RRDDOCDIR, [[DATADIR/doc/PACKAGE-VERSION] Documentation directory]) |
1008 | if test -z "$RRDDOCDIR"; then | |
1009 | RRDDOCDIR='${datadir}/doc/${PACKAGE}-${VERSION}'; fi | |
1010 | ||
deaef079 GZ |
1011 | fi |
1012 | ||
f6537a47 WS |
1013 | # Check for MinGW-w64 build and pass to automake |
1014 | build_mingw_w64=no | |
1015 | AC_MSG_CHECKING([for MinGW-w64 build]) | |
1016 | case "$host" in | |
1017 | *w64-mingw32*) | |
1018 | AC_MSG_RESULT([yes]) | |
1019 | build_mingw_w64=yes | |
1020 | ;; | |
1021 | *) | |
1022 | AC_MSG_RESULT([no]) | |
1023 | ;; | |
1024 | esac | |
1025 | # Pass the conditional to automake | |
1026 | AM_CONDITIONAL([MINGW_W64], [test "$build_mingw_w64" = "yes"]) | |
1027 | ||
134ed0d3 TO |
1028 | # systemd check |
1029 | PKG_PROG_PKG_CONFIG | |
1030 | AC_ARG_WITH([systemdsystemunitdir], | |
1031 | AS_HELP_STRING([--with-systemdsystemunitdir=DIR], [Directory for systemd service files]), | |
1032 | [], [with_systemdsystemunitdir=$($PKG_CONFIG --variable=systemdsystemunitdir systemd)]) | |
1033 | if test "x$with_systemdsystemunitdir" != xno; then | |
1034 | AC_SUBST([systemdsystemunitdir], [$with_systemdsystemunitdir]) | |
1035 | AC_OUTPUT([etc/rrdcached.socket etc/rrdcached.service]) | |
1036 | fi | |
1037 | AM_CONDITIONAL(HAVE_SYSTEMD, [test -n "$with_systemdsystemunitdir" -a "x$with_systemdsystemunitdir" != xno ]) | |
1038 | ||
37fc6638 | 1039 | |
b672fc87 | 1040 | CONFIGURE_PART(Apply Configuration Information) |
0cbdf24b | 1041 | |
deb6b836 TO |
1042 | AC_CONFIG_FILES([examples/shared-demo.pl]) |
1043 | AC_CONFIG_FILES([examples/piped-demo.pl]) | |
1044 | AC_CONFIG_FILES([examples/stripes.pl]) | |
1045 | AC_CONFIG_FILES([examples/bigtops.pl]) | |
1046 | AC_CONFIG_FILES([examples/minmax.pl]) | |
deb6b836 | 1047 | AC_CONFIG_FILES([examples/4charts.pl]) |
7adfdafc | 1048 | AC_CONFIG_FILES([examples/perftest.pl]) |
deb6b836 | 1049 | AC_CONFIG_FILES([examples/Makefile]) |
873f61f9 | 1050 | AC_CONFIG_FILES([examples/rrdcached/Makefile]) |
4fa84a99 | 1051 | AC_CONFIG_FILES([etc/rrdcached-default-lsb]) |
64e74e75 | 1052 | AC_CONFIG_FILES([tests/Makefile]) |
deb6b836 | 1053 | AC_CONFIG_FILES([doc/Makefile]) |
020fde35 | 1054 | AC_CONFIG_FILES([etc/Makefile]) |
0cbdf24b | 1055 | AC_CONFIG_FILES([po/Makefile.in]) |
deb6b836 | 1056 | AC_CONFIG_FILES([src/Makefile]) |
9e5b1bb7 | 1057 | AC_CONFIG_FILES([src/librrd.pc]) |
deb6b836 TO |
1058 | AC_CONFIG_FILES([bindings/Makefile]) |
1059 | AC_CONFIG_FILES([bindings/tcl/Makefile]) | |
1060 | AC_CONFIG_FILES([bindings/tcl/ifOctets.tcl]) | |
125593ce | 1061 | AC_CONFIG_FILES([bindings/lua/Makefile]) |
0cbdf24b | 1062 | AC_CONFIG_FILES([Makefile]) |
72b4ce71 | 1063 | |
398cb63e | 1064 | AC_CONFIG_COMMANDS([default],[[ chmod +x examples/*.pl]],[[]]) |
bb94a87f | 1065 | |
cdab6835 | 1066 | AC_OUTPUT |
37fc6638 TO |
1067 | |
1068 | AC_MSG_CHECKING(in) | |
1069 | AC_MSG_RESULT(and out again) | |
1070 | ||
eea2e745 | 1071 | echo $ECHO_N "ordering CD from https://tobi.oetiker.ch/wish $ECHO_C" 1>&6 |
37fc6638 | 1072 | sleep 1 |
cdab6835 | 1073 | echo $ECHO_N ".$ECHO_C" 1>&6 |
37fc6638 | 1074 | sleep 1 |
cdab6835 | 1075 | echo $ECHO_N ".$ECHO_C" 1>&6 |
37fc6638 | 1076 | sleep 1 |
cdab6835 | 1077 | echo $ECHO_N ".$ECHO_C" 1>&6 |
37fc6638 | 1078 | sleep 1 |
cdab6835 | 1079 | echo $ECHO_N ".$ECHO_C" 1>&6 |
37fc6638 TO |
1080 | sleep 1 |
1081 | AC_MSG_RESULT([ just kidding ;-)]) | |
1082 | echo | |
1083 | echo "----------------------------------------------------------------" | |
1084 | echo "Config is DONE!" | |
1085 | echo | |
1e48a62f | 1086 | echo " With MMAP IO: $enable_mmap" |
0033ee5d | 1087 | echo " With Locking: $enable_flock" |
52018ea3 | 1088 | echo " Build rrd_graph: $enable_rrd_graph" |
91ce7bd4 | 1089 | echo " Build rrd_restore: $enable_rrd_restore" |
81ff9dac | 1090 | echo " Static programs: $staticprogs" |
e93d17d9 TO |
1091 | echo " Perl Modules: $COMP_PERL" |
1092 | echo " Perl Binary: $PERL" | |
1093 | echo " Perl Version: $PERL_VERSION" | |
1094 | echo " Perl Options: $PERL_MAKE_OPTIONS" | |
6d14fd1d TO |
1095 | echo " Ruby Modules: $COMP_RUBY" |
1096 | echo " Ruby Binary: $RUBY" | |
1097 | echo " Ruby Options: $RUBY_MAKE_OPTIONS" | |
b4cc220b | 1098 | echo " Build Lua Bindings: $enable_lua" |
71c7ff72 | 1099 | if test "$enable_lua" = "yes"; then |
e7d79940 | 1100 | echo " Lua Binary: $LUA" |
b4cc220b | 1101 | echo " Lua Version: $lua_version" |
71c7ff72 TO |
1102 | echo " Lua C-modules dir: $LUA_INSTALL_CMOD" |
1103 | if test "$lua_need_compat51" = "1"; then | |
1104 | echo " Lua Lua-modules dir: $LUA_INSTALL_LMOD" | |
1105 | fi | |
1106 | fi | |
020fde35 | 1107 | echo " Systemd unit dir: $with_systemdsystemunitdir" |
e93d17d9 TO |
1108 | echo " Build Tcl Bindings: $enable_tcl" |
1109 | echo " Build Python Bindings: $enable_python" | |
6be43f4a WS |
1110 | echo " Python Binary: $PYTHON" |
1111 | echo " Python Version: $PYTHON_VERSION" | |
e24e014c | 1112 | echo " Build examples: $enable_examples" |
38fb0ad1 | 1113 | echo " Build rrdcached: $enable_rrdcached" |
e93d17d9 TO |
1114 | echo " Build rrdcgi: $enable_rrdcgi" |
1115 | echo " Build librrd MT: $enable_pthread" | |
c862de08 | 1116 | echo " Use gettext: $USE_NLS" |
311f41ad | 1117 | echo " With libDBI: $have_libdbi" |
e0ec619b | 1118 | echo " With librados: $have_librados" |
2740ecc9 | 1119 | echo " With libwrap: $have_libwrap" |
134ed0d3 | 1120 | echo " With systemd dir: $with_systemdsystemunitdir" |
e3f3fc54 | 1121 | echo |
58cc8383 | 1122 | echo " Libraries: $ALL_LIBS" |
f37148b1 | 1123 | echo |
37fc6638 TO |
1124 | echo "Type 'make' to compile the software and use 'make install' to " |
1125 | echo "install everything to: $prefix." | |
020fde35 TO |
1126 | if test "x$with_systemdsystemunitdir" != xno; then |
1127 | echo | |
1128 | echo "Type 'make etc-install' to install systemd support for rrdcached" | |
1129 | fi | |
0cbdf24b | 1130 | echo |
37fc6638 | 1131 | echo " ... that wishlist is NO JOKE. If you find RRDtool useful" |
eea2e745 | 1132 | echo "make me happy. Go to https://tobi.oetiker.ch/wish and" |
37fc6638 | 1133 | echo "place an order." |
0cbdf24b | 1134 | echo |
37fc6638 TO |
1135 | echo " -- Tobi Oetiker <tobi@oetiker.ch>" |
1136 | echo "----------------------------------------------------------------" |