-
Notifications
You must be signed in to change notification settings - Fork 11
/
configure.ac
91 lines (72 loc) · 3.06 KB
/
configure.ac
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
m4_include([version.m4])
AC_INIT([ding-libs],
VERSION_NUMBER,
AC_CONFIG_SRCDIR([README])
AC_CONFIG_AUX_DIR([build])
m4_ifdef([AC_USE_SYSTEM_EXTENSIONS],
[AC_USE_SYSTEM_EXTENSIONS],
[AC_GNU_SOURCE])
AM_INIT_AUTOMAKE([-Wall foreign subdir-objects])
AM_PROG_CC_C_O
m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
AC_PROG_LIBTOOL
AC_CONFIG_MACRO_DIR([m4])
AC_PROG_INSTALL
AM_CONDITIONAL([HAVE_GCC], [test "$ac_cv_prog_gcc" = yes])
PKG_CHECK_MODULES([CHECK], [check >= 0.9.5], [have_check=1], [have_check=])
if test x$have_check = x; then
AC_MSG_WARN([Without the 'CHECK' libraries, you will be unable to run all tests in the 'make check' suite])
fi
AM_CONDITIONAL([HAVE_CHECK], [test x$have_check != x])
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES])
AC_CONFIG_HEADERS([config.h])
AC_SUBST([PRERELEASE_VERSION],
PRERELEASE_VERSION_NUMBER)
AC_SUBST([PATH_UTILS_VERSION], PATH_UTILS_VERSION_NUMBER)
AC_SUBST([DHASH_VERSION], DHASH_VERSION_NUMBER)
AC_SUBST([COLLECTION_VERSION], COLLECTION_VERSION_NUMBER)
AC_SUBST([REF_ARRAY_VERSION], REF_ARRAY_VERSION_NUMBER)
AC_SUBST([BASICOBJECTS_VERSION], BASICOBJECTS_VERSION_NUMBER)
AC_SUBST([INI_CONFIG_VERSION], INI_CONFIG_VERSION_NUMBER)
AM_CONDITIONAL([GIT_CHECKOUT], [git log -1 >/dev/null 2>&1])
AC_PATH_PROG([DOXYGEN], [doxygen], [false])
AM_CONDITIONAL([HAVE_DOXYGEN], [test x$DOXYGEN != xfalse ])
# Enable trace build
AC_ARG_ENABLE([trace],
[AS_HELP_STRING([--enable-trace[=LEVEL]],[build with low level tracing enabled])],
[trace_level="$enableval"],
[trace_level="0"])
AS_IF([test ["$trace_level" -gt "0"] -a ["$trace_level" -lt "8"] ],[AC_SUBST([TRACE_VAR],["-DTRACE_LEVEL=$trace_level"])])
AC_CHECK_SIZEOF([long])
AC_CHECK_SIZEOF([long long])
gl_LD_VERSION_SCRIPT
AM_ICONV
AM_GNU_GETTEXT([external])
AM_GNU_GETTEXT_VERSION([0.14.4])
AC_CHECK_FUNC([strcasestr],
AC_DEFINE([HAVE_STRCASESTR],
[1],
[Define if strcasestr exists]),
AC_MSG_ERROR("Platform must support strcasestr"))
AC_CHECK_FUNC([getline],
AC_DEFINE([HAVE_GETLINE],
[1],
[Define if getline() exists]),
AC_MSG_ERROR("Platform must support getline()"))
AC_DEFINE([COL_MAX_DATA], [65535], [Max length of the data block allowed in the collection value.])
AC_DEFINE([MAX_KEY], [1024], [Max length of the key in the INI file.])
#Support old versions of autotools that don't provide docdir
AC_SUBST([docdir])
if test x$docdir = x; then
AC_SUBST([docdir], ${datadir}/doc/AC_PACKAGE_NAME)
fi
AC_CONFIG_FILES([Makefile contrib/ding-libs.spec
path_utils/path_utils.cfg.doxy path_utils/path_utils.pc
dhash/dhash.pc
collection/collection.cfg.doxy collection/collection.pc
refarray/ref_array.cfg.doxy refarray/ref_array.pc
basicobjects/basicobjects.cfg.doxy
basicobjects/basicobjects.pc
ini/ini_config.cfg.doxy ini/ini_config.pc])
AC_OUTPUT