source: main/trunk/greenstone2/common-src/indexers/configure.ac@ 22378

Last change on this file since 22378 was 22378, checked in by sjm84, 14 years ago

Greenstone 2 now compiles and installs on 64-bit linux machines

  • Property svn:keywords set to Author Date Id Revision
File size: 3.0 KB
Line 
1
2dnl AC_INIT(mgpp/text/MGQuery.cpp)
3dnl http://www.gnu.org/software/hello/manual/autoconf/Initializing-configure.html
4AC_INIT()
5
6
7dnl
8dnl Disable accent folding
9dnl
10AC_ARG_ENABLE(accentfold, [ --disable-accentfold Disable Accent Folding for MGPP], ENABLE_ACCENTFOLD=$enableval, ENABLE_ACCENTFOLD=yes)
11if test $ENABLE_ACCENTFOLD = "yes" -o $ENABLE_ACCENTFOLD = "1" ; then
12 ENABLE_ACCENTFOLD=1
13 AC_DEFINE(ENABLE_ACCENTFOLD,[])
14else
15 ENABLE_ACCENTFOLD=0
16fi
17AC_SUBST(ENABLE_ACCENTFOLD)
18
19
20dnl
21dnl Set compilation of JNI parts of MG and MGPP indexers (disabled by default, which is GS2's default behaviour)
22dnl
23AC_ARG_ENABLE(jni, [ --enable-jni Enable JNI compilation], ENABLE_JNI=$enableval, ENABLE_JNI=no)
24if test $ENABLE_JNI = "yes" -o $ENABLE_JNI = "1" ; then
25 ENABLE_JNI=1
26 AC_DEFINE(ENABLE_JNI,[])
27else
28 ENABLE_JNI=0
29fi
30AC_SUBST(ENABLE_JNI)
31
32
33dnl
34dnl Set compilation of MG (enabled by default)
35dnl
36AC_ARG_ENABLE(mg, [ --disable-mg Disable MG compilation], ENABLE_MG=$enableval, ENABLE_MG=yes)
37if test $ENABLE_MG = "yes" -o $ENABLE_MG = "1" ; then
38 ENABLE_MG=1
39 AC_DEFINE(ENABLE_MG,[])
40else
41 ENABLE_MG=0
42fi
43AC_SUBST(ENABLE_MG)
44
45
46dnl
47dnl Set compilation of MGPP (enabled by default)
48dnl
49AC_ARG_ENABLE(mgpp, [ --disable-mgpp Disable MGPP compilation], ENABLE_MGPP=$enableval, ENABLE_MGPP=yes)
50if test $ENABLE_MGPP = "yes" -o $ENABLE_MGPP = "1" ; then
51 ENABLE_MGPP=1
52 AC_DEFINE(ENABLE_MGPP,[])
53else
54 ENABLE_MGPP=0
55fi
56AC_SUBST(ENABLE_MGPP)
57
58dnl
59dnl Set compilation of Lucene (enabled by default)
60dnl
61AC_ARG_ENABLE(lucene, [ --disable-lucene Disable Lucene compilation], ENABLE_LUCENE=$enableval, ENABLE_LUCENE=yes)
62if test $ENABLE_LUCENE = "yes" -o $ENABLE_LUCENE = "1" ; then
63 ENABLE_LUCENE=1
64 AC_DEFINE(ENABLE_LUCENE,[])
65else
66 ENABLE_LUCENE=0
67fi
68AC_SUBST(ENABLE_LUCENE)
69
70
71AC_DEFINE_UNQUOTED(COMPAT32BITFLAGS, $COMPAT32BITFLAGS)
72AC_SUBST(COMPAT32BITFLAGS)
73
74dnl
75dnl Make sure Javac and Java are available if were are compiling Lucene
76dnl
77
78if test "$ENABLE_LUCENE" = "1" ; then
79 AC_PROG_JAVAC
80 AC_PROG_JAVA
81fi
82
83dnl
84dnl Specify location of unac - if specified, will be passed to cascading configures
85dnl
86AC_ARG_WITH(unac, [ --with-unac=dir Use specified unac directory], UNAC_DIR=$withval)
87
88dnl
89dnl Specify location of libiconv - if specified, will be passed to cascading configures
90dnl
91AC_ARG_WITH(libiconv, [ --with-libiconv-prefix=dir Use specified libiconv directory], LIBICONV_DIR=$withval)
92
93if test $ENABLE_ACCENTFOLD = 1; then
94AC_CONFIG_SUBDIRS(packages/unac)
95fi
96
97dnl AC_CONFIG_SUBDIRS(mg mgpp)
98
99if test $ENABLE_MG = 1; then
100if test ! -d mg; then
101echo "***** Folder mg does not exist, cannot ENABLE_MG.";
102exit 1;
103fi
104AC_CONFIG_SUBDIRS(mg)
105fi
106
107if test $ENABLE_MGPP = 1; then
108if test ! -d mgpp; then
109echo "***** Folder mgpp does not exist, cannot ENABLE_MGPP.";
110exit 1;
111fi
112AC_CONFIG_SUBDIRS(mgpp)
113fi
114
115if test $ENABLE_LUCENE = 1; then
116if test ! -d lucene-gs; then
117echo "***** Folder lucene-gs does not exist, cannot ENABLE_LUCENE.";
118exit 1;
119fi
120fi
121
122AC_OUTPUT(Makefile)
Note: See TracBrowser for help on using the repository browser.