[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[Libguestfs] [PATCH 2/3] java: out-of-tree build, don't build static library



From: Hilko Bengen <bengen hilluzination de>

---
 java/Makefile.am |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/java/Makefile.am b/java/Makefile.am
index 7686047..4bf7e38 100644
--- a/java/Makefile.am
+++ b/java/Makefile.am
@@ -19,7 +19,6 @@ include $(top_srcdir)/subdir-rules.mk
 
 # Old RHEL 5 autoconf doesn't have builddir.
 builddir ?= $(top_builddir)/java
-
 # XXX: Need to fix generator.ml dependencies
 #
 # Files generated by generator.ml:
@@ -73,7 +72,7 @@ libguestfs_jni_la_SOURCES = \
 	com_redhat_et_libguestfs_GuestFS.c
 
 libguestfs_jni_la_LIBADD = $(top_builddir)/src/libguestfs.la
-libguestfs_jni_la_LDFLAGS = -version-info $(JNI_VERSION_INFO)
+libguestfs_jni_la_LDFLAGS = -version-info $(JNI_VERSION_INFO) -shared
 libguestfs_jni_la_CFLAGS = \
   $(WARN_CFLAGS) $(WERROR_CFLAGS) \
   -I$(top_srcdir)/src -I$(top_builddir)/src \
@@ -112,10 +111,11 @@ TESTS_ENVIRONMENT = \
 noinst_DATA = Bindtests.class $(java_tests:.java=.class)
 
 t/%.class: t/%.java
-	$(JAVAC) $(JAVAC_FLAGS) -classpath libguestfs-$(VERSION).jar $<
+	mkdir -p t
+	$(JAVAC) $(JAVAC_FLAGS) -classpath libguestfs-$(VERSION).jar -d $(builddir)/t $<
 
 Bindtests.class: Bindtests.java
-	$(JAVAC) $(JAVAC_FLAGS) -classpath libguestfs-$(VERSION).jar $<
+	$(JAVAC) $(JAVAC_FLAGS) -classpath libguestfs-$(VERSION).jar -d $(builddir) $<
 
 endif
 
-- 
1.7.7.2


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]