/hg/icedtea: Differentiate the plugin build directory from the s...

andrew at icedtea.classpath.org andrew at icedtea.classpath.org
Tue Mar 2 19:15:28 PST 2010


changeset fd1500c0d6e8 in /hg/icedtea
details: http://icedtea.classpath.org/hg/icedtea?cmd=changeset;node=fd1500c0d6e8
author: Andrew John Hughes <ahughes at redhat.com>
date: Wed Mar 03 03:15:21 2010 +0000

	Differentiate the plugin build directory from the source directory.

	2010-03-03 Andrew John Hughes <ahughes at redhat.com>

	 * Makefile.am: (PLUGIN_BUILD_DIR): Name the build
	directory differently so it doesn't conflict when
	srcdir==builddir. (clean-IcedTeaNPPlugin): Avoid needless
	use of cd by using absolute paths. (clean-
	IcedTeaPlugin): Explicitly name files as in clean-
	IcedTeaNPPlugin. (clean-plugin): Remove the plugin build
	directory using rmdir. This will fail if anything
	unexpected is left in the build directory.


diffstat:

2 files changed, 23 insertions(+), 7 deletions(-)
ChangeLog   |   14 ++++++++++++++
Makefile.am |   16 +++++++++-------

diffs (75 lines):

diff -r a78f9278f99e -r fd1500c0d6e8 ChangeLog
--- a/ChangeLog	Wed Mar 03 00:52:15 2010 +0000
+++ b/ChangeLog	Wed Mar 03 03:15:21 2010 +0000
@@ -1,3 +1,17 @@ 2010-03-02 Andrew John Hughes  <ahughes@
+2010-03-03 Andrew John Hughes  <ahughes at redhat.com>
+
+	* Makefile.am:
+	(PLUGIN_BUILD_DIR): Name the build directory
+	differently so it doesn't conflict when
+	srcdir==builddir.
+	(clean-IcedTeaNPPlugin): Avoid needless use
+	of cd by using absolute paths.
+	(clean-IcedTeaPlugin): Explicitly name files
+	as in clean-IcedTeaNPPlugin.
+	(clean-plugin): Remove the plugin build directory
+	using rmdir.  This will fail if anything unexpected
+	is left in the build directory.
+
 2010-03-02 Andrew John Hughes  <ahughes at redhat.com>
 
 	* patches/boot/genstubs-nofork.patch:
diff -r a78f9278f99e -r fd1500c0d6e8 Makefile.am
--- a/Makefile.am	Wed Mar 03 00:52:15 2010 +0000
+++ b/Makefile.am	Wed Mar 03 03:15:21 2010 +0000
@@ -172,7 +172,7 @@ endif
 
 if ENABLE_NPPLUGIN
 PLUGIN_SRCDIR=$(abs_top_srcdir)/plugin/icedteanp
-PLUGIN_BUILD_DIR=$(abs_top_builddir)/plugin/icedteanp
+PLUGIN_BUILD_DIR=$(abs_top_builddir)/plugin.build/icedteanp
 ICEDTEANPPLUGIN_TARGET = $(PLUGIN_BUILD_DIR)/IcedTeaNPPlugin.so
 ICEDTEAPLUGIN_CLEAN = clean-IcedTeaNPPlugin
 PLUGIN_PATCH = patches/icedtea-liveconnect.patch
@@ -181,7 +181,7 @@ else
 else
 if ENABLE_PLUGIN
 PLUGIN_SRCDIR=$(abs_top_srcdir)/plugin/icedtea
-PLUGIN_BUILD_DIR=$(abs_top_builddir)/plugin/icedtea
+PLUGIN_BUILD_DIR=$(abs_top_builddir)/plugin.build/icedtea
 ICEDTEAPLUGIN_TARGET = $(PLUGIN_BUILD_DIR)/IcedTeaPlugin.so
 ICEDTEAPLUGIN_CLEAN = clean-IcedTeaPlugin
 PLUGIN_PATCH = patches/icedtea-liveconnect.patch
@@ -1997,10 +1997,8 @@ NPPLUGIN_OBJECTS=IcedTeaNPPlugin.o IcedT
 	  -shared -o $@
 
 clean-IcedTeaNPPlugin:
-	cd $(PLUGIN_BUILD_DIR); \
-	rm -f *.o; \
-	rm -f IcedTeaNPPlugin.so; \
-	cd ../
+	rm -f $(addprefix $(PLUGIN_BUILD_DIR)/,$(NPPLUGIN_OBJECTS))
+	rm -f $(PLUGIN_BUILD_DIR)/IcedTeaNPPlugin.so
 endif
 
 if ENABLE_PLUGIN
@@ -2030,7 +2028,8 @@ if ENABLE_PLUGIN
 	  -shared -o $@
 
 clean-IcedTeaPlugin:
-	rm -rf $(PLUGIN_BUILD_DIR)
+	rm -f $(PLUGIN_BUILD_DIR)/IcedTeaPlugin.o
+	rm -f $(PLUGIN_BUILD_DIR)/IcedTeaPlugin.so
 endif
 
 stamps/plugin.stamp: $(ICEDTEAPLUGIN_TARGET) $(ICEDTEANPPLUGIN_TARGET)
@@ -2038,6 +2037,9 @@ stamps/plugin.stamp: $(ICEDTEAPLUGIN_TAR
 	touch $@
 
 clean-plugin: $(ICEDTEAPLUGIN_CLEAN) $(ICEDTEANPPLUGIN_CLEAN)
+	if [ -e $(PLUGIN_BUILD_DIR) ] ; then \
+	  rmdir $(PLUGIN_BUILD_DIR) ; \
+	fi
 	rm -f stamps/plugin.stamp
 
 liveconnect-source-files.txt:



More information about the distro-pkg-dev mailing list