diff options
Diffstat (limited to 'dev-java/openjdk/openjdk-11.0.14_p9.ebuild')
-rw-r--r-- | dev-java/openjdk/openjdk-11.0.14_p9.ebuild | 57 |
1 files changed, 45 insertions, 12 deletions
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= \ |