aboutsummaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in43
1 files changed, 39 insertions, 4 deletions
diff --git a/configure.in b/configure.in
index 285ab37..5518067 100644
--- a/configure.in
+++ b/configure.in
@@ -85,6 +85,19 @@ AC_ARG_WITH(fftw3_dir,
echo
])
+dnl If --enable-swig, make with java bindings
+AC_ARG_WITH(java,
+ [ --with-java If --enable-swig - make with java bindings (default=no) ],
+ [with_java=true])
+
+AM_CONDITIONAL(BUILD_JAVA, test "x${with_java}" = 'xtrue')
+
+dnl If --enable-swig, make with java bindings
+AC_ARG_WITH(python,
+ [ --with-python If --enable-swig - make with python bindings (default=no) ], [with_python=true])
+
+AM_CONDITIONAL(BUILD_PYTHON, test "x${with_python}" = 'xtrue')
+
dnl Are we building with fftw?
if [[ "$fft" = "true" ]] ; then
LDFLAGS="$LDFLAGS -lfftw3f"
@@ -148,11 +161,27 @@ AC_ARG_ENABLE(swig,
dnl SWIG stuff
if [[ "$swig" = "true" ]] ; then
AC_PROG_SWIG(1.3.21)
+ AC_DEFINE([BUILD_SWIG], [1], [Build the swig bindings])
+fi
+
+if [[ "$with_java" = "true" ]] ; then
+ AC_PROG_JAVAC
+ AC_JNI_INCLUDE_DIR
+
+ for JNI_INCLUDE_DIR in $JNI_INCLUDE_DIRS
+ do
+ CFLAGS="$CFLAGS -I$JNI_INCLUDE_DIR"
+ done
+ dnl AC_PROG_JAVAH
+ dnl AC_PATH_PROG(JAVAH,javah)
+fi
+
+if [[ "$with_python" = "true" ]] ; then
AM_PATH_PYTHON
SWIG_PYTHON
- AC_DEFINE([BUILD_SWIG], [1], [Build the swig bindings])
fi
+
AM_CONDITIONAL(BUILD_SWIG, test "x${swig}" = 'xtrue')
dnl ------------------------------------------
@@ -232,7 +261,8 @@ AC_SUBST(PD_SOURCES)
AC_CONFIG_FILES([doc/documentation.doxygen
libxtract.pc])
-AC_OUTPUT(Makefile src/Makefile xtract/Makefile doc/Makefile examples/Makefile examples/puredata/Makefile examples/simpletest/Makefile swig/Makefile)
+dnl There must be a better way to do this...
+AC_OUTPUT(Makefile src/Makefile xtract/Makefile doc/Makefile examples/Makefile examples/puredata/Makefile examples/simpletest/Makefile swig/Makefile swig/python/Makefile swig/java/Makefile)
echo
echo "**************************************************************"
@@ -261,9 +291,14 @@ else
echo "PD external: no"
fi
if test "$swig" == "true"; then
- echo "SWIG Python bindings: yes"
+ echo "SWIG bindings: yes"
+else
+ echo "SWIG bindings: no"
+fi
+if test "$with_java" == "true"; then
+ echo "with JAVA module: yes"
else
- echo "SWIG Python bindings: no"
+ echo "with JAVA module: no"
fi
echo
echo "**************************************************************"