[1.9] RFC: Allow NetX to be disabled
Deepak Bhole
dbhole at redhat.com
Thu Nov 11 12:10:54 PST 2010
* Dr Andrew John Hughes <ahughes at redhat.com> [2010-11-11 10:56]:
> On 15:12 Thu 11 Nov , Dr Andrew John Hughes wrote:
> > On 09:49 Thu 11 Nov , Deepak Bhole wrote:
> > > * Dr Andrew John Hughes <ahughes at redhat.com> [2010-11-11 09:21]:
> > > > > +])
> > > >
> > > > New version; turns out I missed the -debug target... :-(
> > >
> > > Just tried building with --disable-webstart. The classes are not built,
> > > however javaws still is. javaws shouldn't get built with
> > > --disable-webstart as it'd be unusable without the classes.
> > >
> >
> > Yeah just spotted that; it's because it's added by netx.patch and produced
> > by the OpenJDK build, not our makefiles. Testing a new version.
> >
> > > Cheers,
> > > Deepak
> >
> > --
> > 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
>
> New version attached.
Built it with and without webstart. Without webstart is as expected now
-- no related files/classes. With webstart enabled, javaws builds and
works.
I was unable to configure+make by just reconfiguring without the
--disable-webstart.... make ran into error with missing classes and what
not. It worked fine after a make clean though. Is this expected?
Cheers,
Deepak
> --
> 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
> diff -r 17c34c4c6fae Makefile.am
> --- a/Makefile.am Wed Nov 10 16:30:08 2010 +0000
> +++ b/Makefile.am Thu Nov 11 15:55:47 2010 +0000
> @@ -288,8 +288,6 @@
> patches/icedtea-policy-evaluation.patch \
> patches/hotspot/$(HSBUILD)/update-bootclasspath.patch \
> patches/libpng.patch \
> - patches/extensions/netx.patch \
> - patches/extensions/netx-umask.patch \
> patches/icedtea-jtreg-httpTest.patch \
> patches/arm.patch \
> patches/openjdk/6678385-window_movement_crasher.patch \
> @@ -339,6 +337,12 @@
> patches/icedtea-rhino.patch
> endif
>
> +if ENABLE_NETX
> +ICEDTEA_PATCHES += \
> + patches/extensions/netx.patch \
> + patches/extensions/netx-umask.patch
> +endif
> +
> if ENABLE_PLUGIN
> ICEDTEA_PATCHES += \
> patches/extensions/liveconnect.patch
> @@ -579,7 +583,7 @@
> clean-icedtea-against-icedtea clean-icedtea-debug-against-icedtea \
> clean-icedtea-against-ecj clean-extract-ecj clean-generated clean-replace-hotspot \
> clean-rewriter clean-rewrite-rhino clean-extra clean-rt clean-bootstrap-directory \
> - clean-bootstrap-directory-ecj clean-bootstrap-directory-symlink \
> + clean-bootstrap-directory-ecj clean-bootstrap-directory-symlink clean-about \
> clean-bootstrap-directory-symlink-ecj
> if [ -e bootstrap ]; then \
> rmdir bootstrap ; \
> @@ -613,7 +617,7 @@
> clean-ports clean-overlay clean-extract-ecj clean-extract clean-extract-openjdk \
> clean-replace-hotspot clean-generated clean-download clean-hgforest clean-download-openjdk \
> clean-rewriter clean-rewrite-rhino clean-add-netx clean-add-netx-debug \
> - clean-add-plugin clean-add-plugin-debug
> + clean-add-plugin clean-add-plugin-debug clean-about
>
> env:
> @echo 'unset JAVA_HOME'
> @@ -1469,7 +1473,8 @@
> rm -f $(DEBUG_BUILD_OUTPUT_DIR)/j2re-image/lib/plugin.jar
> rm -f stamps/add-plugin-debug.stamp
>
> -stamps/add-netx.stamp: stamps/netx-dist.stamp extra-lib/about.jar
> +stamps/add-netx.stamp: stamps/netx-dist.stamp stamps/about.stamp
> +if ENABLE_NETX
> cp -pPRf $(abs_top_builddir)/netx.build/lib/classes.jar \
> $(BUILD_OUTPUT_DIR)/j2sdk-image/jre/lib/netx.jar
> cp -pPRf $(abs_top_builddir)/netx.build/lib/classes.jar \
> @@ -1486,6 +1491,7 @@
> cp $(NETX_SRCDIR)/javaws.1 \
> $(BUILD_OUTPUT_DIR)/j2re-image/man/man1 ; \
> fi
> +endif
> touch stamps/add-netx.stamp
>
> clean-add-netx:
> @@ -1499,7 +1505,8 @@
> rm -f $(BUILD_OUTPUT_DIR)/j2re-image/man/man1/javaws.1
> rm -f stamps/add-netx.stamp
>
> -stamps/add-netx-debug.stamp: stamps/netx-dist.stamp extra-lib/about.jar
> +stamps/add-netx-debug.stamp: stamps/netx-dist.stamp stamps/about.stamp
> +if ENABLE_NETX
> cp -pPRf $(abs_top_builddir)/netx.build/lib/classes.jar \
> $(DEBUG_BUILD_OUTPUT_DIR)/j2sdk-image/jre/lib/netx.jar
> cp -pPRf $(abs_top_builddir)/netx.build/lib/classes.jar \
> @@ -1516,6 +1523,7 @@
> cp $(NETX_SRCDIR)/javaws.1 \
> $(DEBUG_BUILD_OUTPUT_DIR)/j2re-image/man/man1 ; \
> fi
> +endif
> touch stamps/add-netx-debug.stamp
>
> clean-add-netx-debug:
> @@ -1693,6 +1701,7 @@
> find $(NETX_SRCDIR) -name '*.java' | sort > $@
>
> stamps/netx.stamp: netx-source-files.txt stamps/rt-class-files.stamp
> +if ENABLE_NETX
> mkdir -p $(abs_top_builddir)/netx.build
> $(BOOT_DIR)/bin/javac $(IT_JAVACFLAGS) \
> -d $(abs_top_builddir)/netx.build \
> @@ -1700,10 +1709,12 @@
> -classpath $(RUNTIME) -bootclasspath \'\' \
> @netx-source-files.txt
> cp -r $(NETX_RESOURCE_DIR) $(abs_top_builddir)/netx.build/net/sourceforge/jnlp
> +endif
> mkdir -p stamps
> touch $@
>
> stamps/netx-dist.stamp: stamps/netx.stamp
> +if ENABLE_NETX
> (cd $(abs_top_builddir)/netx.build ; \
> mkdir -p lib ; \
> $(BOOT_DIR)/bin/jar cf lib/classes.jar javax/jnlp net ; \
> @@ -1713,6 +1724,7 @@
> $(BOOT_DIR)/bin/jar uf $(abs_top_builddir)/netx.build/lib/classes.jar \
> `find . -type f -not -name '*.java'` ; \
> $(ZIP) -qr $(abs_top_builddir)/netx.build/lib/src.zip javax net )
> +endif
> mkdir -p stamps
> touch $@
>
> @@ -1728,11 +1740,13 @@
>
> stamps/extra-class-files.stamp: $(INITIAL_BOOTSTRAP_LINK_STAMP) \
> extra-source-files.txt stamps/netx.stamp
> +if ENABLE_NETX
> mkdir -p extra-lib
> $(BOOT_DIR)/bin/javac $(IT_JAVACFLAGS) -d extra-lib \
> -sourcepath extra -cp netx.build \
> -bootclasspath $(RUNTIME) @extra-source-files.txt
> cp -r $(NETX_EXTRA_DIR) extra-lib/net/sourceforge/jnlp/about
> +endif
> mkdir -p stamps
> touch $@
>
> @@ -1741,8 +1755,16 @@
> rm -f stamps/extra-class-files.stamp
> rm -f extra-source-files.txt
>
> -extra-lib/about.jar: stamps/extra-class-files.stamp
> - $(BOOT_DIR)/bin/jar cf $@ -C extra-lib net ;
> +stamps/about.stamp: stamps/extra-class-files.stamp
> +if ENABLE_NETX
> + $(BOOT_DIR)/bin/jar cf extra-lib/about.jar -C extra-lib net
> +endif
> + mkdir -p stamps
> + touch $@
> +
> +clean-about:
> + rm -f extra-lib/about.jar
> + rm -f stamps/about.stamp
>
> # PulseAudio based mixer
> # (pulse-java)
> diff -r 17c34c4c6fae acinclude.m4
> --- a/acinclude.m4 Wed Nov 10 16:30:08 2010 +0000
> +++ b/acinclude.m4 Thu Nov 11 15:55:47 2010 +0000
> @@ -1459,12 +1459,17 @@
>
> AC_DEFUN_ONCE([IT_CHECK_PLUGIN],
> [
> +AC_REQUIRE([IT_CHECK_NETX])
> AC_MSG_CHECKING([whether to build the browser plugin])
> AC_ARG_ENABLE([plugin],
> [AS_HELP_STRING([--disable-plugin],
> [Disable compilation of browser plugin])],
> [enable_plugin="${enableval}"], [enable_plugin="yes"])
> AC_MSG_RESULT(${enable_plugin})
> +if test "x${enable_netx}" = "xno" ; then
> + AC_MSG_WARN([Plugin can not be built without NetX; disabling plugin])
> + enable_plugin=no;
> +fi
> ])
>
> AC_DEFUN_ONCE([IT_CHECK_PLUGIN_DEPENDENCIES],
> @@ -1556,3 +1561,14 @@
> AM_CONDITIONAL([HAS_PAX], test x"${it_cv_pax}" = "xyes")
> AC_PROVIDE([$0])dnl
> ])
> +
> +AC_DEFUN_ONCE([IT_CHECK_NETX],
> +[
> +AC_MSG_CHECKING([whether to build NetX])
> +AC_ARG_ENABLE([webstart],
> + [AS_HELP_STRING([--disable-webstart],
> + [Disable compilation of Web Start support])],
> + [enable_netx="${enableval}"], [enable_netx="yes"])
> +AC_MSG_RESULT(${enable_netx})
> +AM_CONDITIONAL(ENABLE_NETX, test "x${enable_netx}" = "xyes")
> +])
More information about the distro-pkg-dev
mailing list