RFC: Patch to correct pulse-java.jar build
Andrew John Hughes
gnu_andrew at member.fsf.org
Wed Sep 16 14:52:27 PDT 2009
2009/9/16 <jon.vanalten at redhat.com>:
> Hi,
>
> It has been pointed out (off-list, sorry) that pulse-java.jar contains the source tree and other unnecessary intermediate files. The attached patches for correct this icedtea6 and icedtea7 respectively, producing a .jar containing the .class files which is ~70K (previous size was ~1.5M). Also, the pulse-audio sections of the makefile for both versions have been harmonized, as there were differences which made little sense.
>
> Thoughts? Comments?
>
> cheers,
>
> jon
The definitions:
PULSE_JAVA_DIR = $(abs_top_srcdir)/pulseaudio
PULSE_JAVA_NATIVE_SRCDIR = $(PULSE_JAVA_DIR)/src/native
+PULSE_JAVA_BUILDDIR = $(PULSE_JAVA_DIR)/build
+PULSE_JAVA_NATIVE_BUILDDIR = $(PULSE_JAVA_BUILDDIR)/native
PULSE_JAVA_JAVA_SRCDIR = $(PULSE_JAVA_DIR)/src/java
-PULSE_JAVA_CLASS_DIR = $(abs_top_builddir)/pulseaudio
+PULSE_JAVA_CLASS_DIR = $(PULSE_JAVA_BUILDDIR)/cp
seem to end up writing to the source directory
(PULSE_JAVA_NATIVE_BUILDDIR =
$(abs_top_srcdir)/pulseaudio/build/native and PULSE_JAVA_CLASS_DIR =
$(abs_top_srcdir)/pulseaudio/build/cp). That's incorrect and will
break make distcheck. The build directories should be in
subdirectories of $(abs_top_builddir). Making PULSE_JAVA_BUILDDIR =
$(abs_top_builddir)/pulseaudio would fix that.
The IcedTea7 patch also reintroduces conditionals on ICEDTEA_BOOT_DIR
and the corresponding duplicating javac/jar invocations.. Please
don't do this. These were removed deliberately and will also be
removed from IcedTea6 once I port over
$(INITIAL_BOOTSTRAP_LINK_STAMP). The new JAVAC definitions also drop
IT_JAVACFLAGS, completely reverting it to the IcedTea6 version.
All you need to do is make sure the classes go in a clean
subdirectory, so make PULSE_JAVA_CLASS_DIR =
$(abs_top_builddir)/pulseaudio/build. Then change the jar invocation
to:
$(ICEDTEA_BOOT_DIR)/bin/jar cf pulse-java.jar -C
$(PULSE_JAVA_CLASS_DIR) META-INF \
-C $(PULSE_JAVA_CLASS_DIR) org;
If you want to give native a subdirectory too, then fine but don't
write files to the srcdir and please don't add back old cruft.
Thanks,
--
Andrew :-)
Free Java Software Engineer
Red Hat, Inc. (http://www.redhat.com)
Support Free Java!
Contribute to GNU Classpath and the OpenJDK
http://www.gnu.org/software/classpath
http://openjdk.java.net
PGP Key: 94EFD9D8 (http://subkeys.pgp.net)
Fingerprint: F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8
More information about the distro-pkg-dev
mailing list