aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimon Frankenberger <simon@fraho.eu>2020-03-25 08:05:23 +0100
committerRasmus Thomsen <oss@cogitri.dev>2020-03-25 12:41:14 +0000
commitc9b97e700523162e327870dafcb48dc7342f7466 (patch)
tree5a78cfdefeb49052ed6b91c85d7bf1670e7131be
parent8118704de68b0fe5edfc9d98cf62536b08eae5f9 (diff)
downloadaports-c9b97e700523162e327870dafcb48dc7342f7466.tar.gz
aports-c9b97e700523162e327870dafcb48dc7342f7466.tar.bz2
aports-c9b97e700523162e327870dafcb48dc7342f7466.tar.xz
testing/openjdk12: Cleanup and unify with other openjdk aports
-rw-r--r--testing/openjdk12/APKBUILD40
-rw-r--r--testing/openjdk12/arm.patch28
-rw-r--r--testing/openjdk12/fix-bootjdk-check.patch15
-rw-r--r--testing/openjdk12/make-4.3.patch17
-rw-r--r--testing/openjdk12/x86.patch140
5 files changed, 46 insertions, 194 deletions
diff --git a/testing/openjdk12/APKBUILD b/testing/openjdk12/APKBUILD
index d1b0d74dcd..de865808ee 100644
--- a/testing/openjdk12/APKBUILD
+++ b/testing/openjdk12/APKBUILD
@@ -2,11 +2,11 @@
# Maintainer: Simon Frankenberger <simon-alpine@fraho.eu>
pkgname=openjdk12
pkgver=12.0.2_p10
-_pkgver=${pkgver/_p/+}
-pkgrel=0
+_pkgver=${pkgver/_p10/-ga}
+pkgrel=1
pkgdesc="Oracle OpenJDK 12"
url="https://hg.openjdk.java.net/jdk-updates/jdk12u"
-arch="all !x86 !armhf !armv7" # oracle dopped support for 32 bit arches, so disable for now
+arch="all !x86 !armhf !armv7" # oracle dropped support for 32 bit
license="GPL-2.0-with-classpath-exception"
makedepends="autoconf
bash
@@ -37,18 +37,17 @@ depends="$pkgname-jmods $pkgname-demos $pkgname-doc $pkgname-jdk" # for the virt
subpackages="$pkgname-jmods:_jmods:noarch
$pkgname-demos:_demos:noarch
$pkgname-doc:_doc:noarch
- $pkgname-dbg:_dbg
$pkgname-jre:_jre
$pkgname-src:_src:noarch
$pkgname-jre-headless:_jre_headless
$pkgname-jdk:_jdk"
-source="jdk-$_pkgver.tar.bz2::http://hg.openjdk.java.net/jdk-updates/jdk12u/archive/jdk-$_pkgver.tar.bz2
+source="jdk-$_pkgver.tar.gz::https://github.com/openjdk/jdk12u/archive/jdk-$_pkgver.tar.gz
build.patch
aarch64.patch
- arm.patch
ppc64le.patch
- x86.patch
+ make-4.3.patch
+ fix-bootjdk-check.patch
HelloWorld.java
TestECDSA.java
@@ -94,9 +93,9 @@ build() {
# CFLAGS, CXXFLAGS and LDFLAGS are ignored as shown by a warning
# in the output of ./configure unless used like such:
- # --with-extra-cflags="${CFLAGS}"
- # --with-extra-cxxflags="${CXXFLAGS}"
- # --with-extra-ldflags="${LDFLAGS}"
+ # --with-extra-cflags="$CFLAGS"
+ # --with-extra-cxxflags="$CXXFLAGS"
+ # --with-extra-ldflags="$LDFLAGS"
# See also paragraph "Configure Control Variables" from "common/doc/building.md"
# shellcheck disable=2097 disable=2098
CFLAGS='' CXXFLAGS='' LDFLAGS='' \
@@ -119,7 +118,7 @@ build() {
--with-lcms=system \
--with-jobs=${JOBS:-4} \
--with-test-jobs=${JOBS:-4} \
- --with-native-debug-symbols=external \
+ --with-native-debug-symbols=none \
$_with_jtreg \
--disable-warnings-as-errors \
--disable-precompiled-headers \
@@ -127,7 +126,7 @@ build() {
--with-jvm-variants=server \
--with-debug-level=release \
--with-version-pre= \
- --with-version-opt=alpine-r${pkgrel} \
+ --with-version-opt="alpine-r$pkgrel" \
--with-version-build=${_pkgver#*+} \
--with-vendor-name="Alpine" \
--with-vendor-url="https://alpinelinux.org/" \
@@ -213,17 +212,6 @@ _doc() {
mv "$_fromroot/man" "$_toroot"
}
-_dbg() {
- pkgdesc="Oracle OpenJDK 12 (debug)"
- depends="$pkgname-jdk"
- _fromroot="$pkgdir/$_java_home"
- _toroot="$subpkgdir/$_java_home"
-
- mkdir -p "$_toroot/lib/server"
- mv "$_fromroot"/lib/server/*.debuginfo "$_toroot"/lib/server
- mv "$_fromroot"/lib/*.debuginfo "$_toroot"/lib
-}
-
_jre() {
pkgdesc="Oracle OpenJDK 12 (JRE)"
depends="$pkgname-jre-headless"
@@ -296,12 +284,12 @@ _jdk() {
mv "$_fromroot/include" "$_toroot"
}
-sha512sums="62aa64ac500fa5a13349c9b27c54408c22336fe0573bc0575c94b9b3f9a6657cd8d19d45b1b9ae4f6c759892144d5abeed49f9ce0c004b84ade9f59c7aeaa923 jdk-12.0.2+10.tar.bz2
+sha512sums="370e3d8378fcdf929df7325ac988ffcb4565c3fbb7cd1831554e0977769f1beaef0185ac8c7df40b5d74ca88acb27f657fb617279f58a8f78cf2adac10b95882 jdk-12.0.2-ga.tar.gz
fe1b54d6006e9f77c1ebc0705e28eb962f42571b4e4ee5cd73e0c7000cbf46f90df4a83b72421261e02abec488f493111d28893a27edf2af8eb43a9ecee00833 build.patch
8c0f1f8d2a78ebb30a8460bc0ea9cd2349cea98819df1577bf7de19a1dd82d06a593f36b4e17c282ed53d23f00163e387e3dd1f3c9e5a092726e78c3aa710370 aarch64.patch
-56a74c4f4437358f62e2955724a9a8c547ccd765cf509476f435bf62b9dc07c323635a2679162bd6e83229e50cd60b7711cdf1e1dcb061f775f6be8c0a64a1f1 arm.patch
b6b1623a8dffd5a91bf122d7ef5a4b7cd2dff9dde072e9613eb38b1c95000c95b1eef7eb8ea8edc8bc3a59592ba3cf78bd32d31a8c6e3a30c24fc2030405a696 ppc64le.patch
-0e4818b252e2af178f4c33e674de8dec934e7304f38c3f228aeb16ca8f3888b6bfdf0338a1b9fa48a44bc89bcf3ff4a48e22948a06f8df1fd9aeb93a7302d95a x86.patch
+ee8ba62ab5909648dccc1d5e1d12b4f35e813320a7919476bc1ff35bc2ef51030df3426616e0f636dd64a8b07021201f7bcb477253bb33a97cd0db8a6684137c make-4.3.patch
+5261f5d30659991869a069ee50988ccb4741951def70a172bbe978c0bbb2d7dc0fe4595d9ac19ae28137a13e246882f21a275b1553652ab20b96ca9af550e444 fix-bootjdk-check.patch
d1767dddd8e0956e25c0f77ed45c6fc86a1191bae1704a6dc33be490fd20eaa50461fe5c2a3349512059d555651e2eb41437dd3c1096c351e8ee68b4534a2579 HelloWorld.java
27e91edef89d26c0c5b9a813e2045f8d2b348745a506ae37b34b660fa7093da9a4e0e676ea41dc4a5c901bce02e5304d95e90f68d6c99cbf461b2da40a7a9853 TestECDSA.java
b02dff8d549f88317bb4c741a9e269e8d59eef990197d085388fc49c7423a4eb9367dbe1e02bffb10e7862f5980301eb58d4494e177d0e8f60af6b05c7fbbe60 TestCryptoLevel.java
diff --git a/testing/openjdk12/arm.patch b/testing/openjdk12/arm.patch
deleted file mode 100644
index d31699a2bd..0000000000
--- a/testing/openjdk12/arm.patch
+++ /dev/null
@@ -1,28 +0,0 @@
---- old/src/hotspot/os_cpu/linux_arm/os_linux_arm.cpp
-+++ new/src/hotspot/os_cpu/linux_arm/os_linux_arm.cpp
-@@ -71,7 +71,6 @@
- # include <pwd.h>
- # include <poll.h>
- # include <ucontext.h>
--# include <fpu_control.h>
- # include <asm/ptrace.h>
-
- #define SPELL_REG_SP "sp"
-@@ -91,6 +90,17 @@
- return (char*) -1;
- }
-
-+// Stupid hack as the origin if below doesnt compile with gcc 8.2.0:
-+//
-+// os_linux_arm.cpp:114:5: error: missing binary operator before token "("
-+// #if NGREG == 16
-+// ^~~~~
-+//
-+// The NGREG is 18, so force it to that value.
-+#ifdef NGREG
-+# undef NGREG
-+#endif
-+#define NGREG 18
-
- #if NGREG == 16
- // These definitions are based on the observation that until
diff --git a/testing/openjdk12/fix-bootjdk-check.patch b/testing/openjdk12/fix-bootjdk-check.patch
new file mode 100644
index 0000000000..c7fe679b36
--- /dev/null
+++ b/testing/openjdk12/fix-bootjdk-check.patch
@@ -0,0 +1,15 @@
+The alpine builders print out a warning about sched_getaffinity() not working.
+This causes the version check for the boot jdk to fail.
+Patch the command to determine the version number to ignore any errors and warnings.
+
+--- old/make/autoconf/boot-jdk.m4
++++ new/make/autoconf/boot-jdk.m4
+@@ -74,7 +74,7 @@
+ BOOT_JDK_FOUND=no
+ else
+ # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version?
+- BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" $USER_BOOT_JDK_OPTIONS -version 2>&1 | $HEAD -n 1`
++ BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" $USER_BOOT_JDK_OPTIONS -version 2>&1 | $GREP version | $HEAD -n 1`
+ if [ [[ "$BOOT_JDK_VERSION" =~ "Picked up" ]] ]; then
+ AC_MSG_NOTICE([You have _JAVA_OPTIONS or JAVA_TOOL_OPTIONS set. This can mess up the build. Please use --with-boot-jdk-jvmargs instead.])
+ AC_MSG_NOTICE([Java reports: "$BOOT_JDK_VERSION".])
diff --git a/testing/openjdk12/make-4.3.patch b/testing/openjdk12/make-4.3.patch
new file mode 100644
index 0000000000..6720709cda
--- /dev/null
+++ b/testing/openjdk12/make-4.3.patch
@@ -0,0 +1,17 @@
+upstream report: https://bugs.openjdk.java.net/browse/JDK-8237879.
+
+diff --git a/make/common/MakeBase.gmk b/make/common/MakeBase.gmk
+index 170c3ed..697f9d2 100644
+--- a/make/common/MakeBase.gmk
++++ b/make/common/MakeBase.gmk
+@@ -984,7 +984,9 @@ DependOnVariableHelper = \
+ $(info NewVariable $1: >$(strip $($1))<) \
+ $(info OldVariable $1: >$(strip $($1_old))<)) \
+ $(call WriteFile, $1_old:=$(call DoubleDollar,$(call EscapeHash,$($1))), \
+- $(call DependOnVariableFileName, $1, $2))) \
++ $(call DependOnVariableFileName, $1, $2)) \
++ $(eval $(call DependOnVariableFileName, $1, $2): ) \
++ ) \
+ $(call DependOnVariableFileName, $1, $2) \
+ )
+
diff --git a/testing/openjdk12/x86.patch b/testing/openjdk12/x86.patch
deleted file mode 100644
index 8425b794f0..0000000000
--- a/testing/openjdk12/x86.patch
+++ /dev/null
@@ -1,140 +0,0 @@
---- old/src/hotspot/os_cpu/linux_x86/os_linux_x86.cpp
-+++ new/src/hotspot/os_cpu/linux_x86/os_linux_x86.cpp
-@@ -90,6 +90,126 @@
- #define SPELL_REG_FP "ebp"
- #endif // AMD64
-
-+// ==============================================================================
-+// Taken from glibc 2.28
-+// source: https://sourceware.org/git/?p=glibc.git;a=blob;f=sysdeps/x86/fpu_control.h;h=4cb98c5679b2897ff4e5826d228cba6be589e24d;hb=3c03baca37fdcb52c3881e653ca392bba7a99c2b
-+// ==============================================================================
-+#ifndef AMD64
-+/* FPU control word bits. x86 version.
-+ Copyright (C) 1993-2018 Free Software Foundation, Inc.
-+ This file is part of the GNU C Library.
-+ Contributed by Olaf Flebbe.
-+
-+ The GNU C Library is free software; you can redistribute it and/or
-+ modify it under the terms of the GNU Lesser General Public
-+ License as published by the Free Software Foundation; either
-+ version 2.1 of the License, or (at your option) any later version.
-+
-+ The GNU C Library is distributed in the hope that it will be useful,
-+ but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-+ Lesser General Public License for more details.
-+
-+ You should have received a copy of the GNU Lesser General Public
-+ License along with the GNU C Library; if not, see
-+ <http://www.gnu.org/licenses/>. */
-+
-+#ifndef _FPU_CONTROL_H
-+#define _FPU_CONTROL_H 1
-+
-+/* Note that this file sets on x86-64 only the x87 FPU, it does not
-+ touch the SSE unit. */
-+
-+/* Here is the dirty part. Set up your 387 through the control word
-+ * (cw) register.
-+ *
-+ * 15-13 12 11-10 9-8 7-6 5 4 3 2 1 0
-+ * | reserved | IC | RC | PC | reserved | PM | UM | OM | ZM | DM | IM
-+ *
-+ * IM: Invalid operation mask
-+ * DM: Denormalized operand mask
-+ * ZM: Zero-divide mask
-+ * OM: Overflow mask
-+ * UM: Underflow mask
-+ * PM: Precision (inexact result) mask
-+ *
-+ * Mask bit is 1 means no interrupt.
-+ *
-+ * PC: Precision control
-+ * 11 - round to extended precision
-+ * 10 - round to double precision
-+ * 00 - round to single precision
-+ *
-+ * RC: Rounding control
-+ * 00 - rounding to nearest
-+ * 01 - rounding down (toward - infinity)
-+ * 10 - rounding up (toward + infinity)
-+ * 11 - rounding toward zero
-+ *
-+ * IC: Infinity control
-+ * That is for 8087 and 80287 only.
-+ *
-+ * The hardware default is 0x037f which we use.
-+ */
-+
-+#include <features.h>
-+
-+/* masking of interrupts */
-+#define _FPU_MASK_IM 0x01
-+#define _FPU_MASK_DM 0x02
-+#define _FPU_MASK_ZM 0x04
-+#define _FPU_MASK_OM 0x08
-+#define _FPU_MASK_UM 0x10
-+#define _FPU_MASK_PM 0x20
-+
-+/* precision control */
-+#define _FPU_EXTENDED 0x300 /* libm requires double extended precision. */
-+#define _FPU_DOUBLE 0x200
-+#define _FPU_SINGLE 0x0
-+
-+/* rounding control */
-+#define _FPU_RC_NEAREST 0x0 /* RECOMMENDED */
-+#define _FPU_RC_DOWN 0x400
-+#define _FPU_RC_UP 0x800
-+#define _FPU_RC_ZERO 0xC00
-+
-+#define _FPU_RESERVED 0xF0C0 /* Reserved bits in cw */
-+
-+
-+/* The fdlibm code requires strict IEEE double precision arithmetic,
-+ and no interrupts for exceptions, rounding to nearest. */
-+
-+#define _FPU_DEFAULT 0x037f
-+
-+/* IEEE: same as above. */
-+#define _FPU_IEEE 0x037f
-+
-+/* Type of the control word. */
-+typedef unsigned int fpu_control_t __attribute__ ((__mode__ (__HI__)));
-+
-+/* Macros for accessing the hardware control word. "*&" is used to
-+ work around a bug in older versions of GCC. __volatile__ is used
-+ to support combination of writing the control register and reading
-+ it back. Without __volatile__, the old value may be used for reading
-+ back under compiler optimization.
-+
-+ Note that the use of these macros is not sufficient anymore with
-+ recent hardware nor on x86-64. Some floating point operations are
-+ executed in the SSE/SSE2 engines which have their own control and
-+ status register. */
-+#define _FPU_GETCW(cw) __asm__ __volatile__ ("fnstcw %0" : "=m" (*&cw))
-+#define _FPU_SETCW(cw) __asm__ __volatile__ ("fldcw %0" : : "m" (*&cw))
-+
-+/* Default control word set at startup. */
-+extern fpu_control_t __fpu_control;
-+
-+#endif /* fpu_control.h */
-+
-+#endif // AMD64
-+// ==============================================================================
-+// ==============================================================================
-+// ==============================================================================
-+
- address os::current_stack_pointer() {
- #ifdef SPARC_WORKS
- void *esp;
---- old/make/hotspot/lib/JvmOverrideFiles.gmk
-+++ new/make/hotspot/lib/JvmOverrideFiles.gmk
-@@ -80,7 +80,7 @@
- # Declare variables for each source file that needs the pic flag like this:
- # BUILD_JVM_<srcfile>_CXXFLAGS := -fno-PIC
- # This will get implicitly picked up by SetupNativeCompilation below.
-- $(foreach s, $(NONPIC_SRC), $(eval BUILD_LIBJVM_$(notdir $s)_CXXFLAGS := -fno-PIC))
-+ #$(foreach s, $(NONPIC_SRC), $(eval BUILD_LIBJVM_$(notdir $s)_CXXFLAGS := -fno-PIC))
- endif
-
- else ifeq ($(OPENJDK_TARGET_OS), solaris)