summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArthur Zamarin <arthurzam@gentoo.org>2022-01-13 16:17:25 +0200
committerGeorgy Yakovlev <gyakovlev@gentoo.org>2022-01-19 23:23:18 -0800
commitf4a0c4d5810e06a9013b546e3821b0532a2b4d8c (patch)
tree360ac902bf40b3cd0df080bbaa6f7def3a0f0cdb /dev-java
parentdev-java/openjdk: add 11.0.14_p9 (diff)
downloadgentoo-f4a0c4d5810e06a9013b546e3821b0532a2b4d8c.tar.gz
gentoo-f4a0c4d5810e06a9013b546e3821b0532a2b4d8c.tar.bz2
gentoo-f4a0c4d5810e06a9013b546e3821b0532a2b4d8c.zip
dev-java/openjdk: enable usage of bootstrapping using snapshots
Signed-off-by: Georgy Yakovlev <gyakovlev@gentoo.org> Signed-off-by: Arthur Zamarin <arthurzam@gentoo.org>
Diffstat (limited to 'dev-java')
-rw-r--r--dev-java/openjdk/Manifest2
-rw-r--r--dev-java/openjdk/metadata.xml1
-rw-r--r--dev-java/openjdk/openjdk-11.0.14_p9.ebuild57
-rw-r--r--dev-java/openjdk/openjdk-17.0.2_p8.ebuild57
4 files changed, 93 insertions, 24 deletions
diff --git a/dev-java/openjdk/Manifest b/dev-java/openjdk/Manifest
index 38a39ca62be1..e0c613ca2c60 100644
--- a/dev-java/openjdk/Manifest
+++ b/dev-java/openjdk/Manifest
@@ -11,6 +11,8 @@ DIST openjdk-aarch64-shenandoah-jaxws-8.312_p07.tar.bz2 2559773 BLAKE2B b3c06549
DIST openjdk-aarch64-shenandoah-jdk-8.312_p07.tar.bz2 48837594 BLAKE2B 368caa0a628e3bd0d0343baf7ac6c8854f6998ea5b5f96594e99ac565293bfdbfe733acfdfd398964634ffaf4e0eef298dbed078b0a61626c97711764a45a0bb SHA512 8436daa785fba98ed2c23444673842dc28b18f114ebafd203bc01bd2295a9501c2391c2e51d0f589cd4112243eee2e18a8a71180b2aca3988c58a02f33d13d57
DIST openjdk-aarch64-shenandoah-langtools-8.312_p07.tar.bz2 2403116 BLAKE2B 10c1ca4e78dfad90bf9b8d6745cda41605d5985eddfd8e4c3bfbfcb6458c5b5115813e9aa7b4aec148c4d82f268ab02ca6cef9e68bb902f1944858b6bb6b36d4 SHA512 2c9fc95cb19b1c3a4e7b9c2e305d9a285f1dedb7954cce365738e683c3a52eb7f4e3f3485b947860aee2fd6059b7d2b18e196cc1c585427c6b4b8299f6fc3105
DIST openjdk-aarch64-shenandoah-nashorn-jdk8.312_p07.tar.bz2 2845057 BLAKE2B ff32686b27b767683ae0a670b2509291b6708d371b398cac854210132f555218b9189d3012cf9b45e0584f44425e09aefb8acbef95f1786787067f4d5275fdbe SHA512 71fad14ad6b7a75ee499bc0b3370e5beb22d5a7e32a02d54fc5dff1cf25ede51c3a8a04de6424947ddaa3b5d4a0d7f5a447ba073b62c5c86a49c0543cec3f374
+DIST openjdk-bootstrap-11.0.13_p8-ppc64.tar.xz 108215404 BLAKE2B 5e6c0b905b34b437137922b73a9724da96b8832186fea945f8c73d941db822ca1cc5718f3ecb4607ed98d1f8241c9f365b54caaf978863e8b84680a94f067b5d SHA512 732e2220219d42be10589fcaf2420da87ebc8564b4afc6bd02f61f31cdca9c31b339366e34d374fb814499b92f8aa796435a18f28e10c8cb00d9a0f5953bb60e
+DIST openjdk-bootstrap-17.0.1_p12-ppc64.tar.xz 116557680 BLAKE2B d20e45a5a76e30ee60446993bf5dcf0fa10b8b668ebec637ea02b458a472c642f22740e18f28cbf9923ea4cceb17702115c038b13137442e5f0572477d37f12f SHA512 92e0343f493d094300911625a561f42c47402ca4cdbd2ac18414089e8ed8a50ca58f02ec1ef9a3dce017ab7af99a22ab465ddf732ab9e55728e2b146de56fba7
DIST openjdk-corba-8.312_p07.tar.bz2 1035097 BLAKE2B 38ae2cf2e61c44a42320b26f7bdea424066ee4568f2f3bbe6e7aa2d8b7aa927429d0b8c2cc757f580867df6c6e5dbe1270da5f91d9c52aa131e66c146a311caa SHA512 9035449c07e5fc9776b40e32de3e4f1c6efac482c14298671e5e719a1f9830fe9a20851dac3f9c6d6c0c8c387a7b44e40019570c1f054fd1d1f24e2f5cef5bfc
DIST openjdk-hotspot-8.312_p07.tar.bz2 8559682 BLAKE2B 776acb83bc065885da90b26c88f0083c3bb7bb1f6dfd0585e37e58f185b5612f6501f2b26e1eeb7533d30f82faea7ccedeeee21dcf454a4e8fe951aca0406a1d SHA512 0c501d284bb22867391de0f8da8b098ca9309173ab6f7415d591d056a2d8859757aaa3da4a9c294dcc434a41771928a9f1edd8a69dad38ef7a9bcad793deeaa8
DIST openjdk-jaxp-8.312_p07.tar.bz2 2686710 BLAKE2B acbfd2a7ebfdcfbfa1c4467dbc6778afbb2b8fab5c70381000b926645197c3bb5537a81574ed98960cae2fd0d70e50ca5976aabd0c49cf833c07f1f3b7935773 SHA512 da3fbd82ff05e48809cf6180d876f09764f5f97e4fc37c4352c7875ccd5bebe66cb51ff4565e6fcd67699ec5b5ae3eebc9c0a1510998697519cfc94d3d04df5f
diff --git a/dev-java/openjdk/metadata.xml b/dev-java/openjdk/metadata.xml
index a97614c63101..e4fe12d5b61f 100644
--- a/dev-java/openjdk/metadata.xml
+++ b/dev-java/openjdk/metadata.xml
@@ -24,6 +24,7 @@
<flag name="javafx" restrict="&gt;=dev-java/openjdk-11">Import OpenJFX modules at build time, via <pkg>dev-java/openjfx</pkg></flag>
<flag name="jbootstrap">Build OpenJDK twice, the second time using the result of the first</flag>
<flag name="source">Install JVM sources</flag>
+ <flag name="system-bootstrap">Bootstrap using installed openjdk</flag>
<flag name="systemtap" restrict="&gt;=dev-java/openjdk-11">Enable SystemTAP/DTrace tracing</flag>
</use>
</pkgmetadata>
diff --git a/dev-java/openjdk/openjdk-11.0.14_p9.ebuild b/dev-java/openjdk/openjdk-11.0.14_p9.ebuild
index 3e2a2d0ff12f..76112e4cf51d 100644
--- a/dev-java/openjdk/openjdk-11.0.14_p9.ebuild
+++ b/dev-java/openjdk/openjdk-11.0.14_p9.ebuild
@@ -10,14 +10,37 @@ inherit check-reqs flag-o-matic java-pkg-2 java-vm-2 multiprocessing pax-utils t
MY_PV="${PV%_p*}-ga"
SLOT="${MY_PV%%[.+]*}"
+# variable name format: <UPPERCASE_KEYWORD>_XPAK
+PPC64_XPAK="11.0.13_p8" # big-endian bootstrap tarball
+
+# Usage: bootstrap_uri <keyword> <version> [extracond]
+# Example: $(bootstrap_uri ppc64 17.0.1_p12 big-endian)
+# Output: ppc64? ( big-endian? ( https://...17.0.1_p12-ppc64.tar.xz ) )
+bootstrap_uri() {
+ local baseuri="https://dev.gentoo.org/~arthurzam/distfiles/dev-java/${PN}/${PN}-bootstrap"
+ local suff="tar.xz"
+ local kw="${1:?${FUNCNAME[0]}: keyword not specified}"
+ local ver="${2:?${FUNCNAME[0]}: version not specified}"
+ local cond="${3-}"
+
+ # here be dragons
+ echo "${kw}? ( ${cond:+${cond}? (} ${baseuri}-${ver}-${kw}.${suff} ${cond:+) })"
+}
+
DESCRIPTION="Open source implementation of the Java programming language"
HOMEPAGE="https://openjdk.java.net"
-SRC_URI="https://github.com/${PN}/jdk${SLOT}u/archive/refs/tags/jdk-${MY_PV}.tar.gz -> ${P}.tar.gz"
+SRC_URI="
+ https://github.com/${PN}/jdk${SLOT}u/archive/refs/tags/jdk-${MY_PV}.tar.gz
+ -> ${P}.tar.gz
+ !system-bootstrap? (
+ $(bootstrap_uri ppc64 ${PPC64_XPAK} big-endian)
+ )
+"
LICENSE="GPL-2"
KEYWORDS="~amd64 ~arm ~arm64 ~ppc64"
-IUSE="alsa cups debug doc examples gentoo-vm headless-awt javafx +jbootstrap pch selinux source systemtap"
+IUSE="alsa big-endian cups debug doc examples gentoo-vm headless-awt javafx +jbootstrap pch selinux source system-bootstrap systemtap"
COMMON_DEPEND="
media-libs/freetype:2=
@@ -63,9 +86,11 @@ DEPEND="
x11-libs/libXt
x11-libs/libXtst
javafx? ( dev-java/openjfx:${SLOT}= )
- || (
- dev-java/openjdk-bin:${SLOT}
- dev-java/openjdk:${SLOT}
+ system-bootstrap? (
+ || (
+ dev-java/openjdk-bin:${SLOT}
+ dev-java/openjdk:${SLOT}
+ )
)
"
@@ -119,6 +144,9 @@ pkg_setup() {
if has_version --host-root dev-java/openjdk:${SLOT}; then
export JDK_HOME=${EPREFIX}/usr/$(get_libdir)/openjdk-${SLOT}
+ elif use !system-bootstrap ; then
+ local xpakvar="${ARCH^^}_XPAK"
+ export JDK_HOME="${WORKDIR}/openjdk-bootstrap-${!xpakvar}"
else
if [[ ${MERGE_TYPE} != "binary" ]]; then
JDK_HOME=$(best_version --host-root dev-java/openjdk-bin:${SLOT})
@@ -156,12 +184,12 @@ src_configure() {
--with-extra-cflags="${CFLAGS}"
--with-extra-cxxflags="${CXXFLAGS}"
--with-extra-ldflags="${LDFLAGS}"
- --with-freetype=system
- --with-giflib=system
- --with-harfbuzz=system
- --with-lcms=system
- --with-libjpeg=system
- --with-libpng=system
+ --with-freetype="${XPAK_BOOTSTRAP:-system}"
+ --with-giflib="${XPAK_BOOTSTRAP:-system}"
+ --with-harfbuzz="${XPAK_BOOTSTRAP:-system}"
+ --with-lcms="${XPAK_BOOTSTRAP:-system}"
+ --with-libjpeg="${XPAK_BOOTSTRAP:-system}"
+ --with-libpng="${XPAK_BOOTSTRAP:-system}"
--with-native-debug-symbols=$(usex debug internal none)
--with-vendor-name="Gentoo"
--with-vendor-url="https://gentoo.org"
@@ -171,7 +199,7 @@ src_configure() {
--with-version-pre=""
--with-version-string="${PV%_p*}"
--with-version-build="${PV#*_p}"
- --with-zlib=system
+ --with-zlib="${XPAK_BOOTSTRAP:-system}"
--enable-dtrace=$(usex systemtap yes no)
--enable-headless-only=$(usex headless-awt yes no)
$(tc-is-clang && echo "--with-toolchain-type=clang")
@@ -198,6 +226,11 @@ src_configure() {
myconf+=( --disable-precompiled-headers )
fi
+ if use !system-bootstrap ; then
+ addpredict /dev/random
+ addpredict /proc/self/coredump_filter
+ fi
+
(
unset _JAVA_OPTIONS JAVA JAVA_TOOL_OPTIONS JAVAC XARGS
CFLAGS= CXXFLAGS= LDFLAGS= \
diff --git a/dev-java/openjdk/openjdk-17.0.2_p8.ebuild b/dev-java/openjdk/openjdk-17.0.2_p8.ebuild
index a446bf53746b..fa5f143fce01 100644
--- a/dev-java/openjdk/openjdk-17.0.2_p8.ebuild
+++ b/dev-java/openjdk/openjdk-17.0.2_p8.ebuild
@@ -5,17 +5,40 @@ EAPI=6
inherit check-reqs eapi7-ver flag-o-matic java-pkg-2 java-vm-2 multiprocessing pax-utils toolchain-funcs
+# variable name format: <UPPERCASE_KEYWORD>_XPAK
+PPC64_XPAK="17.0.1_p12" # big-endian bootstrap tarball
+
+# Usage: bootstrap_uri <keyword> <version> [extracond]
+# Example: $(bootstrap_uri ppc64 17.0.1_p12 big-endian)
+# Output: ppc64? ( big-endian? ( https://...17.0.1_p12-ppc64.tar.xz ) )
+bootstrap_uri() {
+ local baseuri="https://dev.gentoo.org/~arthurzam/distfiles/dev-java/${PN}/${PN}-bootstrap"
+ local suff="tar.xz"
+ local kw="${1:?${FUNCNAME[0]}: keyword not specified}"
+ local ver="${2:?${FUNCNAME[0]}: version not specified}"
+ local cond="${3-}"
+
+ # here be dragons
+ echo "${kw}? ( ${cond:+${cond}? (} ${baseuri}-${ver}-${kw}.${suff} ${cond:+) })"
+}
+
MY_PV="${PV//_p/+}"
SLOT="$(ver_cut 1)"
DESCRIPTION="Open source implementation of the Java programming language"
HOMEPAGE="https://openjdk.java.net"
-SRC_URI="https://github.com/openjdk/jdk${SLOT}u/archive/refs/tags/jdk-${MY_PV}.tar.gz -> ${P}.tar.gz"
+SRC_URI="
+ https://github.com/openjdk/jdk${SLOT}u/archive/refs/tags/jdk-${MY_PV}.tar.gz
+ -> ${P}.tar.gz
+ !system-bootstrap? (
+ $(bootstrap_uri ppc64 ${PPC64_XPAK} big-endian)
+ )
+"
LICENSE="GPL-2"
KEYWORDS="~amd64 ~arm ~arm64 ~ppc64"
-IUSE="alsa cups debug doc examples gentoo-vm headless-awt javafx +jbootstrap pch selinux source systemtap"
+IUSE="alsa big-endian cups debug doc examples gentoo-vm headless-awt javafx +jbootstrap pch selinux source system-bootstrap systemtap"
COMMON_DEPEND="
media-libs/freetype:2=
@@ -61,9 +84,11 @@ DEPEND="
x11-libs/libXt
x11-libs/libXtst
javafx? ( dev-java/openjfx:${SLOT}= )
- || (
- dev-java/openjdk-bin:${SLOT}
- dev-java/openjdk:${SLOT}
+ system-bootstrap? (
+ || (
+ dev-java/openjdk-bin:${SLOT}
+ dev-java/openjdk:${SLOT}
+ )
)
"
@@ -117,6 +142,9 @@ pkg_setup() {
if has_version --host-root dev-java/openjdk:${SLOT}; then
export JDK_HOME=${EPREFIX}/usr/$(get_libdir)/openjdk-${SLOT}
+ elif use !system-bootstrap ; then
+ local xpakvar="${ARCH^^}_XPAK"
+ export JDK_HOME="${WORKDIR}/openjdk-bootstrap-${!xpakvar}"
else
if [[ ${MERGE_TYPE} != "binary" ]]; then
JDK_HOME=$(best_version --host-root dev-java/openjdk-bin:${SLOT})
@@ -155,12 +183,12 @@ src_configure() {
--with-extra-cflags="${CFLAGS}"
--with-extra-cxxflags="${CXXFLAGS}"
--with-extra-ldflags="${LDFLAGS}"
- --with-freetype=system
- --with-giflib=system
- --with-harfbuzz=system
- --with-lcms=system
- --with-libjpeg=system
- --with-libpng=system
+ --with-freetype="${XPAK_BOOTSTRAP:-system}"
+ --with-giflib="${XPAK_BOOTSTRAP:-system}"
+ --with-harfbuzz="${XPAK_BOOTSTRAP:-system}"
+ --with-lcms="${XPAK_BOOTSTRAP:-system}"
+ --with-libjpeg="${XPAK_BOOTSTRAP:-system}"
+ --with-libpng="${XPAK_BOOTSTRAP:-system}"
--with-native-debug-symbols=$(usex debug internal none)
--with-vendor-name="Gentoo"
--with-vendor-url="https://gentoo.org"
@@ -170,7 +198,7 @@ src_configure() {
--with-version-pre=""
--with-version-string="${PV%_p*}"
--with-version-build="${PV#*_p}"
- --with-zlib=system
+ --with-zlib="${XPAK_BOOTSTRAP:-system}"
--enable-dtrace=$(usex systemtap yes no)
--enable-headless-only=$(usex headless-awt yes no)
$(tc-is-clang && echo "--with-toolchain-type=clang")
@@ -192,6 +220,11 @@ src_configure() {
myconf+=( --disable-precompiled-headers )
fi
+ if use !system-bootstrap ; then
+ addpredict /dev/random
+ addpredict /proc/self/coredump_filter
+ fi
+
(
unset _JAVA_OPTIONS JAVA JAVA_TOOL_OPTIONS JAVAC XARGS
CFLAGS= CXXFLAGS= LDFLAGS= \