1 | AC_INIT([Rappture],[1.1],[rappture@nanohub.org]) |
---|
2 | dnl AC_CONFIG_HEADER(src/core/RpConfig.h) |
---|
3 | AC_CONFIG_AUX_DIR(cf) |
---|
4 | AC_CONFIG_HEADER(src/core/config.h) |
---|
5 | |
---|
6 | #------------------------------------------------------------------------ |
---|
7 | # Handle the --prefix=... option |
---|
8 | #------------------------------------------------------------------------ |
---|
9 | |
---|
10 | if test "${prefix}" = "NONE"; then |
---|
11 | prefix=/usr/local |
---|
12 | fi |
---|
13 | if test "${exec_prefix}" = "NONE"; then |
---|
14 | exec_prefix=$prefix |
---|
15 | fi |
---|
16 | |
---|
17 | if test "${libdir}" != "${prefix}/lib"; then |
---|
18 | LIB_SEARCH_DIRS="-L${prefix}/lib -L${libdir}" |
---|
19 | else |
---|
20 | LIB_SEARCH_DIRS="-L${libdir}" |
---|
21 | fi |
---|
22 | |
---|
23 | AC_SUBST(LIB_SEARCH_DIRS) |
---|
24 | |
---|
25 | AC_PROG_INSTALL |
---|
26 | AC_PROG_MAKE_SET |
---|
27 | |
---|
28 | # Check for C, C++, and FORTRAN |
---|
29 | AC_PROG_CC |
---|
30 | AC_PROG_CXX |
---|
31 | # Avoid g95 |
---|
32 | AC_PROG_INSTALL |
---|
33 | AC_PROG_RANLIB |
---|
34 | AC_PROG_LN_S |
---|
35 | AC_PROG_MKDIR_P |
---|
36 | |
---|
37 | AC_PROG_F77([g77 gfortran f77 fort77 f90 xlf xlf90 fl32]) |
---|
38 | |
---|
39 | AC_LANG([C]) |
---|
40 | |
---|
41 | AC_HEADER_STDC |
---|
42 | AC_CHECK_FUNC(atol,,AC_MSG_ERROR(oops! no atol ?!?)) |
---|
43 | |
---|
44 | AC_LANG([C++]) |
---|
45 | |
---|
46 | AC_CHECK_FUNCS([sysinfo]) |
---|
47 | AC_CHECK_HEADERS(sys/sysinfo.h) |
---|
48 | |
---|
49 | AC_CHECK_LIB(m, main,,AC_MSG_ERROR(librappture requires libm)) |
---|
50 | AC_CHECK_LIB(stdc++, main,,AC_MSG_ERROR(librappture requires libstdc++)) |
---|
51 | AC_CHECK_HEADERS(algorithm,,AC_MSG_WARN(STL classes missing ?)) |
---|
52 | AC_CHECK_HEADERS(cctype,,AC_MSG_WARN(STL classes missing ?)) |
---|
53 | AC_CHECK_HEADERS(cfloat,,AC_MSG_WARN(STL classes missing ?)) |
---|
54 | AC_CHECK_HEADERS(cmath,,AC_MSG_WARN(STL classes missing ?)) |
---|
55 | AC_CHECK_HEADERS(cstdio,,AC_MSG_WARN(STL classes missing ?)) |
---|
56 | AC_CHECK_HEADERS(cstdlib,,AC_MSG_WARN(STL classes missing ?)) |
---|
57 | AC_CHECK_HEADERS(cstring,,AC_MSG_WARN(STL classes missing ?)) |
---|
58 | AC_CHECK_HEADERS(fstream,,AC_MSG_WARN(STL classes missing ?)) |
---|
59 | AC_CHECK_HEADERS(list,,AC_MSG_WARN(STL classes missing ?)) |
---|
60 | AC_CHECK_HEADERS(iostream,,AC_MSG_WARN(STL classes missing ?)) |
---|
61 | AC_CHECK_HEADERS(iterator,,AC_MSG_WARN(STL classes missing ?)) |
---|
62 | AC_CHECK_HEADERS(sstream,,AC_MSG_WARN(STL classes missing ?)) |
---|
63 | AC_CHECK_HEADERS(stack,,AC_MSG_WARN(STL classes missing ?)) |
---|
64 | AC_CHECK_HEADERS(string,,AC_MSG_WARN(STL classes missing ?)) |
---|
65 | AC_CHECK_HEADERS(vector,,AC_MSG_WARN(STL classes missing ?)) |
---|
66 | |
---|
67 | AC_CHECK_HEADERS(assert.h,,AC_MSG_WARN(C headers missing ?)) |
---|
68 | AC_CHECK_HEADERS(ctype.h,,AC_MSG_WARN(C headers missing ?)) |
---|
69 | AC_CHECK_HEADERS(errno.h,,AC_MSG_WARN(C headers missing ?)) |
---|
70 | AC_CHECK_HEADERS(limits.h,,AC_MSG_WARN(C headers missing ?)) |
---|
71 | AC_CHECK_HEADERS(string.h,,AC_MSG_WARN(C headers missing ?)) |
---|
72 | AC_CHECK_HEADERS(stdlib.h,,AC_MSG_WARN(C headers missing ?)) |
---|
73 | AC_CHECK_HEADERS(stddef.h,,AC_MSG_WARN(C headers missing ?)) |
---|
74 | AC_CHECK_HEADERS(float.h,,AC_MSG_WARN(C headers missing ?)) |
---|
75 | AC_CHECK_HEADERS(math.h,,AC_MSG_WARN(C headers missing ?)) |
---|
76 | dnl AC_CHECK_HEADERS(ieeefp.h,,AC_MSG_WARN(C headers missing ?)) |
---|
77 | AC_CHECK_HEADERS(malloc.h,,AC_MSG_WARN(C headers missing ?)) |
---|
78 | AC_CHECK_HEADERS(memory.h,,AC_MSG_WARN(C headers missing ?)) |
---|
79 | AC_CHECK_HEADERS(unistd.h,,AC_MSG_WARN(C headers missing ?)) |
---|
80 | |
---|
81 | AC_CHECK_HEADERS(inttypes.h,,AC_MSG_WARN(C headers missing ?)) |
---|
82 | if test "${ac_cv_header_inttypes_h}" = "yes" ; then |
---|
83 | HAVE_INTTYPES_H=1 |
---|
84 | else |
---|
85 | HAVE_INTTYPES_H=0 |
---|
86 | fi |
---|
87 | AC_SUBST(HAVE_INTTYPES_H) |
---|
88 | |
---|
89 | |
---|
90 | SC_CONFIG_CFLAGS |
---|
91 | |
---|
92 | make_command="" |
---|
93 | for m in "$MAKE" make gmake gnumake ; do |
---|
94 | if test "x${m}" != "x" ; then |
---|
95 | if ( sh -c "$m --version" 2>/dev/null | grep GNU >/dev/null ) ; then |
---|
96 | make_command=$m; break; |
---|
97 | fi |
---|
98 | fi |
---|
99 | done |
---|
100 | if test "x${make_command}" = "x" ; then |
---|
101 | AC_MSG_ERROR([Requires GNU make. You can specify a version with \$MAKE]) |
---|
102 | fi |
---|
103 | AC_SUBST(MAKE, ${make_command}) |
---|
104 | |
---|
105 | AC_ARG_ENABLE( |
---|
106 | [gui], |
---|
107 | [AS_HELP_STRING([--enable-gui], [build code related to the graphical user interface @<:@default=yes@:>@])], |
---|
108 | [], |
---|
109 | [enable_gui=yes]) |
---|
110 | |
---|
111 | ENABLE_GUI= |
---|
112 | if test "$enable_gui" != "no" ; then |
---|
113 | ENABLE_GUI="yes" |
---|
114 | fi |
---|
115 | AC_SUBST(ENABLE_GUI) |
---|
116 | |
---|
117 | with_tclsh="yes" |
---|
118 | AC_ARG_WITH( |
---|
119 | [tclsh], |
---|
120 | [AS_HELP_STRING([--with-tclsh[=DIR]], |
---|
121 | [location of tclsh @<:@default=yes@:>@])], |
---|
122 | [], |
---|
123 | [with_tclsh=yes]) |
---|
124 | |
---|
125 | TCLSH= |
---|
126 | if test "$with_tclsh" != "no" ; then |
---|
127 | AC_MSG_CHECKING([for tclsh]) |
---|
128 | if test -x "$with_tclsh/bin/tclsh" |
---|
129 | then |
---|
130 | echo Found tclsh in $with_tclsh/bin/tclsh |
---|
131 | TCLSH="$with_tclsh/bin/tclsh" |
---|
132 | else |
---|
133 | if test -x "$with_tclsh" |
---|
134 | then |
---|
135 | echo Found tclsh in $with_tclsh |
---|
136 | TCLSH="$with_tclsh" |
---|
137 | else |
---|
138 | AC_PATH_PROG(TCLSH, tclsh) |
---|
139 | fi |
---|
140 | fi |
---|
141 | fi |
---|
142 | AC_MSG_RESULT([${TCLSH}]) |
---|
143 | AC_SUBST(TCLSH) |
---|
144 | |
---|
145 | TCL_VERSION="8.4" |
---|
146 | for dir in \ |
---|
147 | ${exec_prefix} \ |
---|
148 | ${exec_prefix}/lib ; do |
---|
149 | tclconfig="${dir}/tclConfig.sh" |
---|
150 | if test -f "$tclconfig" ; then |
---|
151 | . $tclconfig |
---|
152 | break |
---|
153 | fi |
---|
154 | done |
---|
155 | TCL_INC_SPEC="$TCL_INCLUDE_SPEC" |
---|
156 | |
---|
157 | if test "x$with_tcllib" != "x" ; then |
---|
158 | tclconfig="${with_tcllib}/tclConfig.sh" |
---|
159 | if test -f "$tclconfig" ; then |
---|
160 | . $tclconfig |
---|
161 | fi |
---|
162 | TCL_LIB_SPEC="-L${with_tcllib} -ltcl${TCL_VERSION}" |
---|
163 | fi |
---|
164 | if test "x$with_tclinclude" != "x" ; then |
---|
165 | TCL_INC_SPEC="-I${with_tclinclude}" |
---|
166 | fi |
---|
167 | |
---|
168 | AC_SUBST(TCL_VERSION) |
---|
169 | AC_SUBST(TCL_INC_SPEC) |
---|
170 | AC_SUBST(TCL_LIB_SPEC) |
---|
171 | |
---|
172 | AC_ARG_WITH( |
---|
173 | [matlab], |
---|
174 | [AS_HELP_STRING([--with-matlab[=DIR]], |
---|
175 | [location of matlab and mex compiler @<:@default=yes@:>@])], |
---|
176 | [with_matlab=$withval], |
---|
177 | [with_matlab=yes]) |
---|
178 | |
---|
179 | MCC="" |
---|
180 | MEX="" |
---|
181 | MEX_ARCH="" |
---|
182 | MEXEXT="" |
---|
183 | MATLAB= |
---|
184 | if test "$with_matlab" != "no" ; then |
---|
185 | if test "$with_matlab" = "yes" ; then |
---|
186 | AC_PATH_PROG(MATLAB, matlab) |
---|
187 | else |
---|
188 | AC_PATH_PROG(MATLAB, matlab, [], [${with_matlab}/bin:${with_matlab}]) |
---|
189 | fi |
---|
190 | fi |
---|
191 | |
---|
192 | if test "x$MATLAB" != "x" ; then |
---|
193 | # Found matlab. May be a symlink to the real binary. Run "matlab -e" |
---|
194 | # to tell where matlab is installed. |
---|
195 | |
---|
196 | matlab_bindir=`${MATLAB} -e | grep "MATLAB=" | sed s/MATLAB=//`/bin |
---|
197 | |
---|
198 | # Now see if we can find "mex" or "mexext" there. |
---|
199 | AC_PATH_PROG(MEX, mex, [], [${matlab_bindir}]) |
---|
200 | AC_PATH_PROG(MEXEXT, mexext, [], [${matlab_bindir}]) |
---|
201 | |
---|
202 | # Run "mexext" to get the expected module extension for this platform. |
---|
203 | AC_MSG_CHECKING([for mex extension]) |
---|
204 | if test "x$MEXEXT" != "x" ; then |
---|
205 | MEXEXT=`$MEXEXT` |
---|
206 | else |
---|
207 | MEXEXT="mexglx" |
---|
208 | fi |
---|
209 | AC_MSG_RESULT([$MEXEXT]) |
---|
210 | AC_PATH_PROG(MCC, mcc, [], [${matlab_bindir}]) |
---|
211 | AC_MSG_CHECKING([for mcc extension]) |
---|
212 | fi |
---|
213 | |
---|
214 | AC_SUBST(MCC) |
---|
215 | AC_SUBST(MEX) |
---|
216 | AC_SUBST(MATLAB) |
---|
217 | AC_SUBST(MEX_ARCH) |
---|
218 | AC_SUBST(MEXEXT) |
---|
219 | |
---|
220 | AC_ARG_WITH( |
---|
221 | [octave], |
---|
222 | [AS_HELP_STRING([--with-octave[=DIR]], |
---|
223 | [location of octave compiler MKOCTFILE @<:@default=yes@:>@])], |
---|
224 | [with_octave=$withval], |
---|
225 | [with_octave=yes]) |
---|
226 | |
---|
227 | OCTAVE= |
---|
228 | OCTAVE_VERSION= |
---|
229 | OCTAVE_VERSION_MAJOR= |
---|
230 | MKOCTFILE= |
---|
231 | if test "$with_octave" != "no" ; then |
---|
232 | AC_MSG_CHECKING([for octave and mkoctfile]) |
---|
233 | if test "$with_octave" = "yes" ; then |
---|
234 | AC_PATH_PROG(OCTAVE, octave) |
---|
235 | AC_PATH_PROG(MKOCTFILE, mkoctfile) |
---|
236 | else |
---|
237 | AC_PATH_PROG(OCTAVE, octave, [], [$with_octave/bin:$with_octave]) |
---|
238 | AC_PATH_PROG(MKOCTFILE, mkoctfile, [], |
---|
239 | [${with_octave}/bin/mkoctfile:${with_octave}]) |
---|
240 | fi |
---|
241 | if test "x${OCTAVE}" != "x" ; then |
---|
242 | OCTAVE_VERSION=`${OCTAVE} -v | grep version | cut -d' ' -f4` |
---|
243 | OCTAVE_VERSION_MAJOR=`echo ${OCTAVE_VERSION} | cut -d'.' -f1` |
---|
244 | fi |
---|
245 | fi |
---|
246 | AC_SUBST(OCTAVE) |
---|
247 | AC_SUBST(OCTAVE_VERSION) |
---|
248 | AC_SUBST(OCTAVE_VERSION_MAJOR) |
---|
249 | AC_SUBST(MKOCTFILE) |
---|
250 | |
---|
251 | AC_ARG_WITH( |
---|
252 | [perl], |
---|
253 | [AS_HELP_STRING([--with-perl[=DIR]], [location of perl @<:@default=yes@:>@])], |
---|
254 | [], |
---|
255 | [with_perl=yes]) |
---|
256 | |
---|
257 | PERL= |
---|
258 | PERL_INCLUDES= |
---|
259 | PERL_ARCHLIB= |
---|
260 | PERL_ARCHLIBEXP= |
---|
261 | PERL_VERSION= |
---|
262 | PERL_VENDORLIB= |
---|
263 | PERL_PRIVLIB= |
---|
264 | PERL_CPPFLAGS= |
---|
265 | PERL_CCFlAGS= |
---|
266 | PERL_VERSION_RV= |
---|
267 | PERL_LIBSPEC= |
---|
268 | if test "$with_perl" != "no" ; then |
---|
269 | AC_MSG_CHECKING([for perl]) |
---|
270 | if test "$with_perl" != "yes" ; then |
---|
271 | AC_PATH_PROG(PERL, perl, [], [$with_perl/bin:$with_perl]) |
---|
272 | else |
---|
273 | AC_PATH_PROG(PERL, perl) |
---|
274 | fi |
---|
275 | if test "x${PERL}" != "x" ; then |
---|
276 | PERL_ARCHLIB=`${PERL} -MConfig -e 'print $Config{archlib}'` |
---|
277 | PERL_VERSION=`${PERL} -MConfig -e 'print $Config{version}'` |
---|
278 | PERL_CCFLAGS=`${PERL} -MConfig -e 'print $Config{ccflags}'` |
---|
279 | PERL_CPPFLAGS=`${PERL} -MConfig -e 'print $Config{cppflags}'` |
---|
280 | PERL_VENDORLIB=`${PERL} -MConfig -e 'print $Config{vendorlib}'` |
---|
281 | PERL_PRIVLIB=`${PERL} -MConfig -e 'print $Config{privlib}'` |
---|
282 | PERL_INSTALLARCHLIB=`${PERL} -MConfig -e 'print $Config{installarchlib}'` |
---|
283 | PERL_ARCHLIBEXP=`${PERL} -MConfig -e 'print $Config{archlibexp}'` |
---|
284 | PERL_VERSION_RV=`echo ${PERL_VERSION} | cut -d'.' -f1-2` |
---|
285 | echo perllib="${PERL_ARCHLIBEXP}/CORE/libperl${SHLIB_SUFFIX}" |
---|
286 | |
---|
287 | # libperl may or may not be installed. Check for its existence. |
---|
288 | if test -f "${PERL_ARCHLIBEXP}/CORE/libperl${SHLIB_SUFFIX}" ; then |
---|
289 | PERL_LIBSPEC="-L${PERL_ARCHLIBEXP}/CORE -lperl" |
---|
290 | fi |
---|
291 | fi |
---|
292 | fi |
---|
293 | AC_MSG_RESULT([${PERL}]) |
---|
294 | AC_SUBST(PERL) |
---|
295 | AC_SUBST(PERL_INCLUDES) |
---|
296 | AC_SUBST(PERL_ARCHLIB) |
---|
297 | AC_SUBST(PERL_ARCHLIBEXP) |
---|
298 | AC_SUBST(PERL_VERSION) |
---|
299 | AC_SUBST(PERL_CCFLAGS) |
---|
300 | AC_SUBST(PERL_CPPFLAGS) |
---|
301 | AC_SUBST(PERL_VENDORLIB) |
---|
302 | AC_SUBST(PERL_PRIVLIB) |
---|
303 | AC_SUBST(PERL_INSTALLARCHLIB) |
---|
304 | AC_SUBST(PERL_VERSION_RV) |
---|
305 | AC_SUBST(PERL_LIBSPEC) |
---|
306 | |
---|
307 | PYTHON="" |
---|
308 | PYTHON_CFLAGS="" |
---|
309 | PYTHON_CPPFLAGS="" |
---|
310 | HAVE_PYTHON_DISTUTILS="" |
---|
311 | PYTHON_INCLUDES="" |
---|
312 | PYTHON_LDFLAGS="" |
---|
313 | PYTHON_LIB="" |
---|
314 | PYTHON_LIBDIR="" |
---|
315 | PYTHON_SITE_DIR="" |
---|
316 | PYTHON_SITE_PACKAGES="" |
---|
317 | PYTHON_VERSION="" |
---|
318 | pythondir="" |
---|
319 | |
---|
320 | AC_ARG_WITH([python], |
---|
321 | [AS_HELP_STRING([--with-python[=DIR]],[location of python @<:@default=yes@:>@])], |
---|
322 | [], |
---|
323 | [with_python=yes]) |
---|
324 | |
---|
325 | if test "$with_python" != "no" ; then |
---|
326 | AC_MSG_CHECKING([for python]) |
---|
327 | if test -x "$with_python/bin/python"; then |
---|
328 | echo Found python in $with_python/bin/python |
---|
329 | PYTHON="$with_python/bin/python" |
---|
330 | elif test -x "$with_python"; then |
---|
331 | echo Found python in $with_python |
---|
332 | PYTHON="$with_python" |
---|
333 | else |
---|
334 | AC_PATH_PROG(PYTHON, python python2.5 python2.4 python2.3 python2.2 python2.1 python2.0 python1.6 python1.5) |
---|
335 | fi |
---|
336 | if test "x${PYTHON}" != "x"; then |
---|
337 | PYTHON_VERSION=`$PYTHON -c "import sys; print sys.version[[0:3]]"` |
---|
338 | echo Using python version $PYTHON_VERSION |
---|
339 | fi |
---|
340 | if test "x${PYTHON_VERSION}" != "x"; then |
---|
341 | if test -r $with_python/include/python$PYTHON_VERSION/Python.h -a \ |
---|
342 | -d $with_python/lib/python$PYTHON_VERSION/site-packages; then |
---|
343 | PYTHON_INCLUDES=$with_python/include/python$PYTHON_VERSION |
---|
344 | PYTHON_SITE_PACKAGES=$with_python/lib/python$PYTHON_VERSION/site-packages |
---|
345 | else |
---|
346 | if test -r $prefix/include/python$PYTHON_VERSION/Python.h; then |
---|
347 | PYTHON_INCLUDES='$(prefix)/include/python$(PYTHON_VERSION)' |
---|
348 | PYTHON_SITE_PACKAGES='$(libdir)/python$(PYTHON_VERSION)/site-packages' |
---|
349 | else |
---|
350 | if test -r /usr/include/python$PYTHON_VERSION/Python.h; then |
---|
351 | PYTHON_INCLUDES=/usr/include/python$PYTHON_VERSION |
---|
352 | PYTHON_SITE_PACKAGES='$(libdir)/python$(PYTHON_VERSION)/site-packages' |
---|
353 | else |
---|
354 | echo could not find python$PYTHON_VERSION/Python.h |
---|
355 | fi |
---|
356 | fi |
---|
357 | if test ! -d "$PYTHON_SITE_PACKAGES"; then |
---|
358 | PYTHON_SITE_PACKAGES=`$PYTHON -c "from distutils import sysconfig; print sysconfig.get_python_lib()"` |
---|
359 | fi |
---|
360 | fi |
---|
361 | fi |
---|
362 | if test "x$with_python" != "x" ; then |
---|
363 | pythondir='$(PYTHON_SITE_PACKAGES)' |
---|
364 | else |
---|
365 | pythondir='$(libdir)/python${PYTHON_VERSION}/site-packages' |
---|
366 | fi |
---|
367 | |
---|
368 | AC_MSG_CHECKING([for python distutils]) |
---|
369 | ${PYTHON} -c "from distutils.core import setup; setup(name='test')" \ |
---|
370 | build build_ext 2>&1 > /dev/null |
---|
371 | if test $? = 0 ; then |
---|
372 | HAVE_PYTHON_DISTUTILS="yes" |
---|
373 | else |
---|
374 | HAVE_PYTHON_DISTUTILS="no" |
---|
375 | fi |
---|
376 | AC_MSG_RESULT([$HAVE_PYTHON_DISTUTILS]) |
---|
377 | |
---|
378 | if test "${HAVE_PYTHON_DISTUTILS}" = "yes"; then |
---|
379 | # |
---|
380 | # Check for Python include path |
---|
381 | # |
---|
382 | AC_MSG_CHECKING([for Python include path]) |
---|
383 | if test "x${PYTHON_CPPFLAGS}" = "x"; then |
---|
384 | incdir_path=`${PYTHON} -c "import distutils.sysconfig; \ |
---|
385 | print distutils.sysconfig.get_python_inc();"` |
---|
386 | if test -n "${incdir}"; then |
---|
387 | python_path="-I${incdir}" |
---|
388 | fi |
---|
389 | PYTHON_CPPFLAGS=$python_path |
---|
390 | fi |
---|
391 | AC_MSG_RESULT([$PYTHON_CPPFLAGS]) |
---|
392 | AC_SUBST([PYTHON_CPPFLAGS]) |
---|
393 | # |
---|
394 | # python distutils found, get settings from python directly |
---|
395 | # |
---|
396 | AC_MSG_CHECKING([location of site-packages]) |
---|
397 | PYTHON_SITE_DIR="`${PYTHON} -c 'from distutils import sysconfig; print sysconfig.get_python_lib(0);'`" |
---|
398 | |
---|
399 | PYTHON_CFLAGS="`$PYTHON -c 'from distutils import sysconfig; flags = [[\"-I\" + sysconfig.get_python_inc(0), \"-I\" + sysconfig.get_python_inc(1), \" \".join(sysconfig.get_config_var(\"CFLAGS\").split())]]; print \" \".join(flags);'`" |
---|
400 | PYTHON_LDFLAGS="`$PYTHON -c 'from distutils import sysconfig; libs = sysconfig.get_config_var(\"LIBS\").split() + sysconfig.get_config_var(\"SYSLIBS\").split(); libs.append(\"-lpython\"+sysconfig.get_config_var(\"VERSION\")); print \" \".join(libs);'`" |
---|
401 | PYTHON_LIB="`$PYTHON -c 'from distutils import sysconfig; print \"python\" + sysconfig.get_config_var(\"VERSION\");'`" |
---|
402 | PYTHON_LIBDIR="`$PYTHON -c 'from distutils import sysconfig; print sysconfig.get_config_var(\"LIBDIR\");'`" |
---|
403 | fi |
---|
404 | fi |
---|
405 | AC_SUBST(pythondir) |
---|
406 | |
---|
407 | AC_SUBST(PYTHON) |
---|
408 | AC_SUBST(PYTHON_VERSION) |
---|
409 | AC_SUBST(PYTHON_INCLUDES) |
---|
410 | AC_SUBST(PYTHON_SITE_PACKAGES) |
---|
411 | AC_SUBST(HAVE_PYTHON_DISTUTILS) |
---|
412 | |
---|
413 | rappture_with_ruby="yes" |
---|
414 | |
---|
415 | RUBY="" |
---|
416 | RUBY_DEV_PKG="no" |
---|
417 | |
---|
418 | AC_ARG_WITH(ruby, |
---|
419 | AS_HELP_STRING([--with-ruby=PATH], [absolute path to ruby executable]), |
---|
420 | [rappture_with_ruby=$with_val]) |
---|
421 | if test "${rappture_with_ruby}" != "no" ; then |
---|
422 | if test "${rappture_with_ruby}" = "yes" ; then |
---|
423 | AC_PATH_PROG(RUBY, ruby) |
---|
424 | else |
---|
425 | AC_PATH_PROG(RUBY, ruby, [], |
---|
426 | [${rappture_with_ruby}/bin/ruby:${rappture_with_ruby}]) |
---|
427 | fi |
---|
428 | fi |
---|
429 | AC_SUBST(RUBY) |
---|
430 | |
---|
431 | RUBY_VERSION_RV= |
---|
432 | RUBY_PLATFORM= |
---|
433 | if test "x${RUBY}" != "x" ; then |
---|
434 | AX_PROG_RUBY_VERSION |
---|
435 | RUBY_VERSION_RV=`echo ${RUBY_VERSION} | cut -d'.' -f1-2` |
---|
436 | RUBY_PLATFORM=`ruby -e 'puts RUBY_PLATFORM'` |
---|
437 | ac_mkmf_result=`${RUBY} -r mkmf -e ";" 2>&1` |
---|
438 | if test -z "$ac_mkmf_result"; then |
---|
439 | HAVE_RUBY_DEVEL="yes" |
---|
440 | AX_RUBY_DEV_FLAGS([${RUBY}]) |
---|
441 | fi |
---|
442 | fi |
---|
443 | AC_SUBST(HAVE_RUBY_DEVEL) |
---|
444 | AC_SUBST(RUBY_VERSION_RV) |
---|
445 | AC_SUBST(RUBY_PLATFORM) |
---|
446 | |
---|
447 | RP_BASE=`pwd` |
---|
448 | AC_SUBST(RP_BASE) |
---|
449 | |
---|
450 | SC_ENABLE_SHARED |
---|
451 | |
---|
452 | #-------------------------------------------------------------------- |
---|
453 | # This macro figures out what flags to use with the compiler/linker |
---|
454 | # when building shared/static debug/optimized objects. This information |
---|
455 | # is all taken from the tclConfig.sh file. |
---|
456 | #-------------------------------------------------------------------- |
---|
457 | |
---|
458 | AC_SUBST(CFLAGS_DEBUG) |
---|
459 | AC_SUBST(CFLAGS_OPTIMIZE) |
---|
460 | AC_SUBST(STLIB_LD) |
---|
461 | AC_SUBST(SHLIB_LD) |
---|
462 | AC_SUBST(SHLIB_CFLAGS) |
---|
463 | AC_SUBST(SHLIB_LDFLAGS) |
---|
464 | AC_SUBST(SHLIB_SUFFIX) |
---|
465 | |
---|
466 | if test -f "${exec_prefix}/lib/tclConfig.sh" ; then |
---|
467 | . ${exec_prefix}/lib/tclConfig.sh |
---|
468 | fi |
---|
469 | if test -f "${exec_prefix}/lib/tclConfig.sh" ; then |
---|
470 | . ${exec_prefix}/lib/tkConfig.sh |
---|
471 | fi |
---|
472 | AC_SUBST(TCL_VERSION) |
---|
473 | AC_SUBST(TK_VERSION) |
---|
474 | |
---|
475 | # ----------------------------------------------------------------------- |
---|
476 | # |
---|
477 | # Compiler characteristics: |
---|
478 | # Check for existence of types of size_t and pid_t |
---|
479 | # |
---|
480 | # ----------------------------------------------------------------------- |
---|
481 | |
---|
482 | AC_C_BIGENDIAN |
---|
483 | AC_CHECK_SIZEOF(int) |
---|
484 | AC_CHECK_SIZEOF(long) |
---|
485 | AC_CHECK_SIZEOF(long long) |
---|
486 | AC_CHECK_SIZEOF(void *) |
---|
487 | |
---|
488 | SIZEOF_LONG="${ac_cv_sizeof_long}" |
---|
489 | SIZEOF_LONG_LONG="${ac_cv_sizeof_long_long}" |
---|
490 | SIZEOF_VOID_P="${ac_cv_sizeof_void_p}" |
---|
491 | SIZEOF_INT="${ac_cv_sizeof_int}" |
---|
492 | AC_SUBST(SIZEOF_INT) |
---|
493 | AC_SUBST(SIZEOF_LONG) |
---|
494 | AC_SUBST(SIZEOF_LONG_LONG) |
---|
495 | AC_SUBST(SIZEOF_VOID_P) |
---|
496 | |
---|
497 | |
---|
498 | #-------------------------------------------------------------------- |
---|
499 | # Set the default compiler switches based on the --enable-symbols |
---|
500 | # option. |
---|
501 | #-------------------------------------------------------------------- |
---|
502 | |
---|
503 | SC_ENABLE_SYMBOLS |
---|
504 | |
---|
505 | if test "${SHARED_BUILD}" = "1" ; then |
---|
506 | CFLAGS='${CFLAGS_DEFAULT} ${CFLAGS_WARNING} ${SHLIB_CFLAGS}' |
---|
507 | else |
---|
508 | CFLAGS='${CFLAGS_DEFAULT} ${CFLAGS_WARNING}' |
---|
509 | fi |
---|
510 | |
---|
511 | ac_configure_args="--disable-threads --enable-shared" |
---|
512 | AC_CONFIG_SUBDIRS( [packages/optimizer/src] ) |
---|
513 | |
---|
514 | dnl read Makefile.in and write Makefile |
---|
515 | AC_CONFIG_FILES([ |
---|
516 | Makefile |
---|
517 | packages/Makefile |
---|
518 | src/Makefile |
---|
519 | src/core/Makefile |
---|
520 | src/core2/Makefile |
---|
521 | src/objects/Makefile |
---|
522 | src/objects/RpHash.h |
---|
523 | gui/Makefile |
---|
524 | gui/apps/Makefile |
---|
525 | gui/apps/about |
---|
526 | gui/apps/encodedata |
---|
527 | gui/apps/rappture |
---|
528 | gui/apps/rappture-csh.env |
---|
529 | gui/apps/rappture.env |
---|
530 | gui/apps/rappture.use |
---|
531 | gui/apps/rerun |
---|
532 | gui/apps/simsim |
---|
533 | gui/apps/xmldiff |
---|
534 | gui/pkgIndex.tcl |
---|
535 | gui/scripts/Makefile |
---|
536 | lang/Makefile |
---|
537 | lang/perl/Makefile |
---|
538 | lang/perl/Makefile.PL |
---|
539 | lang/python/Makefile |
---|
540 | lang/python/setup.py |
---|
541 | lang/matlab/Makefile |
---|
542 | lang/octave/Makefile |
---|
543 | lang/octave/RpOctaveInterface.h |
---|
544 | lang/ruby/Makefile |
---|
545 | lang/ruby/build.rb |
---|
546 | lang/tcl/Makefile |
---|
547 | lang/tcl/pkgIndex.tcl |
---|
548 | lang/tcl/src/Makefile |
---|
549 | lang/tcl/scripts/Makefile |
---|
550 | lang/tcl/tests/Makefile |
---|
551 | lib/Makefile |
---|
552 | examples/3D/Makefile |
---|
553 | examples/Makefile |
---|
554 | examples/app-fermi/2.0/Makefile |
---|
555 | examples/app-fermi/Makefile |
---|
556 | examples/app-fermi/cee/Makefile |
---|
557 | examples/app-fermi/fortran/Makefile |
---|
558 | examples/app-fermi/matlab/Makefile |
---|
559 | examples/app-fermi/matlab/compiled/Makefile |
---|
560 | examples/app-fermi/matlab/uncompiled/Makefile |
---|
561 | examples/app-fermi/octave/Makefile |
---|
562 | examples/app-fermi/octave/2/Makefile |
---|
563 | examples/app-fermi/octave/3/Makefile |
---|
564 | examples/app-fermi/perl/Makefile |
---|
565 | examples/app-fermi/python/Makefile |
---|
566 | examples/app-fermi/ruby/Makefile |
---|
567 | examples/app-fermi/tcl/Makefile |
---|
568 | examples/app-fermi/wrapper/Makefile |
---|
569 | examples/app-fermi/wrapper/cee/Makefile |
---|
570 | examples/app-fermi/wrapper/python/Makefile |
---|
571 | examples/app-fermi/wrapper/tcl/Makefile |
---|
572 | examples/c-example/Makefile |
---|
573 | examples/canvas/Makefile |
---|
574 | examples/demo.bash |
---|
575 | examples/flow/Makefile |
---|
576 | examples/flow/demo1/Makefile |
---|
577 | examples/flow/demo2/Makefile |
---|
578 | examples/flow/demo3/Makefile |
---|
579 | examples/graph/Makefile |
---|
580 | examples/objects/Makefile |
---|
581 | examples/objects/axis/Makefile |
---|
582 | examples/objects/contour/Makefile |
---|
583 | examples/objects/curve/Makefile |
---|
584 | examples/objects/dxWriter/Makefile |
---|
585 | examples/objects/floatBuffer/Makefile |
---|
586 | examples/objects/histogram/Makefile |
---|
587 | examples/objects/library/Makefile |
---|
588 | examples/objects/number/Makefile |
---|
589 | examples/objects/path/Makefile |
---|
590 | examples/objects/plot/Makefile |
---|
591 | examples/objects/scatter/Makefile |
---|
592 | examples/objects/string/Makefile |
---|
593 | examples/objects/tree/Makefile |
---|
594 | examples/objects/xmlparser/Makefile |
---|
595 | examples/zoo/Makefile |
---|
596 | examples/zoo/binary/Makefile |
---|
597 | examples/zoo/boolean/Makefile |
---|
598 | examples/zoo/choice/Makefile |
---|
599 | examples/zoo/cloud/Makefile |
---|
600 | examples/zoo/cloud/matlab/Makefile |
---|
601 | examples/zoo/curve/Makefile |
---|
602 | examples/zoo/enable/Makefile |
---|
603 | examples/zoo/field/Makefile |
---|
604 | examples/zoo/group/Makefile |
---|
605 | examples/zoo/image/Makefile |
---|
606 | examples/zoo/image/docs/Makefile |
---|
607 | examples/zoo/image/examples/Makefile |
---|
608 | examples/zoo/integer/Makefile |
---|
609 | examples/zoo/integer2/Makefile |
---|
610 | examples/zoo/loader/Makefile |
---|
611 | examples/zoo/loader/examples/Makefile |
---|
612 | examples/zoo/loadrun/Makefile |
---|
613 | examples/zoo/log/Makefile |
---|
614 | examples/zoo/note/Makefile |
---|
615 | examples/zoo/note/docs/Makefile |
---|
616 | examples/zoo/number/Makefile |
---|
617 | examples/zoo/number2/Makefile |
---|
618 | examples/zoo/periodicelement/Makefile |
---|
619 | examples/zoo/phase/Makefile |
---|
620 | examples/zoo/sequence/Makefile |
---|
621 | examples/zoo/sequence/examples/Makefile |
---|
622 | examples/zoo/string/Makefile |
---|
623 | examples/zoo/structure/Makefile |
---|
624 | examples/zoo/structure/examples/Makefile |
---|
625 | examples/zoo/table/Makefile |
---|
626 | examples/zoo/unirect2d/Makefile |
---|
627 | test/Makefile |
---|
628 | test/src/Makefile |
---|
629 | ]) |
---|
630 | AC_OUTPUT |
---|