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

Last change on this file since 21364 was 21364, checked in by ak19, 14 years ago

New configuration and compilation flag ENABLE_JNI added which will be disabled by default for GS2 since in general GS doesn't need mg and mgpp compiled up with jni. GS3

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