From f0c21a72cd6b027779fa99e55ec21be06c3dee41 Mon Sep 17 00:00:00 2001 From: David Reiss Date: Fri, 11 Jul 2008 01:26:16 +0000 Subject: [PATCH] [THRIFT-70] Allow the Java install prefix to be configured. Systems like Debian expect the thrift jar to be in /usr/share/java, not the default /usr/local/lib This patch allows configure to be passed a JAVA_PREFIX= flag. git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@675821 13f79535-47bb-0310-9956-ffa450edef68 --- configure.ac | 5 +++++ lib/java/Makefile.am | 2 +- lib/java/build.xml | 3 ++- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index ef163f74..3e1d1ac7 100644 --- a/configure.ac +++ b/configure.ac @@ -12,6 +12,11 @@ AC_ARG_VAR([PY_PREFIX], [Prefix for installing Python modules. Default = "/usr"]) AS_IF([test "x$PY_PREFIX" = x], [PY_PREFIX="/usr"]) +AC_ARG_VAR([JAVA_PREFIX], [Prefix for installing the Java lib jar. + (Normal --prefix is ignored for Java because + Java has different conevntions.) + Default = "/usr/local/lib"]) +AS_IF([test "x$JAVA_PREFIX" = x], [JAVA_PREFIX="/usr/local/lib"]) AC_PROG_CC AC_PROG_CPP diff --git a/lib/java/Makefile.am b/lib/java/Makefile.am index e878ae99..45a88e29 100644 --- a/lib/java/Makefile.am +++ b/lib/java/Makefile.am @@ -4,7 +4,7 @@ all-local: $(ANT) install-exec-hook: - $(ANT) install + $(ANT) install -Dinstall.path=$(DESTDIR)$(JAVA_PREFIX) # Make sure this doesn't fail if ant is not configured. clean-local: diff --git a/lib/java/build.xml b/lib/java/build.xml index cd010171..75e74517 100644 --- a/lib/java/build.xml +++ b/lib/java/build.xml @@ -4,6 +4,7 @@ + @@ -20,7 +21,7 @@ - + -- 2.17.1