[arch-commits] Commit in icedtea-web/trunk (3 files)

Levente Polyak anthraxx at archlinux.org
Thu Oct 10 21:03:43 UTC 2019


    Date: Thursday, October 10, 2019 @ 21:03:42
  Author: anthraxx
Revision: 364587

upgpkg: icedtea-web 1.8.3-1 (switch to new upstream)

- upstream release
- contains security patches that are important

Added:
  icedtea-web/trunk/compiler-flags.patch
  icedtea-web/trunk/java13-SecurityManager.patch
Modified:
  icedtea-web/trunk/PKGBUILD

------------------------------+
 PKGBUILD                     |   86 ++++++++++++++++++++---------------------
 compiler-flags.patch         |   69 ++++++++++++++++++++++++++++++++
 java13-SecurityManager.patch |   65 ++++++++++++++++++++++++++++++
 3 files changed, 177 insertions(+), 43 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2019-10-10 20:02:41 UTC (rev 364586)
+++ PKGBUILD	2019-10-10 21:03:42 UTC (rev 364587)
@@ -1,30 +1,37 @@
+# Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
 # Maintainer: Guillaume ALAUX <guillaume at archlinux.org>
 # Contributor: Andreas Radke <andyrtr at archlinux.org>
 
 pkgbase=icedtea-web
 pkgname=('icedtea-web' 'icedtea-web-doc')
-pkgver=1.7
+pkgver=1.8.3
 pkgrel=1
+pkgdesc='Additional components for OpenJDK - Browser plug-in and Web Start implementation'
+url='https://github.com/AdoptOpenJDK/IcedTea-Web'
 arch=('x86_64')
-url='https://icedtea.classpath.org/wiki/IcedTea-Web'
 license=('GPL2')
-makedepends=('java-environment-openjdk=8' 'zip' 'libxtst' 'npapi-sdk' 'rhino' 'junit'
-             'firefox' 'epiphany')
+makedepends=('java-environment=8' 'zip' 'libxtst' 'npapi-sdk' 'rhino' 'junit'
+             'firefox' 'epiphany' 'rust' 'bc')
 optdepends=('rhino: for using proxy auto config files')
