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
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
|
AC_INIT([zeitgeist], [0.9.0], [dev@lists.zeitgeist-project.com], [zeitgeist])
AC_CONFIG_SRCDIR([Makefile.am])
AC_CONFIG_HEADERS(config.h)
AM_INIT_AUTOMAKE([dist-bzip2 no-dist-gzip])
AM_MAINTAINER_MODE([enable])
AM_PATH_PYTHON
AC_PROG_CC
AM_PROG_CC_C_O
AC_PROG_CXX
AC_DISABLE_STATIC
AC_PROG_LIBTOOL
AM_PROG_VALAC([0.14.0])
AM_SILENT_RULES([yes])
AH_TEMPLATE([GETTEXT_PACKAGE], [Package name for gettext])
GETTEXT_PACKAGE=zeitgeist
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE, "$GETTEXT_PACKAGE")
AC_SUBST(GETTEXT_PACKAGE)
AM_GLIB_GNU_GETTEXT
IT_PROG_INTLTOOL([0.35.0])
AC_SUBST(CFLAGS)
AC_SUBST(CPPFLAGS)
AC_SUBST(LDFLAGS)
GLIB_REQUIRED=2.26.0
SQLITE_REQUIRED=3.7
ZEITGEIST_REQUIRED="glib-2.0 >= $GLIB_REQUIRED
gobject-2.0 >= $GLIB_REQUIRED
gio-unix-2.0 >= $GLIB_REQUIRED
sqlite3 >= $SQLITE_REQUIRED"
PKG_CHECK_MODULES(ZEITGEIST, [$ZEITGEIST_REQUIRED])
AC_SUBST(ZEITGEIST_CFLAGS)
AC_SUBST(ZEITGEIST_LIBS)
#################################################
# Dee-ICU check
#################################################
DEE_ICU_REQUIRED=1.0.2
AC_ARG_WITH([dee-icu],
AS_HELP_STRING([--with-dee-icu[=@<:@no/auto/yes@:>@]],
[Build the FTS extension with dee-icu]),
[with_dee_icu=$withval],
[with_dee_icu="auto"])
if test "x$with_dee_icu" = "xauto" ; then
PKG_CHECK_EXISTS([dee-icu-1.0 >= $DEE_ICU_REQUIRED],
with_dee_icu="yes",
with_dee_icu="no")
fi
if test "x$with_dee_icu" = "xyes" ; then
PKG_CHECK_MODULES(DEE_ICU, dee-icu-1.0 >= $DEE_ICU_REQUIRED)
AC_DEFINE(HAVE_DEE_ICU, 1, [Have dee-icu])
fi
AM_CONDITIONAL(HAVE_DEE_ICU, test "x$with_dee_icu" = "xyes")
#################################################
# DBus service
#################################################
AC_ARG_WITH([session_bus_services_dir],
AC_HELP_STRING([--with-session-bus-services-dir], [Path to DBus services directory]))
if test "x$with_session_bus_services_dir" = "x" ; then
PKG_CHECK_MODULES(DBUS_MODULE, "dbus-1")
services_dir="`$PKG_CONFIG --variable session_bus_services_dir dbus-1`"
else
services_dir="$with_session_bus_services_dir"
fi
DBUS_SERVICES_DIR="$services_dir"
AC_SUBST(DBUS_SERVICES_DIR)
#################################################
# Configure options: --disable-fts.
#################################################
AC_ARG_ENABLE([fts],
AS_HELP_STRING([--disable-fts], [Build without FTS++ extension]),
[enable_fts=$enableval],[enable_fts="yes"])
AM_CONDITIONAL(HAVE_FTS, test "x$enable_fts" != "xno")
AC_CONFIG_FILES([
Makefile
src/Makefile
extensions/Makefile
extensions/fts++/Makefile
extensions/fts++/test/Makefile
data/Makefile
data/ontology/Makefile
python/Makefile
test/Makefile
test/dbus/Makefile
test/direct/Makefile
doc/Makefile
po/Makefile.in
])
# check for Xapian
AC_CHECK_PROG(HAVE_XAPIAN, xapian-config, yes, no)
if test "x$HAVE_XAPIAN" = "xno"; then
AC_MSG_ERROR("You need the Xapian development files in order to compile Zeitgeist")
fi
XAPIAN_LIBS=`xapian-config --libs`
XAPIAN_CXXFLAGS=`xapian-config --cxxflags`
AC_SUBST(XAPIAN_LIBS)
AC_SUBST(XAPIAN_CXXFLAGS)
# check for rapper
AC_CHECK_PROG(HAVE_RAPPER, rapper, yes, no)
if test "x$HAVE_RAPPER" = "xno"; then
AC_MSG_ERROR("You need the tool `rapper' from the `raptor-utils' package in order to compile Zeitgeist")
fi
# check for python-rdflib
AC_MSG_CHECKING([for python-rdflib])
echo "import rdflib" | python - 2>/dev/null
if test $? -ne 0 ; then
AC_MSG_FAILURE([failed. Please install the python-rdflib package.])
else
AC_MSG_RESULT([yes])
fi
AC_OUTPUT
cat <<EOF
${PACKAGE}-${VERSION}
Build Environment
Install Prefix: ${prefix}
Optional dependencies
fts++: ${enable_fts}
dee-icu: ${with_dee_icu}
EOF
|