Mercurial > hg > icedtea7
changeset 2829:e6ffd4b963d6
PR2537: Desktop files do not allow installation from multiple versions of IcedTea
2015-07-16 Andrew John Hughes <gnu_andrew@member.fsf.org>
PR2537: Desktop files do not allow installation from
multiple versions of IcedTea
* jconsole.desktop: Moved to jconsole.desktop.in.
* policytool.desktop: Moved to policytool.desktop.in.
* Makefile.am:
(ICEDTEA_ENV): Use @JAVA_VER@ in JRE_RELEASE_VERSION,
rather than hardcoding version.
(DESKTOP_FILES): Add Java version to filenames.
(EXTRA_DIST): Remove $(DESKTOP_FILES) as they are
now handled by autoconf and generated versions shouldn't
be packaged.
(all-local): Depend on $(DESKTOP_FILES) being created.
(clean-local): Add clean-policytool-@JAVA_VER@.desktop
and clean-jconsole-@JAVA_VER@.desktop
(.PHONY): Likewise.
(policytool-@JAVA_VER@.desktop): Generate desktop file
by replacing _BINDIR_ with actual make variable $(bindir).
(clean-policytool-@JAVA_VER@.desktop): Remove generated file.
(jconsole-@JAVA_VER@.desktop): Generate desktop file
by replacing _BINDIR_ with actual make variable $(bindir).
(clean-jconsole-@JAVA_VER@.desktop): Remove generated file.
(install-data-local): Replace hard-coded "1.7.0" with @JAVA_VER@.
Copy desktop files from build directory.
* NEWS: Updated.
* acinclude.m4:
(IT_DETERMINE_VERSION): Set JAVA_VER to 1.7.0 and include in
configure output.
* configure.ac:
Generate jconsole.desktop and policytool.desktop.
Drop AC_PREFIX_DEFAULT invocation, reverting to
/usr/local as default installation directory.
* jconsole.desktop.in: Moved from jconsole.desktop so
that @JAVA_VER@ can be replaced by configure and
_BINDIR_ by the build.
* policytool.desktop.in: Likewise for policytool.desktop.
author | Andrew John Hughes <gnu_andrew@member.fsf.org> |
---|---|
date | Thu, 16 Jul 2015 19:25:59 +0100 |
parents | f7a75cccf21b |
children | d4a9d80cb9aa |
files | ChangeLog Makefile.am NEWS acinclude.m4 configure.ac jconsole.desktop jconsole.desktop.in policytool.desktop policytool.desktop.in |
diffstat | 9 files changed, 87 insertions(+), 32 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog Thu Jul 16 01:09:59 2015 +0100 +++ b/ChangeLog Thu Jul 16 19:25:59 2015 +0100 @@ -1,3 +1,41 @@ +2015-07-16 Andrew John Hughes <gnu_andrew@member.fsf.org> + + PR2537: Desktop files do not allow installation from + multiple versions of IcedTea + * jconsole.desktop: Moved to jconsole.desktop.in. + * policytool.desktop: Moved to policytool.desktop.in. + * Makefile.am: + (ICEDTEA_ENV): Use @JAVA_VER@ in JRE_RELEASE_VERSION, + rather than hardcoding version. + (DESKTOP_FILES): Add Java version to filenames. + (EXTRA_DIST): Remove $(DESKTOP_FILES) as they are + now handled by autoconf and generated versions shouldn't + be packaged. + (all-local): Depend on $(DESKTOP_FILES) being created. + (clean-local): Add clean-policytool-@JAVA_VER@.desktop + and clean-jconsole-@JAVA_VER@.desktop + (.PHONY): Likewise. + (policytool-@JAVA_VER@.desktop): Generate desktop file + by replacing _BINDIR_ with actual make variable $(bindir). + (clean-policytool-@JAVA_VER@.desktop): Remove generated file. + (jconsole-@JAVA_VER@.desktop): Generate desktop file + by replacing _BINDIR_ with actual make variable $(bindir). + (clean-jconsole-@JAVA_VER@.desktop): Remove generated file. + (install-data-local): Replace hard-coded "1.7.0" with @JAVA_VER@. + Copy desktop files from build directory. + * NEWS: Updated. + * acinclude.m4: + (IT_DETERMINE_VERSION): Set JAVA_VER to 1.7.0 and include in + configure output. + * configure.ac: + Generate jconsole.desktop and policytool.desktop. + Drop AC_PREFIX_DEFAULT invocation, reverting to + /usr/local as default installation directory. + * jconsole.desktop.in: Moved from jconsole.desktop so + that @JAVA_VER@ can be replaced by configure and + _BINDIR_ by the build. + * policytool.desktop.in: Likewise for policytool.desktop. + 2015-07-15 Andrew John Hughes <gnu_andrew@member.fsf.org> * NEWS: Set 2.6.0 release date.
--- a/Makefile.am Thu Jul 16 01:09:59 2015 +0100 +++ b/Makefile.am Thu Jul 16 19:25:59 2015 +0100 @@ -520,7 +520,7 @@ ANT="$(ANT)" \ BUILD_NUMBER="$(BUILD_VERSION)" \ JDK_UPDATE_VERSION="$(JDK_UPDATE_VERSION)" \ - JRE_RELEASE_VERSION="1.7.0_$(COMBINED_VERSION)" \ + JRE_RELEASE_VERSION="@JAVA_VER@_$(COMBINED_VERSION)" \ MILESTONE="fcs" \ LANG="C" \ PATH="$(BOOT_DIR)/bin:$(OS_PATH):$$PATH" \ @@ -831,15 +831,14 @@ $(top_srcdir)/test/jtreg/JavaTest.cmdMgrs.lst \ $(top_srcdir)/test/jtreg/excludelist.langtools.jtx -DESKTOP_FILES = jconsole.desktop policytool.desktop +DESKTOP_FILES = jconsole-@JAVA_VER@.desktop policytool-@JAVA_VER@.desktop EXTRA_DIST = $(GENERATED_FILES) $(top_srcdir)/patches/*.patch \ $(top_srcdir)/patches/boot/*.patch \ $(top_srcdir)/patches/cacao/*.patch \ $(top_srcdir)/patches/jamvm/*.patch \ tools-copy contrib overlays \ - $(JTREG_SRCS) $(DESKTOP_FILES) \ - HACKING autogen.sh \ + $(JTREG_SRCS) HACKING autogen.sh \ tapset/hotspot.stp.in \ tapset/hotspot_jni.stp.in \ tapset/jstack.stp.in \ @@ -854,7 +853,7 @@ # Top-Level Targets # ================= -all-local: icedtea-stage2 +all-local: icedtea-stage2 $(DESKTOP_FILES) check-local: jtregcheck check-tapset @@ -873,7 +872,8 @@ clean-icedtea-debug-stage2 clean-icedtea-stage1 clean-add-zero clean-add-zero-debug \ clean-add-cacao clean-add-cacao-debug clean-rt clean-rewrite-rhino clean-rewriter \ clean-add-systemtap clean-add-systemtap-debug clean-add-nss clean-add-tzdata-support \ - clean-add-tzdata-support-debug clean-cryptocheck + clean-add-tzdata-support-debug clean-cryptocheck clean-policytool-@JAVA_VER@.desktop \ + clean-jconsole-@JAVA_VER@.desktop if [ -e bootstrap ]; then \ rmdir bootstrap ; \ fi @@ -911,7 +911,7 @@ clean-download-jaxws clean-download-langtools clean-download-jdk clean-download-openjdk \ clean-extract-corba clean-extract-jaxp clean-extract-jaxws clean-extract-jdk \ clean-extract-langtools clean-split-debuginfo clean-split-debuginfo-debug \ - clean-split-debuginfo-boot + clean-split-debuginfo-boot clean-policytool-@JAVA_VER@.desktop clean-jconsole-@JAVA_VER@.desktop env: @echo 'unset JAVA_HOME' @@ -2844,6 +2844,20 @@ rm -rf $(CRYPTO_CHECK_BUILD_DIR) rm -f stamps/cryptocheck.stamp +# File substitution + +policytool-@JAVA_VER@.desktop: policytool.desktop + cat $< | $(SED) "s#_BINDIR_#$(bindir)#" > $@ + +clean-policytool-@JAVA_VER@.desktop: + rm -f policytool-@JAVA_VER@.desktop + +jconsole-@JAVA_VER@.desktop: jconsole.desktop + cat $< | $(SED) "s#_BINDIR_#$(bindir)#" > $@ + +clean-jconsole-@JAVA_VER@.desktop: + rm -f jconsole-@JAVA_VER@.desktop + # Installation Targets # ==================== @@ -3054,10 +3068,10 @@ for sizes in 16 24 32 48 ; do \ ${mkinstalldirs} $(DESTDIR)$(datadir)/icons/hicolor/$${sizes}x$${sizes}/apps ; \ ${INSTALL_DATA} openjdk/jdk/src/solaris/classes/sun/awt/X11/java-icon$${sizes}.png \ - $(DESTDIR)$(datadir)/icons/hicolor/$${sizes}x$${sizes}/apps/java-1.7.0.png ; \ + $(DESTDIR)$(datadir)/icons/hicolor/$${sizes}x$${sizes}/apps/java-@JAVA_VER@.png ; \ done for files in $(DESKTOP_FILES) ; do \ - ${INSTALL_DATA} $(srcdir)/$${files} $(DESTDIR)$(datadir)/applications ; \ + ${INSTALL_DATA} $(builddir)/$${files} $(DESTDIR)$(datadir)/applications ; \ done touch $(DESTDIR)/${prefix}/jre/.systemPrefs/.system.lock touch $(DESTDIR)/${prefix}/jre/.systemPrefs/.systemRootModFile
--- a/NEWS Thu Jul 16 01:09:59 2015 +0100 +++ b/NEWS Thu Jul 16 19:25:59 2015 +0100 @@ -334,6 +334,7 @@ - PR2533: Allow greater control of Javadoc installation directory - PR2534: Install TRADEMARK, COPYING and ChangeLog as RPM spec file does - PR2535: install-data-local needs to check that classes.jsa actually exists + - PR2537: Desktop files do not allow installation from multiple versions of IcedTea * AArch64 port - Add copyright to aarch64_ad.m4 - S8069593: Changes to JavaThread::_thread_state must use acquire and release
--- a/acinclude.m4 Thu Jul 16 01:09:59 2015 +0100 +++ b/acinclude.m4 Thu Jul 16 19:25:59 2015 +0100 @@ -2850,9 +2850,11 @@ AC_DEFUN_ONCE([IT_DETERMINE_VERSION], [ AC_MSG_CHECKING([which branch and release of IcedTea is being built]) + JAVA_VER=1.7.0 ICEDTEA_RELEASE=$(echo ${PACKAGE_VERSION} | sed 's#pre.*##') ICEDTEA_BRANCH=$(echo ${ICEDTEA_RELEASE}|sed 's|\.[[0-9]]$||') - AC_MSG_RESULT([branch ${ICEDTEA_BRANCH}, release ${ICEDTEA_RELEASE}]) + AC_MSG_RESULT([branch ${ICEDTEA_BRANCH}, release ${ICEDTEA_RELEASE} for OpenJDK ${JAVA_VER}]) + AC_SUBST([JAVA_VER]) AC_SUBST([ICEDTEA_RELEASE]) AC_SUBST([ICEDTEA_BRANCH]) ])
--- a/configure.ac Thu Jul 16 01:09:59 2015 +0100 +++ b/configure.ac Thu Jul 16 19:25:59 2015 +0100 @@ -14,11 +14,11 @@ IT_DETERMINE_VERSION AC_CONFIG_FILES([hotspot.map fsg.sh]) +AC_CONFIG_FILES([jconsole.desktop]) +AC_CONFIG_FILES([policytool.desktop]) AC_CANONICAL_HOST -AC_PREFIX_DEFAULT([bootstrap]) - AC_PROG_CC AC_PROG_CXX
--- a/jconsole.desktop Thu Jul 16 01:09:59 2015 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,10 +0,0 @@ -[Desktop Entry] -Name=OpenJDK Monitoring & Management Console -Comment=Monitor and manage OpenJDK applications -Exec=/usr/bin/jconsole -Icon=java -Terminal=false -Type=Application -StartupWMClass=sun-tools-jconsole-JConsole -Categories=Development;Monitor;Java; -Version=1.0
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/jconsole.desktop.in Thu Jul 16 19:25:59 2015 +0100 @@ -0,0 +1,10 @@ +[Desktop Entry] +Name=OpenJDK @JAVA_VER@ Monitoring & Management Console +Comment=Monitor and manage OpenJDK applications +Exec=_BINDIR_/jconsole +Icon=java +Terminal=false +Type=Application +StartupWMClass=sun-tools-jconsole-JConsole +Categories=Development;Monitor;Java; +Version=1.0
--- a/policytool.desktop Thu Jul 16 01:09:59 2015 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,10 +0,0 @@ -[Desktop Entry] -Name=OpenJDK Policy Tool -Comment=Manage OpenJDK policy files -Exec=/usr/bin/policytool -Icon=java -Terminal=false -Type=Application -StartupWMClass=sun-security-tools-PolicyTool -Categories=Development;Java; -Version=1.0
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/policytool.desktop.in Thu Jul 16 19:25:59 2015 +0100 @@ -0,0 +1,10 @@ +[Desktop Entry] +Name=OpenJDK @JAVA_VER@ Policy Tool +Comment=Manage OpenJDK policy files +Exec=_BINDIR_/policytool +Icon=java +Terminal=false +Type=Application +StartupWMClass=sun-security-tools-PolicyTool +Categories=Development;Java; +Version=1.0