-# Due to broken path names in the tarball that fails with LANG=C in our chroot
-noextract=("${pkgbase}-${pkgver}.tar.gz")
-source=(https://icedtea.classpath.org/download/source/${pkgbase}-${pkgver}.tar.gz{,.sig})
-validpgpkeys=('C058EF1E749812E6A486384B53B5CFF671EEED59') # Jiri Vanek <jvanek at redhat.com>
-sha256sums=('2030ea323964ae82eabe5436eef076de4b892786424ad9be21f3abc9d76c0291'
-            'SKIP')
+source=(https://github.com/AdoptOpenJDK/IcedTea-Web/archive/${pkgbase}-${pkgver}.tar.gz
+        java13-SecurityManager.patch
+        compiler-flags.patch)
+sha256sums=('41b6f09a7b44ad6b85d5086c289557f6f6340baa51be71bc4361aa26a844e7af'
+            'ee2221225afd4a577c1133b8ea4ddb7a596c7c8443cffc9185d21d404bd09f8c'
+            '4db38a59012bf4c3dc857f340924ecbc796d89f15521abdc367bc39301be7a19')
+sha512sums=('878f2abffdce56ad487d495c68c70d07553a01ec379ab81b29dee4a9ddc34182337eb4b019d84dbe32160c9b9160ff2010e566cfa9beacf901bd5a14332a2c9e'
+            '2ced4eb0542ed91a59d766bb4ca0db28a1f9b9569f48bf5b80ff178c81700067cc28a2ec99d06f479fa402ef4f290da291ad8275e52d1cbd27bee445e3ce3f7c'
+            '0689abbe5fa5b616a3c71caf038a42bc69a4950e923cce3c658c15a85a140f5d2e19a96429fc82cfe38c42fdc7bca4a305fd613e3483a8f98a6ee3daaf0a8304')
 
 prepare() {
-  cd "${srcdir}"
-  LANG=en_US.UTF-8 bsdtar -x -f "${srcdir}"/${pkgbase}-${pkgver}.tar.gz
+  cd IcedTea-Web-${pkgbase}-${pkgver}
+  patch -Np0 < "${srcdir}/compiler-flags.patch"
+  patch -Np1 < "${srcdir}/java13-SecurityManager.patch"
+  autoreconf -fiv
 }
 
 build() {
-  cd "${srcdir}"/${pkgbase}-${pkgver}
+  cd IcedTea-Web-${pkgbase}-${pkgver}
   ./configure \
       --prefix=/usr/share/${pkgbase} \
       --datarootdir=/usr/share \
@@ -33,58 +40,51 @@
       --with-java=/usr/bin/java \
       --with-browser-tests \
       --with-firefox=/usr/bin/firefox \
-      --with-epiphany=/usr/bin/epiphany
+      --with-epiphany=/usr/bin/epiphany \
+      --with-itw-libs=DISTRIBUTION
    make
 }
 
-#check() {
-#  cd "${srcdir}"/${pkgbase}-${pkgver}
-#  # as more tests have been added some are expectged to fail
-#  # see http://mail.openjdk.java.net/pipermail/distro-pkg-dev/2012-March/017566.html
-#  make -k check
-#}
+check() {
+  cd IcedTea-Web-${pkgbase}-${pkgver}
+  make -k check
+}
 
 
 package_icedtea-web() {
-
-  pkgdesc='Free web browser plugin to run applets written in Java and an implementation of Java Web Start'
   depends=('java-runtime-openjdk' 'desktop-file-utils')
   provides=('java-web-start')
-  replaces=('icedtea-web-java7')
 
-  cd "${srcdir}"/${pkgbase}-${pkgver}
-  # possible make target (see bottom of Makefile.am: install-exec-local install-data-local
-  make DESTDIR="${pkgdir}" install-exec-local install-data-local
+  cd IcedTea-Web-${pkgbase}-${pkgver}
+  make DESTDIR="${pkgdir}" install
 
-  # Install desktop files.
-  install -m 755 -d "${pkgdir}"/usr/share/{applications,pixmaps}
-  install -m 644 javaws.png "${pkgdir}"/usr/share/pixmaps
-  install -m 644 {javaws,itweb-settings}.desktop "${pkgdir}"/usr/share/applications
-  # remove splitted doc files
-  rm -rf "${pkgdir}"/usr/share/doc
+  # Install desktop files
+  install -Dm 644 javaws.png -t "${pkgdir}"/usr/share/pixmaps
+  install -Dm 644 *.desktop -t "${pkgdir}"/usr/share/applications
 
-  # link binaries into /usr/bin + jre/bin
+  ## link binaries into /usr/bin + jre/bin
   install -m 755 -d "${pkgdir}"/usr/bin
-  pushd "${pkgdir}"/usr/share/${pkgbase}/bin
-  for file in *; do
-    ln -sf /usr/share/${pkgbase}/bin/${file} "${pkgdir}"/usr/bin
+  for file in "${pkgdir}/usr/share/${pkgbase}/bin/"*; do
+    ln -sf "/usr/share/${pkgbase}/bin/$(basename "${file}")" "${pkgdir}"/usr/bin
   done
-  popd
 
-  # link the mozilla-plugin - test it here http://www.java.com/en/download/help/testvm.xml
+  ## link the mozilla-plugin - test it here http://www.java.com/en/download/help/testvm.xml
   install -m 755 -d "${pkgdir}"/usr/lib/mozilla/plugins/
   ln -sf /usr/share/${pkgbase}/lib/IcedTeaPlugin.so "${pkgdir}"/usr/lib/mozilla/plugins/
+
+  # remove splitted doc files
+  rm -rf "${pkgdir}"/usr/share/doc
 }
 
 package_icedtea-web-doc() {
+  pkgdesc+=' (documentation)'
 
-  pkgdesc='icedtea-web browser plugin + Java WebStart - documentation files'
-  replaces=('icedtea-web-java7-doc')
-
-  cd "${srcdir}"/${pkgbase}-${pkgver}
+  cd IcedTea-Web-${pkgbase}-${pkgver}
   make DESTDIR="${pkgdir}" install-data-local
   # remove javaws about and man page
   rm -rf "${pkgdir}"/usr/lib
   rm -rf "${pkgdir}"/usr/share/man
-  rm -rf "${pkgdir}"/usr/share/icedtea-web # conflicting and unneeded file it seems
+  rm -rf "${pkgdir}"/usr/share/icedtea-web
 }
+
+# vim: ts=2 sw=2 et:

Added: compiler-flags.patch
===================================================================
--- compiler-flags.patch	                        (rev 0)
+++ compiler-flags.patch	2019-10-10 21:03:42 UTC (rev 364587)
@@ -0,0 +1,69 @@
+--- Makefile.am	2019-09-16 15:31:52.584052355 +0200
++++ Makefile.am	2019-09-16 17:06:33.643083502 +0200
+@@ -593,7 +593,7 @@
+ $(PLUGIN_DIR)/%.o: $(PLUGIN_SRCDIR)/%.cc
+ 	mkdir -p $(PLUGIN_DIR) && \
+ 	cd $(PLUGIN_DIR) && \
+-	$(CXX) $(CXXFLAGS) \
++	$(CXX) $(CXXFLAGS) $(CPPFLAGS) \
+ 	   $(DEFS) $(VERSION_DEFS) \
+ 	  -DJDK_UPDATE_VERSION="\"$(JDK_UPDATE_VERSION)\"" \
+ 	  -DPLUGIN_NAME="\"IcedTea-Web Plugin\"" \
+@@ -614,10 +614,11 @@
+ 
+ $(PLUGIN_DIR)/$(BUILT_PLUGIN_LIBRARY): $(addprefix $(PLUGIN_DIR)/,$(PLUGIN_OBJECTS))
+ 	cd $(PLUGIN_DIR) && \
+-	$(CXX) $(CXXFLAGS) \
++	$(CXX) $(CXXFLAGS) $(CPPFLAGS) \
+ 	  $(PLUGIN_OBJECTS) \
+ 	  $(GLIB_LIBS) \
+ 	  $(MOZILLA_LIBS) \
++	  $(LDFLAGS) \
+ 	  -shared -o $@
+ 
+ # Start of CPP Unit test targets
+@@ -629,7 +630,7 @@
+ 	for cppfile in $$(find $(CPP_UNITTEST_FRAMEWORK_SRCDIR) -name '*.cpp') ; \
+ 	do \
+ 	  objfile="$(CPP_UNITTEST_FRAMEWORK_BUILDDIR)/$$(basename $${cppfile%.cpp}).o" ; \
+-	  $(CXX) $(CXXFLAGS) -c $$cppfile -o $$objfile || exit 1 ; \
++	  $(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $$cppfile -o $$objfile || exit 1 ; \
+ 	done ; \
+ 	ar cr $(CPP_UNITTEST_FRAMEWORK_LIB) $(CPP_UNITTEST_FRAMEWORK_BUILDDIR)/*.o ; \
+ 	popd
+@@ -648,7 +649,7 @@
+ 	do \
+ 	objfile="$(CPP_UNITTEST_DIR)/$$(basename $${cppfile%.cc}).o" ; \
+ 	echo "Compiling $$cppfile to $$objfile"; \
+-	$(CXX) $(CXXFLAGS) \
++	$(CXX) $(CXXFLAGS) $(CPPFLAGS) \
+ 	   $(DEFS) $(VERSION_DEFS) \
+ 	  -DJDK_UPDATE_VERSION="\"$(JDK_UPDATE_VERSION)\"" \
+ 	  -DPLUGIN_NAME="\"IcedTea-Web Plugin\"" \
+@@ -674,7 +675,7 @@
+ 
+ $(CPP_UNITTEST_EXECUTABLE): $(CPP_UNITTEST_FRAMEWORK_LIB) stamps/cpp-unit-tests-compile.stamp 
+ 	cd $(CPP_UNITTEST_DIR) && \
+-	$(CXX) $(CXXFLAGS) \
++	  $(CXX) $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) \
+ 	  $(addprefix $(PLUGIN_DIR)/,$(PLUGIN_OBJECTS)) \
+ 	  $(CPP_UNITTEST_DIR)/*.o \
+ 	  -lrt \
+@@ -1753,7 +1754,7 @@
+ 	
+ $(COVERABLE_PLUGIN_DIR)/%.o: $(PLUGIN_SRCDIR)/%.cc
+ 	cd $(COVERABLE_PLUGIN_DIR) && \
+-	$(CXX) $(CXXFLAGS) \
++	$(CXX) $(CXXFLAGS) $(CPPFLAGS) \
+ 	   $(DEFS) $(VERSION_DEFS) \
+ 	  -DJDK_UPDATE_VERSION="\"$(JDK_UPDATE_VERSION)\"" \
+ 	  -DPLUGIN_NAME="\"IcedTea-Web Plugin with jacoco coverage agent\"" \
+@@ -1775,7 +1776,7 @@
+ 
+ $(COVERABLE_PLUGIN_DIR)/$(BUILT_PLUGIN_LIBRARY): $(addprefix $(COVERABLE_PLUGIN_DIR)/,$(PLUGIN_OBJECTS))
+ 	cd $(COVERABLE_PLUGIN_DIR) && \
+-	$(CXX) $(CXXFLAGS) \
++	$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) \
+ 	  $(PLUGIN_OBJECTS) \
+ 	  $(GLIB_LIBS) \
+ 	  $(MOZILLA_LIBS) \

Added: java13-SecurityManager.patch
===================================================================
--- java13-SecurityManager.patch	                        (rev 0)
+++ java13-SecurityManager.patch	2019-10-10 21:03:42 UTC (rev 364587)
@@ -0,0 +1,65 @@
+From 276806d9984331c754fb636ab11f05e78b3fc8c7 Mon Sep 17 00:00:00 2001
+From: Martin Schelldorfer <schelldorfer at gmail.com>
+Date: Fri, 20 Sep 2019 14:51:29 +0200
+Subject: [PATCH]  #437 Application cannot be started with JDK 13 -
+ AWTSecurityManager was removed
+
+---
+ .../jnlp/runtime/JNLPSecurityManager.java     | 30 +------------------
+ 1 file changed, 1 insertion(+), 29 deletions(-)
+
+diff --git a/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java b/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java
+index 367b2b25..be418103 100644
+--- a/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java
++++ b/netx/net/sourceforge/jnlp/runtime/JNLPSecurityManager.java
+@@ -29,7 +29,6 @@
+ import net.sourceforge.jnlp.util.logging.OutputController;
+ import net.sourceforge.jnlp.util.WeakList;
+ import net.sourceforge.swing.SwingUtils;
+-import sun.awt.AWTSecurityManager;
+ import sun.awt.AppContext;
+
+ /**
+@@ -47,7 +46,7 @@
+  * @author <a href="mailto:jmaxwell at users.sourceforge.net">Jon A. Maxwell (JAM)</a> - initial author
+  * @version $Revision: 1.17 $
+  */
+-class JNLPSecurityManager extends AWTSecurityManager {
++class JNLPSecurityManager extends SecurityManager {
+
+     // todo: some apps like JDiskReport can close the VM even when
+     // an exit class is set - fix!
+@@ -424,33 +423,6 @@
+     }
+
+     /**
+-     * This returns the appropriate {@link AppContext}. Hooks in AppContext
+-     * check if the current {@link SecurityManager} is an instance of
+-     * AWTSecurityManager and if so, call this method to give it a chance to
+-     * return the appropriate appContext based on the application that is
+-     * running.
+-     * <p>
+-     * This can be called from any thread (possibly a swing thread) to find out
+-     * the AppContext for the thread (which may correspond to a particular
+-     * applet).
+-     * </p>
+-     */
+-    @Override
+-    public AppContext getAppContext() {
+-        ApplicationInstance app = getApplication();
+-        if (app == null) {
+-            /*
+-             * if we cannot find an application based on the code on the stack,
+-             * then assume it is the main application
+-             */
+-            return mainAppContext;
+-        } else {
+-            return app.getAppContext();
+-        }
+-
+-    }
+-
+-    /**
+      * Tests if a client can get access to the AWT event queue. This version allows
+      * complete access to the EventQueue for its own AppContext-specific EventQueue.
+      *



More information about the arch-commits mailing list