diff options
Diffstat (limited to 'dev-java')
37 files changed, 686 insertions, 1160 deletions
diff --git a/dev-java/freemarker-bin/Manifest b/dev-java/freemarker-bin/Manifest deleted file mode 100644 index d95f30d..0000000 --- a/dev-java/freemarker-bin/Manifest +++ /dev/null @@ -1 +0,0 @@ -DIST apache-freemarker-2.3.31-bin.tar.gz 3193874 BLAKE2B 5f11d07c6c37d84820d00c56cea420c4b0570259e5e35e6f87f7eb6c0204735c58f72d181a9bc22f0a7234ef09292cba34b00b88a60546c79ad590ab8cd49359 SHA512 c3d9aefa0c0d2703835d7fbed7c6d3074b4be97b4e7c3ec7995f69e7dbb34e24e559ecf8261aa048a7230c1916db593de685a7af3b03e08ec75b1996d1f811fb diff --git a/dev-java/freemarker-bin/freemarker-bin-2.3.31.ebuild b/dev-java/freemarker-bin/freemarker-bin-2.3.31.ebuild deleted file mode 100644 index 04be86b..0000000 --- a/dev-java/freemarker-bin/freemarker-bin-2.3.31.ebuild +++ /dev/null @@ -1,24 +0,0 @@ -# Copyright 1999-2018 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=7 - -inherit java-pkg-2 - -DESCRIPTION="A Java tool to generate text output based on templates (binary package)" -HOMEPAGE="https://freemarker.apache.org/" -SRC_URI="https://downloads.apache.org/freemarker/engine/${PV}/binaries/apache-freemarker-${PV}-bin.tar.gz" -LICENSE="Apache-2.0" -SLOT="0" -KEYWORDS="~amd64 ~x86" - -RDEPEND=" - !dev-java/freemarker - >=virtual/jre-1.7 -" - -S="${WORKDIR}/apache-freemarker-${PV}-bin" - -src_install() { - java-pkg_dojar freemarker.jar -} diff --git a/dev-java/freemarker-bin/metadata.xml b/dev-java/freemarker-bin/metadata.xml deleted file mode 100644 index 004555a..0000000 --- a/dev-java/freemarker-bin/metadata.xml +++ /dev/null @@ -1,8 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> -<pkgmetadata> - <maintainer type="person"> - <email>alex_y_xu@yahoo.ca</email> - <name>Alex Xu (Hello71)</name> - </maintainer> -</pkgmetadata> diff --git a/dev-java/openj9-openjdk-bin/Manifest b/dev-java/openj9-openjdk-bin/Manifest index 5c0a132..998cf94 100644 --- a/dev-java/openj9-openjdk-bin/Manifest +++ b/dev-java/openj9-openjdk-bin/Manifest @@ -1,16 +1,18 @@ -DIST ibm-semeru-open-debugimage_aarch64_linux_11.0.12_7_openj9-0.27.0.tar.gz 257296341 SHA256 c80416fd8e9f100746ca06166dd50a724d3b4b077162350f2b88ff6b746aefb8 -DIST ibm-semeru-open-debugimage_aarch64_linux_16.0.2_7_openj9-0.27.0.tar.gz 260567193 SHA256 bd8c8f9a07444c5b4c5e88de3bf952d27ef93e1f95485a027d84b4158141593f -DIST ibm-semeru-open-debugimage_ppc64le_linux_11.0.12_7_openj9-0.27.0.tar.gz 310406729 SHA256 b3f2a7de056bd6a817a28baaca93b7337163941fe88a49ea2460ce677f4144d5 -DIST ibm-semeru-open-debugimage_ppc64le_linux_16.0.2_7_openj9-0.27.0.tar.gz 313671311 SHA256 92535ef6c071e6e00dba4988fb4ec2533cb1c27232d1b308cc872043ed4ffc98 -DIST ibm-semeru-open-debugimage_s390x_linux_11.0.12_7_openj9-0.27.0.tar.gz 275761551 SHA256 eb7b44331d65771f4ef72978b8088166007a340330c8eda0de0a6a29d566842c -DIST ibm-semeru-open-debugimage_s390x_linux_16.0.2_7_openj9-0.27.0.tar.gz 279233218 SHA256 b771cd97b91cf9233b5ae3fa4970debac036c434ebce03c833bc73113f03986c -DIST ibm-semeru-open-debugimage_x64_linux_11.0.12_7_openj9-0.27.0.tar.gz 320291464 SHA256 a3bf2cf972394b0dfd4f984dfe2d71fea3552ba448c0c050057091c587bf4be3 -DIST ibm-semeru-open-debugimage_x64_linux_16.0.2_7_openj9-0.27.0.tar.gz 323689143 SHA256 24a871c4ea86fec1bca82df385ef28d2315703d62c841344839b52a1ac21d6ad -DIST ibm-semeru-open-jdk_aarch64_linux_11.0.12_7_openj9-0.27.0.tar.gz 197763167 SHA256 f025af94a65872653baeb6f889ec6d592ce9d92391fa04e82fb68a50b96178a7 -DIST ibm-semeru-open-jdk_aarch64_linux_16.0.2_7_openj9-0.27.0.tar.gz 200907027 SHA256 022cda1210331488c3db3d0d1282ea74467397fdabc34cb482cdfe81c45f6a15 -DIST ibm-semeru-open-jdk_ppc64le_linux_11.0.12_7_openj9-0.27.0.tar.gz 203013889 SHA256 7d49a5b29a84831526f7bffaaee399ac9a26d05712ac4b9cb7ca0a370ed3f020 -DIST ibm-semeru-open-jdk_ppc64le_linux_16.0.2_7_openj9-0.27.0.tar.gz 206337625 SHA256 d5901996f2c0889b2b92de97fed0b36d5068da308be0fbd6c8293a6b6b91634d -DIST ibm-semeru-open-jdk_s390x_linux_11.0.12_7_openj9-0.27.0.tar.gz 200393575 SHA256 991f8df53079378782b9de3bbfd4c52a19920ea9ba90e9a54c871ce47b599cdb -DIST ibm-semeru-open-jdk_s390x_linux_16.0.2_7_openj9-0.27.0.tar.gz 203152325 SHA256 3a2741a2e14b9934405a6c0b6af9e865687a70814af355e62dd84025707ccfdc -DIST ibm-semeru-open-jdk_x64_linux_11.0.12_7_openj9-0.27.0.tar.gz 202156239 SHA256 4c2d776f69e3ff7d01cd57c0938b7a7f058264425faf18e3708b905e93f915c4 -DIST ibm-semeru-open-jdk_x64_linux_16.0.2_7_openj9-0.27.0.tar.gz 205317058 SHA256 1349eb9a1d9af491a1984d66a80126730357c4a5c4fcbe7112a2c832f6c0886e +DIST ibm-semeru-open-debugimage_aarch64_linux_11.0.27_6_openj9-0.51.0.tar.gz 392541433 SHA256 db6da3a6b41410a4a2e75aa5b733e2500730baa480be0f60f4bf79273e0dabe1 +DIST ibm-semeru-open-debugimage_aarch64_linux_17.0.15_6_openj9-0.51.0.tar.gz 388670023 SHA256 48514a5a6a42589221360a31086ef17962cbffb6161d7e2644c6bada110480d2 +DIST ibm-semeru-open-debugimage_aarch64_linux_21.0.7_6_openj9-0.51.0.tar.gz 392473040 SHA256 ea43a44ca03734f6616e9cddc7c85fac0a46cca094b2ba77e853eac8c9f08e7d +DIST ibm-semeru-open-debugimage_ppc64le_linux_11.0.27_6_openj9-0.51.0.tar.gz 406192866 SHA256 23a3b21a54649fbab4bce711571fbac747ea746782350f11b61b0027a98bd8bd +DIST ibm-semeru-open-debugimage_ppc64le_linux_17.0.15_6_openj9-0.51.0.tar.gz 402615768 SHA256 6f0843adb3685e3a9debf6e18253748c8bf8e309075903a847e99668f44b7e3f +DIST ibm-semeru-open-debugimage_ppc64le_linux_21.0.7_6_openj9-0.51.0.tar.gz 406680845 SHA256 46c066f829cd752fe9d3c35f48df3269f9539655499b0f67c7497a6cb25afb16 +DIST ibm-semeru-open-debugimage_x64_linux_11.0.27_6_openj9-0.51.0.tar.gz 416188045 SHA256 49987b5f8c9cf9d4d9a267c7c735b6e9674608af7c3669765354e0600a552c14 +DIST ibm-semeru-open-debugimage_x64_linux_17.0.15_6_openj9-0.51.0.tar.gz 411832363 SHA256 fadb8e67da8af2201dde91d959f1698e5724b3ec1e4e0f5b8e3482e175fc19f7 +DIST ibm-semeru-open-debugimage_x64_linux_21.0.7_6_openj9-0.51.0.tar.gz 416057502 SHA256 747fa72c225040b1128e9d3311b5f89441730eae43132cf7b1dd4715243c5ae4 +DIST ibm-semeru-open-jdk_aarch64_linux_11.0.27_6_openj9-0.51.0.tar.gz 206134841 SHA256 41aa50c53f899ff3ae49fa84cf5e5ef218b5670ffd3822ed13df136339190417 +DIST ibm-semeru-open-jdk_aarch64_linux_17.0.15_6_openj9-0.51.0.tar.gz 209490355 SHA256 08a982b6fbca457718bc43d14f1e836d7aa93eeaec7cd308793f990f8a5755ed +DIST ibm-semeru-open-jdk_aarch64_linux_21.0.7_6_openj9-0.51.0.tar.gz 223101860 SHA256 a2bd932fc2737f7605172dbfc4f6a1dfa262cbf9606a21cb83ba1ea94c5898e0 +DIST ibm-semeru-open-jdk_ppc64le_linux_11.0.27_6_openj9-0.51.0.tar.gz 216745194 SHA256 e6e9fde688965274b025b998d44a84d03d27428bcb2116dc38ddfd2dd25c7699 +DIST ibm-semeru-open-jdk_ppc64le_linux_17.0.15_6_openj9-0.51.0.tar.gz 220764693 SHA256 41831486054fab00e1ea925b465ee162ba9ad8b65420d50ff7b3dbccd11e1542 +DIST ibm-semeru-open-jdk_ppc64le_linux_21.0.7_6_openj9-0.51.0.tar.gz 234557620 SHA256 7e094e5a25b46452ef2067be50a8b5137a1a00d9fddf47993b0a1f56e70c1632 +DIST ibm-semeru-open-jdk_x64_linux_11.0.27_6_openj9-0.51.0.tar.gz 213541898 SHA256 13aa056c7f6b4bdee89d98b319fc5894f02deb2e019023f44699928281b6df69 +DIST ibm-semeru-open-jdk_x64_linux_17.0.15_6_openj9-0.51.0.tar.gz 217452384 SHA256 7df65eeedda313cd73d28e6f46029f48b96e4d329066f0438b9b2b43aaafad59 +DIST ibm-semeru-open-jdk_x64_linux_21.0.7_6_openj9-0.51.0.tar.gz 231105498 SHA256 70228be801934a3a51761cc6ec5531b4ab52a8942efd2f0f5033ae6b24ae1423 diff --git a/dev-java/openj9-openjdk-bin/files/openj9-openjdk-bin.env.sh b/dev-java/openj9-openjdk-bin/files/openj9-openjdk-bin.env.sh index 2e200d9..f4e3c9a 100644 --- a/dev-java/openj9-openjdk-bin/files/openj9-openjdk-bin.env.sh +++ b/dev-java/openj9-openjdk-bin/files/openj9-openjdk-bin.env.sh @@ -1,7 +1,4 @@ -# Copyright 1999-2018 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -VERSION="AdoptOpenJDK ${DL_PV}" +VERSION="IBM Semeru JDK ${DL_PV}" JAVA_HOME="${EPREFIX}/opt/${P}" JDK_HOME="${EPREFIX}/opt/${P}" JAVAC="\${JAVA_HOME}/bin/javac" diff --git a/dev-java/openj9-openjdk-bin/metadata.xml b/dev-java/openj9-openjdk-bin/metadata.xml index 4c0b1aa..532f0f1 100644 --- a/dev-java/openj9-openjdk-bin/metadata.xml +++ b/dev-java/openj9-openjdk-bin/metadata.xml @@ -8,7 +8,6 @@ </longdescription> <use> <flag name="headless-awt">Don't install the X backend for AWT, needed by some GUIs (used to be X flag)</flag> - <flag name="gentoo-vm">Allow this JDK to be recognised by Gentoo (package manager, eselect, java-config, EXPERIMENTAL!)</flag> <flag name="source">Install JVM sources</flag> </use> </pkgmetadata> diff --git a/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-11.0.12.7.0.27.0.ebuild b/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-11.0.12.7.0.27.0.ebuild deleted file mode 100644 index 2473ff0..0000000 --- a/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-11.0.12.7.0.27.0.ebuild +++ /dev/null @@ -1,117 +0,0 @@ -# Copyright 1999-2020 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=6 - -inherit java-vm-2 toolchain-funcs versionator - -abi_uri() { - echo "${2-$1}? ( - debug? ( - https://github.com/ibmruntimes/semeru${SLOT}-binaries/releases/download/jdk-${DL_PV/+/%2B}/ibm-semeru-open-debugimage_${1}_linux_${DL_PV/+/_}.tar.gz - ) - https://github.com/ibmruntimes/semeru${SLOT}-binaries/releases/download/jdk-${DL_PV/+/%2B}/ibm-semeru-open-jdk_${1}_linux_${DL_PV/+/_}.tar.gz - )" -} - -JDK_PV=$(get_version_component_range 1-3)+$(get_version_component_range 4) -DL_PV=${JDK_PV}_openj9-$(get_version_component_range 5-7) -SLOT=$(get_major_version) - -SRC_URI=" - $(abi_uri aarch64 arm64) - $(abi_uri ppc64le ppc64) - $(abi_uri s390x s390) - $(abi_uri x64 amd64) -" - -DESCRIPTION="Prebuilt IBM Semeru JDK binaries provided by IBM" -HOMEPAGE="https://developer.ibm.com/languages/java/semeru-runtimes/" -LICENSE="GPL-2-with-classpath-exception" -KEYWORDS="~amd64 ~arm64 ~ppc64 ~s390" -IUSE="alsa cups debug +gentoo-vm headless-awt selinux source" - -RDEPEND=" - media-libs/fontconfig:1.0 - media-libs/freetype:2 - >=sys-apps/baselayout-java-0.1.0-r1 - >=sys-libs/glibc-2.2.5:* - sys-libs/zlib - alsa? ( media-libs/alsa-lib ) - cups? ( net-print/cups ) - selinux? ( sec-policy/selinux-java ) - !headless-awt? ( - x11-libs/libX11 - x11-libs/libXext - x11-libs/libXi - x11-libs/libXrender - x11-libs/libXtst - )" - -RESTRICT="preserve-libs splitdebug" -QA_PREBUILT="*" - -S="${WORKDIR}/jdk-${JDK_PV}" - -pkg_pretend() { - if [[ "$(tc-is-softfloat)" != "no" ]]; then - die "These binaries require a hardfloat system." - fi -} - -do_rm() { - rm -v $1 || die - if use debug ; then - rm -v "${S}-debug-image"/$1 || die - fi -} - -src_install() { - local dest="/opt/${P}" - local ddest="${ED%/}/${dest#/}" - - # Oracle and IcedTea have libjsoundalsa.so depending on - # libasound.so.2 but AdoptOpenJDK only has libjsound.so. Weird. - if ! use alsa ; then - do_rm 'lib/libjsound.*' - fi - - if use headless-awt ; then - do_rm 'lib/lib*{[jx]awt,splashscreen}*' - fi - - if ! use source ; then - rm -v lib/src.zip || die - fi - - rm -v lib/security/cacerts || die - dosym ../../../../etc/ssl/certs/java/cacerts \ - "${dest}"/lib/security/cacerts - - dodir "${dest}" - cp -pPR * "${ddest}" || die - - # provide stable symlink - dosym "${P}" "/opt/${PN}-${SLOT}" - - use gentoo-vm && java-vm_install-env "${FILESDIR}"/${PN}.env.sh - java-vm_set-pax-markings "${ddest}" - java-vm_revdep-mask - java-vm_sandbox-predict /dev/random /proc/self/coredump_filter -} - -pkg_postinst() { - java-vm-2_pkg_postinst - - if use gentoo-vm ; then - ewarn "WARNING! You have enabled the gentoo-vm USE flag, making this JDK" - ewarn "recognised by the system. This will almost certainly break" - ewarn "many java ebuilds as they are not ready for openjdk-11" - else - ewarn "The experimental gentoo-vm USE flag has not been enabled so this JDK" - ewarn "will not be recognised by the system. For example, simply calling" - ewarn "\"java\" will launch a different JVM. This is necessary until Gentoo" - ewarn "fully supports Java 11. This JDK must therefore be invoked using its" - ewarn "absolute location under ${EPREFIX}/opt/${P}." - fi -} diff --git a/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-11.0.27_p6.ebuild b/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-11.0.27_p6.ebuild new file mode 100644 index 0000000..023e8ec --- /dev/null +++ b/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-11.0.27_p6.ebuild @@ -0,0 +1,117 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit java-vm-2 toolchain-funcs + +abi_uri() { + echo "${2-$1}? ( + debug? ( + https://github.com/ibmruntimes/semeru${SLOT}-binaries/releases/download/jdk-${DL_PV/+/%2B}/ibm-semeru-open-debugimage_${1}_linux_${DL_PV/+/_}.tar.gz + ) + https://github.com/ibmruntimes/semeru${SLOT}-binaries/releases/download/jdk-${DL_PV/+/%2B}/ibm-semeru-open-jdk_${1}_linux_${DL_PV/+/_}.tar.gz + )" +} + +JDK_PV=${PV//_p/+} +DL_PV=${JDK_PV}_openj9-0.51.0 +SLOT=$(ver_cut 1) + +SRC_URI=" + $(abi_uri aarch64 arm64) + $(abi_uri ppc64le ppc64) + $(abi_uri x64 amd64) +" + +DESCRIPTION="Prebuilt IBM Semeru JDK binaries provided by IBM" +HOMEPAGE="https://developer.ibm.com/languages/java/semeru-runtimes/" +LICENSE="GPL-2-with-classpath-exception" +KEYWORDS="~amd64 ~arm64 ~ppc64" +IUSE="alsa cups debug headless-awt selinux source" + +RDEPEND=" + >=sys-apps/baselayout-java-0.1.0-r1 + kernel_linux? ( + media-libs/fontconfig:1.0 + media-libs/freetype:2 + media-libs/harfbuzz + elibc_glibc? ( >=sys-libs/glibc-2.2.5:* ) + elibc_musl? ( sys-libs/musl ) + sys-libs/zlib + alsa? ( media-libs/alsa-lib ) + cups? ( net-print/cups ) + selinux? ( sec-policy/selinux-java ) + !headless-awt? ( + x11-libs/libX11 + x11-libs/libXext + x11-libs/libXi + x11-libs/libXrender + x11-libs/libXtst + ) + )" + +RESTRICT="preserve-libs splitdebug" +QA_PREBUILT="*" + +S="${WORKDIR}/jdk-${JDK_PV}" + +pkg_pretend() { + if [[ "$(tc-is-softfloat)" != "no" ]]; then + die "These binaries require a hardfloat system." + fi +} + +src_unpack() { + default + if [[ ${A} == *_mac_* ]] ; then + mv -v "${S}/Contents/Home/"* "${S}" || die + rm -Rf "${S}/Contents" # drop macOS executable + fi +} + +src_install() { + local dest="/opt/${P}" + local ddest="${ED}/${dest#/}" + + # on macOS if they would exist they would be called .dylib, but most + # importantly, there are no different providers, so everything + # that's shipped works. + if [[ ${A} != *_mac_* ]] ; then + # Not sure why they bundle this as it's commonly available and they + # only do so on x86_64. It's needed by libfontmanager.so. IcedTea + # also has an explicit dependency while Oracle seemingly dlopens it. + rm -vf lib/libfreetype.so || die + + # prefer system copy # https://bugs.gentoo.org/776676 + rm -vf lib/libharfbuzz.so || die + + # Oracle and IcedTea have libjsoundalsa.so depending on + # libasound.so.2 but AdoptOpenJDK only has libjsound.so. Weird. + if ! use alsa ; then + rm -v lib/libjsound.* || die + fi + + if use headless-awt ; then + rm -v lib/lib*{[jx]awt,splashscreen}* || die + fi + fi + + if ! use source ; then + rm -v lib/src.zip || die + fi + + rm -v lib/security/cacerts || die + dosym -r /etc/ssl/certs/java/cacerts "${dest}"/lib/security/cacerts + + dodir "${dest}" + cp -pPR * "${ddest}" || die + + # provide stable symlink + dosym "${P}" "/opt/${PN}-${SLOT}" + + java-vm_install-env "${FILESDIR}"/${PN}.env.sh + java-vm_set-pax-markings "${ddest}" + java-vm_revdep-mask + java-vm_sandbox-predict /dev/random /proc/self/coredump_filter +} diff --git a/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-16.0.2.7.0.27.0.ebuild b/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-16.0.2.7.0.27.0.ebuild deleted file mode 100644 index 2473ff0..0000000 --- a/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-16.0.2.7.0.27.0.ebuild +++ /dev/null @@ -1,117 +0,0 @@ -# Copyright 1999-2020 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=6 - -inherit java-vm-2 toolchain-funcs versionator - -abi_uri() { - echo "${2-$1}? ( - debug? ( - https://github.com/ibmruntimes/semeru${SLOT}-binaries/releases/download/jdk-${DL_PV/+/%2B}/ibm-semeru-open-debugimage_${1}_linux_${DL_PV/+/_}.tar.gz - ) - https://github.com/ibmruntimes/semeru${SLOT}-binaries/releases/download/jdk-${DL_PV/+/%2B}/ibm-semeru-open-jdk_${1}_linux_${DL_PV/+/_}.tar.gz - )" -} - -JDK_PV=$(get_version_component_range 1-3)+$(get_version_component_range 4) -DL_PV=${JDK_PV}_openj9-$(get_version_component_range 5-7) -SLOT=$(get_major_version) - -SRC_URI=" - $(abi_uri aarch64 arm64) - $(abi_uri ppc64le ppc64) - $(abi_uri s390x s390) - $(abi_uri x64 amd64) -" - -DESCRIPTION="Prebuilt IBM Semeru JDK binaries provided by IBM" -HOMEPAGE="https://developer.ibm.com/languages/java/semeru-runtimes/" -LICENSE="GPL-2-with-classpath-exception" -KEYWORDS="~amd64 ~arm64 ~ppc64 ~s390" -IUSE="alsa cups debug +gentoo-vm headless-awt selinux source" - -RDEPEND=" - media-libs/fontconfig:1.0 - media-libs/freetype:2 - >=sys-apps/baselayout-java-0.1.0-r1 - >=sys-libs/glibc-2.2.5:* - sys-libs/zlib - alsa? ( media-libs/alsa-lib ) - cups? ( net-print/cups ) - selinux? ( sec-policy/selinux-java ) - !headless-awt? ( - x11-libs/libX11 - x11-libs/libXext - x11-libs/libXi - x11-libs/libXrender - x11-libs/libXtst - )" - -RESTRICT="preserve-libs splitdebug" -QA_PREBUILT="*" - -S="${WORKDIR}/jdk-${JDK_PV}" - -pkg_pretend() { - if [[ "$(tc-is-softfloat)" != "no" ]]; then - die "These binaries require a hardfloat system." - fi -} - -do_rm() { - rm -v $1 || die - if use debug ; then - rm -v "${S}-debug-image"/$1 || die - fi -} - -src_install() { - local dest="/opt/${P}" - local ddest="${ED%/}/${dest#/}" - - # Oracle and IcedTea have libjsoundalsa.so depending on - # libasound.so.2 but AdoptOpenJDK only has libjsound.so. Weird. - if ! use alsa ; then - do_rm 'lib/libjsound.*' - fi - - if use headless-awt ; then - do_rm 'lib/lib*{[jx]awt,splashscreen}*' - fi - - if ! use source ; then - rm -v lib/src.zip || die - fi - - rm -v lib/security/cacerts || die - dosym ../../../../etc/ssl/certs/java/cacerts \ - "${dest}"/lib/security/cacerts - - dodir "${dest}" - cp -pPR * "${ddest}" || die - - # provide stable symlink - dosym "${P}" "/opt/${PN}-${SLOT}" - - use gentoo-vm && java-vm_install-env "${FILESDIR}"/${PN}.env.sh - java-vm_set-pax-markings "${ddest}" - java-vm_revdep-mask - java-vm_sandbox-predict /dev/random /proc/self/coredump_filter -} - -pkg_postinst() { - java-vm-2_pkg_postinst - - if use gentoo-vm ; then - ewarn "WARNING! You have enabled the gentoo-vm USE flag, making this JDK" - ewarn "recognised by the system. This will almost certainly break" - ewarn "many java ebuilds as they are not ready for openjdk-11" - else - ewarn "The experimental gentoo-vm USE flag has not been enabled so this JDK" - ewarn "will not be recognised by the system. For example, simply calling" - ewarn "\"java\" will launch a different JVM. This is necessary until Gentoo" - ewarn "fully supports Java 11. This JDK must therefore be invoked using its" - ewarn "absolute location under ${EPREFIX}/opt/${P}." - fi -} diff --git a/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-17.0.15_p6.ebuild b/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-17.0.15_p6.ebuild new file mode 100644 index 0000000..023e8ec --- /dev/null +++ b/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-17.0.15_p6.ebuild @@ -0,0 +1,117 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit java-vm-2 toolchain-funcs + +abi_uri() { + echo "${2-$1}? ( + debug? ( + https://github.com/ibmruntimes/semeru${SLOT}-binaries/releases/download/jdk-${DL_PV/+/%2B}/ibm-semeru-open-debugimage_${1}_linux_${DL_PV/+/_}.tar.gz + ) + https://github.com/ibmruntimes/semeru${SLOT}-binaries/releases/download/jdk-${DL_PV/+/%2B}/ibm-semeru-open-jdk_${1}_linux_${DL_PV/+/_}.tar.gz + )" +} + +JDK_PV=${PV//_p/+} +DL_PV=${JDK_PV}_openj9-0.51.0 +SLOT=$(ver_cut 1) + +SRC_URI=" + $(abi_uri aarch64 arm64) + $(abi_uri ppc64le ppc64) + $(abi_uri x64 amd64) +" + +DESCRIPTION="Prebuilt IBM Semeru JDK binaries provided by IBM" +HOMEPAGE="https://developer.ibm.com/languages/java/semeru-runtimes/" +LICENSE="GPL-2-with-classpath-exception" +KEYWORDS="~amd64 ~arm64 ~ppc64" +IUSE="alsa cups debug headless-awt selinux source" + +RDEPEND=" + >=sys-apps/baselayout-java-0.1.0-r1 + kernel_linux? ( + media-libs/fontconfig:1.0 + media-libs/freetype:2 + media-libs/harfbuzz + elibc_glibc? ( >=sys-libs/glibc-2.2.5:* ) + elibc_musl? ( sys-libs/musl ) + sys-libs/zlib + alsa? ( media-libs/alsa-lib ) + cups? ( net-print/cups ) + selinux? ( sec-policy/selinux-java ) + !headless-awt? ( + x11-libs/libX11 + x11-libs/libXext + x11-libs/libXi + x11-libs/libXrender + x11-libs/libXtst + ) + )" + +RESTRICT="preserve-libs splitdebug" +QA_PREBUILT="*" + +S="${WORKDIR}/jdk-${JDK_PV}" + +pkg_pretend() { + if [[ "$(tc-is-softfloat)" != "no" ]]; then + die "These binaries require a hardfloat system." + fi +} + +src_unpack() { + default + if [[ ${A} == *_mac_* ]] ; then + mv -v "${S}/Contents/Home/"* "${S}" || die + rm -Rf "${S}/Contents" # drop macOS executable + fi +} + +src_install() { + local dest="/opt/${P}" + local ddest="${ED}/${dest#/}" + + # on macOS if they would exist they would be called .dylib, but most + # importantly, there are no different providers, so everything + # that's shipped works. + if [[ ${A} != *_mac_* ]] ; then + # Not sure why they bundle this as it's commonly available and they + # only do so on x86_64. It's needed by libfontmanager.so. IcedTea + # also has an explicit dependency while Oracle seemingly dlopens it. + rm -vf lib/libfreetype.so || die + + # prefer system copy # https://bugs.gentoo.org/776676 + rm -vf lib/libharfbuzz.so || die + + # Oracle and IcedTea have libjsoundalsa.so depending on + # libasound.so.2 but AdoptOpenJDK only has libjsound.so. Weird. + if ! use alsa ; then + rm -v lib/libjsound.* || die + fi + + if use headless-awt ; then + rm -v lib/lib*{[jx]awt,splashscreen}* || die + fi + fi + + if ! use source ; then + rm -v lib/src.zip || die + fi + + rm -v lib/security/cacerts || die + dosym -r /etc/ssl/certs/java/cacerts "${dest}"/lib/security/cacerts + + dodir "${dest}" + cp -pPR * "${ddest}" || die + + # provide stable symlink + dosym "${P}" "/opt/${PN}-${SLOT}" + + java-vm_install-env "${FILESDIR}"/${PN}.env.sh + java-vm_set-pax-markings "${ddest}" + java-vm_revdep-mask + java-vm_sandbox-predict /dev/random /proc/self/coredump_filter +} diff --git a/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-21.0.7_p6.ebuild b/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-21.0.7_p6.ebuild new file mode 100644 index 0000000..023e8ec --- /dev/null +++ b/dev-java/openj9-openjdk-bin/openj9-openjdk-bin-21.0.7_p6.ebuild @@ -0,0 +1,117 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit java-vm-2 toolchain-funcs + +abi_uri() { + echo "${2-$1}? ( + debug? ( + https://github.com/ibmruntimes/semeru${SLOT}-binaries/releases/download/jdk-${DL_PV/+/%2B}/ibm-semeru-open-debugimage_${1}_linux_${DL_PV/+/_}.tar.gz + ) + https://github.com/ibmruntimes/semeru${SLOT}-binaries/releases/download/jdk-${DL_PV/+/%2B}/ibm-semeru-open-jdk_${1}_linux_${DL_PV/+/_}.tar.gz + )" +} + +JDK_PV=${PV//_p/+} +DL_PV=${JDK_PV}_openj9-0.51.0 +SLOT=$(ver_cut 1) + +SRC_URI=" + $(abi_uri aarch64 arm64) + $(abi_uri ppc64le ppc64) + $(abi_uri x64 amd64) +" + +DESCRIPTION="Prebuilt IBM Semeru JDK binaries provided by IBM" +HOMEPAGE="https://developer.ibm.com/languages/java/semeru-runtimes/" +LICENSE="GPL-2-with-classpath-exception" +KEYWORDS="~amd64 ~arm64 ~ppc64" +IUSE="alsa cups debug headless-awt selinux source" + +RDEPEND=" + >=sys-apps/baselayout-java-0.1.0-r1 + kernel_linux? ( + media-libs/fontconfig:1.0 + media-libs/freetype:2 + media-libs/harfbuzz + elibc_glibc? ( >=sys-libs/glibc-2.2.5:* ) + elibc_musl? ( sys-libs/musl ) + sys-libs/zlib + alsa? ( media-libs/alsa-lib ) + cups? ( net-print/cups ) + selinux? ( sec-policy/selinux-java ) + !headless-awt? ( + x11-libs/libX11 + x11-libs/libXext + x11-libs/libXi + x11-libs/libXrender + x11-libs/libXtst + ) + )" + +RESTRICT="preserve-libs splitdebug" +QA_PREBUILT="*" + +S="${WORKDIR}/jdk-${JDK_PV}" + +pkg_pretend() { + if [[ "$(tc-is-softfloat)" != "no" ]]; then + die "These binaries require a hardfloat system." + fi +} + +src_unpack() { + default + if [[ ${A} == *_mac_* ]] ; then + mv -v "${S}/Contents/Home/"* "${S}" || die + rm -Rf "${S}/Contents" # drop macOS executable + fi +} + +src_install() { + local dest="/opt/${P}" + local ddest="${ED}/${dest#/}" + + # on macOS if they would exist they would be called .dylib, but most + # importantly, there are no different providers, so everything + # that's shipped works. + if [[ ${A} != *_mac_* ]] ; then + # Not sure why they bundle this as it's commonly available and they + # only do so on x86_64. It's needed by libfontmanager.so. IcedTea + # also has an explicit dependency while Oracle seemingly dlopens it. + rm -vf lib/libfreetype.so || die + + # prefer system copy # https://bugs.gentoo.org/776676 + rm -vf lib/libharfbuzz.so || die + + # Oracle and IcedTea have libjsoundalsa.so depending on + # libasound.so.2 but AdoptOpenJDK only has libjsound.so. Weird. + if ! use alsa ; then + rm -v lib/libjsound.* || die + fi + + if use headless-awt ; then + rm -v lib/lib*{[jx]awt,splashscreen}* || die + fi + fi + + if ! use source ; then + rm -v lib/src.zip || die + fi + + rm -v lib/security/cacerts || die + dosym -r /etc/ssl/certs/java/cacerts "${dest}"/lib/security/cacerts + + dodir "${dest}" + cp -pPR * "${ddest}" || die + + # provide stable symlink + dosym "${P}" "/opt/${PN}-${SLOT}" + + java-vm_install-env "${FILESDIR}"/${PN}.env.sh + java-vm_set-pax-markings "${ddest}" + java-vm_revdep-mask + java-vm_sandbox-predict /dev/random /proc/self/coredump_filter +} diff --git a/dev-java/openj9-openjdk-jre-bin/Manifest b/dev-java/openj9-openjdk-jre-bin/Manifest index f037b57..d3babd8 100644 --- a/dev-java/openj9-openjdk-jre-bin/Manifest +++ b/dev-java/openj9-openjdk-jre-bin/Manifest @@ -1,8 +1,9 @@ -DIST ibm-semeru-open-jre_aarch64_linux_11.0.12_7_openj9-0.27.0.tar.gz 41737266 SHA256 06fa66b99d3c9ba07f117860ef653d52bcb19dac1ea598c15f3b4eec9f832b36 -DIST ibm-semeru-open-jre_aarch64_linux_16.0.2_7_openj9-0.27.0.tar.gz 41451784 SHA256 575dc3827077fc661fd1103effaa13ccd0f1606d01a33643956ed2eb1ece9763 -DIST ibm-semeru-open-jre_ppc64le_linux_11.0.12_7_openj9-0.27.0.tar.gz 44324701 SHA256 285bd388a497db61408d26a9f3328f62004714ede94456718cf6440a109e25d2 -DIST ibm-semeru-open-jre_ppc64le_linux_16.0.2_7_openj9-0.27.0.tar.gz 44063048 SHA256 51dac9a69b594c72adabb2c36634a121be04a17c4ce34628cf9b37fd5010c1a8 -DIST ibm-semeru-open-jre_s390x_linux_11.0.12_7_openj9-0.27.0.tar.gz 43083467 SHA256 6e5829aeb37abfb122e0944e438ecb2043c56df14fcdcce39bd4e3c9a55571a8 -DIST ibm-semeru-open-jre_s390x_linux_16.0.2_7_openj9-0.27.0.tar.gz 42822005 SHA256 dba28e3e06bb7c76b4da2f46c48ed74dc72e168f9ee01439decadea181eb402c -DIST ibm-semeru-open-jre_x64_linux_11.0.12_7_openj9-0.27.0.tar.gz 43580993 SHA256 f352998f6fdf0b84f63c563608be57f30aa3f14c8117c1219422dbc712ad4f81 -DIST ibm-semeru-open-jre_x64_linux_16.0.2_7_openj9-0.27.0.tar.gz 43282252 SHA256 b077cd0b35d3ed1927c22e5b498264ecff67297992809056187b42662edfc536 +DIST ibm-semeru-open-jre_aarch64_linux_11.0.27_6_openj9-0.51.0.tar.gz 47804344 SHA256 7aa093df03eb825d62a72a64a60e238e9fde2d36ed18f6e5418e07318ad155a2 +DIST ibm-semeru-open-jre_aarch64_linux_17.0.15_6_openj9-0.51.0.tar.gz 47146898 SHA256 9a44da58055525719ddb87b2fe21a02562a0897b8b537a65b7a94b1ab28f7eb0 +DIST ibm-semeru-open-jre_aarch64_linux_21.0.7_6_openj9-0.51.0.tar.gz 51681810 SHA256 8a140dc3806d8e0ae23ca37cff6b4cf225eea45bc82b0749c05ad5f05b9cff36 +DIST ibm-semeru-open-jre_ppc64le_linux_11.0.27_6_openj9-0.51.0.tar.gz 52978070 SHA256 81c7c9ee709939cc66d5122f096cd36a4d1630851d275881799746b8f9d050da +DIST ibm-semeru-open-jre_ppc64le_linux_17.0.15_6_openj9-0.51.0.tar.gz 52265472 SHA256 e852a334a4a3f59bd8478ffe3190bbdb520fa37d8954e17fc7842ede979b15fa +DIST ibm-semeru-open-jre_ppc64le_linux_21.0.7_6_openj9-0.51.0.tar.gz 56894775 SHA256 c3e5287710e9a30a905e82cd0bb67a114cec08fc4a03f82798e76d22a1a7137e +DIST ibm-semeru-open-jre_x64_linux_11.0.27_6_openj9-0.51.0.tar.gz 51392477 SHA256 73b79ace5c4e01cf5b0c002799185a5db4a601b3158c690cb204e3b618ad7b6e +DIST ibm-semeru-open-jre_x64_linux_17.0.15_6_openj9-0.51.0.tar.gz 50712179 SHA256 c4cc045bfd63fc6412251fef184c91a1acad76d74ee48561fd48c174fb1278d3 +DIST ibm-semeru-open-jre_x64_linux_21.0.7_6_openj9-0.51.0.tar.gz 55276782 SHA256 1c439bacc90f3a119edc3a7f313512b49b21d583a960cb318094974fe5006246 diff --git a/dev-java/openj9-openjdk-jre-bin/files/openj9-openjdk-jre-bin.env.sh b/dev-java/openj9-openjdk-jre-bin/files/openj9-openjdk-jre-bin.env.sh index 1ad9132..ba4b8a2 100644 --- a/dev-java/openj9-openjdk-jre-bin/files/openj9-openjdk-jre-bin.env.sh +++ b/dev-java/openj9-openjdk-jre-bin/files/openj9-openjdk-jre-bin.env.sh @@ -1,10 +1,5 @@ -# Copyright 1999-2019 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -VERSION="AdoptOpenJDK JRE ${DL_PV}" -JAVA_HOME="${EPREFIX}/opt/${P}" -JDK_HOME="${EPREFIX}/opt/${P}" -JAVAC="\${JAVA_HOME}/bin/javac" +VERSION="IBM Semeru JRE ${DL_PV}" +JAVA_HOME="${EPREFIX}/opt/${PN}-${SLOT}" PATH="\${JAVA_HOME}/bin" ROOTPATH="\${JAVA_HOME}/bin" LDPATH="\${JAVA_HOME}/lib/:\${JAVA_HOME}/lib/server/" @@ -13,4 +8,4 @@ PROVIDES_TYPE="JRE" PROVIDES_VERSION="${SLOT}" BOOTCLASSPATH="" GENERATION="2" -ENV_VARS="JAVA_HOME JDK_HOME JAVAC PATH ROOTPATH LDPATH MANPATH" +ENV_VARS="JAVA_HOME PATH ROOTPATH LDPATH MANPATH" diff --git a/dev-java/openj9-openjdk-jre-bin/metadata.xml b/dev-java/openj9-openjdk-jre-bin/metadata.xml index b21a054..96526d8 100644 --- a/dev-java/openj9-openjdk-jre-bin/metadata.xml +++ b/dev-java/openj9-openjdk-jre-bin/metadata.xml @@ -8,6 +8,5 @@ </longdescription> <use> <flag name="headless-awt">Don't install the X backend for AWT, needed by some GUIs (used to be X flag)</flag> - <flag name="gentoo-vm">Allow this JDK to be recognised by Gentoo (package manager, eselect, java-config, EXPERIMENTAL!)</flag> </use> </pkgmetadata> diff --git a/dev-java/openj9-openjdk-jre-bin/openj9-openjdk-jre-bin-11.0.12.7.0.27.0.ebuild b/dev-java/openj9-openjdk-jre-bin/openj9-openjdk-jre-bin-11.0.27_p6.ebuild index 206c839..3f1b111 100644 --- a/dev-java/openj9-openjdk-jre-bin/openj9-openjdk-jre-bin-11.0.12.7.0.27.0.ebuild +++ b/dev-java/openj9-openjdk-jre-bin/openj9-openjdk-jre-bin-11.0.27_p6.ebuild @@ -1,9 +1,9 @@ -# Copyright 1999-2020 Gentoo Authors +# Copyright 1999-2022 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=6 +EAPI=8 -inherit java-vm-2 toolchain-funcs versionator +inherit java-vm-2 abi_uri() { echo "${2-$1}? ( @@ -11,27 +11,25 @@ abi_uri() { )" } -JDK_PV=$(get_version_component_range 1-3)+$(get_version_component_range 4) -DL_PV=${JDK_PV}_openj9-$(get_version_component_range 5-7) -SLOT=$(get_major_version) +JDK_PV=${PV//_p/+} +DL_PV=${JDK_PV}_openj9-0.51.0 +SLOT=$(ver_cut 1) SRC_URI=" $(abi_uri aarch64 arm64) $(abi_uri ppc64le ppc64) - $(abi_uri s390x s390) $(abi_uri x64 amd64) " DESCRIPTION="Prebuilt IBM Semeru JRE binaries provided by IBM" -HOMEPAGE="https://adoptopenjdk.net" +HOMEPAGE="https://developer.ibm.com/languages/java/semeru-runtimes/" LICENSE="GPL-2-with-classpath-exception" -KEYWORDS="~amd64 ~arm64 ~ppc64 ~s390" -IUSE="alsa cups +gentoo-vm headless-awt selinux" +KEYWORDS="~amd64 ~arm64 ~ppc64" +IUSE="alsa cups headless-awt selinux" RDEPEND=" media-libs/fontconfig:1.0 media-libs/freetype:2 - >net-libs/libnet-1.1 >=sys-apps/baselayout-java-0.1.0-r1 >=sys-libs/glibc-2.2.5:* sys-libs/zlib @@ -52,8 +50,13 @@ QA_PREBUILT="*" S="${WORKDIR}/jdk-${JDK_PV}-jre" src_install() { - local dest="/opt/${P}" - local ddest="${ED%/}/${dest#/}" + local dest="/opt/${PN}-${SLOT}" + local ddest="${ED}/${dest#/}" + + # Not sure why they bundle this as it's commonly available and they + # only do so on x86_64. It's needed by libfontmanager.so. IcedTea + # also has an explicit dependency while Oracle seemingly dlopens it. + rm -vf lib/libfreetype.so || die # Oracle and IcedTea have libjsoundalsa.so depending on # libasound.so.2 but AdoptOpenJDK only has libjsound.so. Weird. @@ -66,15 +69,12 @@ src_install() { fi rm -v lib/security/cacerts || die - dosym ../../../../etc/ssl/certs/java/cacerts "${dest}"/lib/security/cacerts + dosym -r /etc/ssl/certs/java/cacerts "${dest}"/lib/security/cacerts dodir "${dest}" cp -pPR * "${ddest}" || die - # provide stable symlink - dosym "${P}" "/opt/${PN}-${SLOT}" - - use gentoo-vm && java-vm_install-env "${FILESDIR}"/${PN}.env.sh + java-vm_install-env "${FILESDIR}"/${PN}.env.sh java-vm_set-pax-markings "${ddest}" java-vm_revdep-mask java-vm_sandbox-predict /dev/random /proc/self/coredump_filter @@ -82,15 +82,4 @@ src_install() { pkg_postinst() { java-vm-2_pkg_postinst - - if use gentoo-vm ; then - ewarn "WARNING! You have enabled the gentoo-vm USE flag, making this JRE" - ewarn "recognised by the system. This will almost certainly break things." - else - ewarn "The experimental gentoo-vm USE flag has not been enabled so this JRE" - ewarn "will not be recognised by the system. For example, simply calling" - ewarn "\"java\" will launch a different JVM. This is necessary until Gentoo" - ewarn "fully supports Java 11. This JRE must therefore be invoked using its" - ewarn "absolute location under ${EPREFIX}/opt/${P}." - fi } diff --git a/dev-java/openj9-openjdk-jre-bin/openj9-openjdk-jre-bin-16.0.2.7.0.27.0.ebuild b/dev-java/openj9-openjdk-jre-bin/openj9-openjdk-jre-bin-17.0.15_p6.ebuild index 206c839..3f1b111 100644 --- a/dev-java/openj9-openjdk-jre-bin/openj9-openjdk-jre-bin-16.0.2.7.0.27.0.ebuild +++ b/dev-java/openj9-openjdk-jre-bin/openj9-openjdk-jre-bin-17.0.15_p6.ebuild @@ -1,9 +1,9 @@ -# Copyright 1999-2020 Gentoo Authors +# Copyright 1999-2022 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=6 +EAPI=8 -inherit java-vm-2 toolchain-funcs versionator +inherit java-vm-2 abi_uri() { echo "${2-$1}? ( @@ -11,27 +11,25 @@ abi_uri() { )" } -JDK_PV=$(get_version_component_range 1-3)+$(get_version_component_range 4) -DL_PV=${JDK_PV}_openj9-$(get_version_component_range 5-7) -SLOT=$(get_major_version) +JDK_PV=${PV//_p/+} +DL_PV=${JDK_PV}_openj9-0.51.0 +SLOT=$(ver_cut 1) SRC_URI=" $(abi_uri aarch64 arm64) $(abi_uri ppc64le ppc64) - $(abi_uri s390x s390) $(abi_uri x64 amd64) " DESCRIPTION="Prebuilt IBM Semeru JRE binaries provided by IBM" -HOMEPAGE="https://adoptopenjdk.net" +HOMEPAGE="https://developer.ibm.com/languages/java/semeru-runtimes/" LICENSE="GPL-2-with-classpath-exception" -KEYWORDS="~amd64 ~arm64 ~ppc64 ~s390" -IUSE="alsa cups +gentoo-vm headless-awt selinux" +KEYWORDS="~amd64 ~arm64 ~ppc64" +IUSE="alsa cups headless-awt selinux" RDEPEND=" media-libs/fontconfig:1.0 media-libs/freetype:2 - >net-libs/libnet-1.1 >=sys-apps/baselayout-java-0.1.0-r1 >=sys-libs/glibc-2.2.5:* sys-libs/zlib @@ -52,8 +50,13 @@ QA_PREBUILT="*" S="${WORKDIR}/jdk-${JDK_PV}-jre" src_install() { - local dest="/opt/${P}" - local ddest="${ED%/}/${dest#/}" + local dest="/opt/${PN}-${SLOT}" + local ddest="${ED}/${dest#/}" + + # Not sure why they bundle this as it's commonly available and they + # only do so on x86_64. It's needed by libfontmanager.so. IcedTea + # also has an explicit dependency while Oracle seemingly dlopens it. + rm -vf lib/libfreetype.so || die # Oracle and IcedTea have libjsoundalsa.so depending on # libasound.so.2 but AdoptOpenJDK only has libjsound.so. Weird. @@ -66,15 +69,12 @@ src_install() { fi rm -v lib/security/cacerts || die - dosym ../../../../etc/ssl/certs/java/cacerts "${dest}"/lib/security/cacerts + dosym -r /etc/ssl/certs/java/cacerts "${dest}"/lib/security/cacerts dodir "${dest}" cp -pPR * "${ddest}" || die - # provide stable symlink - dosym "${P}" "/opt/${PN}-${SLOT}" - - use gentoo-vm && java-vm_install-env "${FILESDIR}"/${PN}.env.sh + java-vm_install-env "${FILESDIR}"/${PN}.env.sh java-vm_set-pax-markings "${ddest}" java-vm_revdep-mask java-vm_sandbox-predict /dev/random /proc/self/coredump_filter @@ -82,15 +82,4 @@ src_install() { pkg_postinst() { java-vm-2_pkg_postinst - - if use gentoo-vm ; then - ewarn "WARNING! You have enabled the gentoo-vm USE flag, making this JRE" - ewarn "recognised by the system. This will almost certainly break things." - else - ewarn "The experimental gentoo-vm USE flag has not been enabled so this JRE" - ewarn "will not be recognised by the system. For example, simply calling" - ewarn "\"java\" will launch a different JVM. This is necessary until Gentoo" - ewarn "fully supports Java 11. This JRE must therefore be invoked using its" - ewarn "absolute location under ${EPREFIX}/opt/${P}." - fi } diff --git a/dev-java/openj9-openjdk-jre-bin/openj9-openjdk-jre-bin-21.0.7_p6.ebuild b/dev-java/openj9-openjdk-jre-bin/openj9-openjdk-jre-bin-21.0.7_p6.ebuild new file mode 100644 index 0000000..3f1b111 --- /dev/null +++ b/dev-java/openj9-openjdk-jre-bin/openj9-openjdk-jre-bin-21.0.7_p6.ebuild @@ -0,0 +1,85 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit java-vm-2 + +abi_uri() { + echo "${2-$1}? ( + https://github.com/ibmruntimes/semeru${SLOT}-binaries/releases/download/jdk-${DL_PV/+/%2B}/ibm-semeru-open-jre_${1}_linux_${DL_PV/+/_}.tar.gz + )" +} + +JDK_PV=${PV//_p/+} +DL_PV=${JDK_PV}_openj9-0.51.0 +SLOT=$(ver_cut 1) + +SRC_URI=" + $(abi_uri aarch64 arm64) + $(abi_uri ppc64le ppc64) + $(abi_uri x64 amd64) +" + +DESCRIPTION="Prebuilt IBM Semeru JRE binaries provided by IBM" +HOMEPAGE="https://developer.ibm.com/languages/java/semeru-runtimes/" +LICENSE="GPL-2-with-classpath-exception" +KEYWORDS="~amd64 ~arm64 ~ppc64" +IUSE="alsa cups headless-awt selinux" + +RDEPEND=" + media-libs/fontconfig:1.0 + media-libs/freetype:2 + >=sys-apps/baselayout-java-0.1.0-r1 + >=sys-libs/glibc-2.2.5:* + sys-libs/zlib + alsa? ( media-libs/alsa-lib ) + cups? ( net-print/cups ) + selinux? ( sec-policy/selinux-java ) + !headless-awt? ( + x11-libs/libX11 + x11-libs/libXext + x11-libs/libXi + x11-libs/libXrender + x11-libs/libXtst + )" + +RESTRICT="preserve-libs splitdebug" +QA_PREBUILT="*" + +S="${WORKDIR}/jdk-${JDK_PV}-jre" + +src_install() { + local dest="/opt/${PN}-${SLOT}" + local ddest="${ED}/${dest#/}" + + # Not sure why they bundle this as it's commonly available and they + # only do so on x86_64. It's needed by libfontmanager.so. IcedTea + # also has an explicit dependency while Oracle seemingly dlopens it. + rm -vf lib/libfreetype.so || die + + # Oracle and IcedTea have libjsoundalsa.so depending on + # libasound.so.2 but AdoptOpenJDK only has libjsound.so. Weird. + if ! use alsa ; then + rm -v lib/libjsound.* || die + fi + + if use headless-awt ; then + rm -v lib/lib*{[jx]awt,splashscreen}* || die + fi + + rm -v lib/security/cacerts || die + dosym -r /etc/ssl/certs/java/cacerts "${dest}"/lib/security/cacerts + + dodir "${dest}" + cp -pPR * "${ddest}" || die + + java-vm_install-env "${FILESDIR}"/${PN}.env.sh + java-vm_set-pax-markings "${ddest}" + java-vm_revdep-mask + java-vm_sandbox-predict /dev/random /proc/self/coredump_filter +} + +pkg_postinst() { + java-vm-2_pkg_postinst +} diff --git a/dev-java/openj9-openjdk/Manifest b/dev-java/openj9-openjdk/Manifest index 89d0bef..533a846 100644 --- a/dev-java/openj9-openjdk/Manifest +++ b/dev-java/openj9-openjdk/Manifest @@ -1,4 +1,4 @@ -DIST openj9-0.27.1.tar.gz 16668711 BLAKE2B 091047b3770d86b652042b49f419c4d4597bb13630b853223a909fa0a135b0252d280e9ba2f1735c9f1c02dceb33a997e7906464d83669cd20d7993766ac46fc SHA512 1ba28787cf92eafb0e789ecac33b0f772bea6d4856f6120befe9c1928a8dcac04569808b053209fafa09a097c32fd3eed2c6c7137250a4e8b6cb96d37e4eec4e -DIST openj9-omr-0.27.1.tar.gz 7815053 BLAKE2B 97d4481dbcd8643e95e2ff50b873f1018c297dff0140207c3352ba5c5395092d21a1b2abcb5796f4d96daf4635f3a86cf76fab8376457fca7f8d1f4692ff9b03 SHA512 980d13ad900aec0d644058f3738f53b29467f4fbda03a2094ccceaa34955e79165002dc2d441af0fe878b523f62b15d315375dea2d5fa57942b5d1509e7afbbd -DIST openj9-openjdk-jdk11-openj9-0.27.1.tar.gz 108889106 BLAKE2B 32260d462fd1daab077cd72f5bd16ae793309d1efa930dcc5cbb2c56b1fc33194f93a4aaef904b23c9a6d16b0206042fbd3a1bc812005e2d115a3f5564849b6f SHA512 a33d0382c4a13cc608341715214c52ef3a81d8476291c078f6a808ebd0674b5f6153645fbd61ec818298e8e82d962b92107b73be67d3ab2610bbbae06804c28b -DIST openj9-openjdk-jdk16-openj9-0.27.1.tar.gz 90946973 BLAKE2B 6e06d96e74b8201fbec23eca14329b13f2a828a0abc6b29658a0b84af927f04142d2f9fd7810e93a00ab6d99e8bc71d38c21fc4bc26eb334166d596567b0f51b SHA512 c170ded18e3f1a41b3cc83d8d16202b4debdcd3d2fa4fbca7ce2c78be1d3d3fa8bc0d466b0a280b7c63a1161e3f50ece3b468096876a61e0cdb999d402895e06 +DIST openj9-0.48.0.tar.gz 18480709 BLAKE2B 4d3d593ce295c0ba40ef32cc79f0e00b4864d2bc5d36e26c0bd0e2c3aa3406888e8a764472c212ff45ab59d092055e9e9775231fd8d979643d91d022911bd147 SHA512 28247eb763056becf881f1a3f431a073f4605d062e26bfc30a8cad86cab7b7a9a114a44faff40743957315d808a42ff7636554ff794dac640578ec75e9328749 +DIST openj9-omr-0.48.0.tar.gz 8126272 BLAKE2B d343b0129d639cd2887c98fe64b92c66ff2932537520158faa2dbaa465cfb32d6ff0c5c7bf0a5591a8f57e25f85cfc1a85f34c7f6bd9f07e04a35d5b50eb09f7 SHA512 090aee202bb7dd46fcc93f94a7168d22f3b2546d86456d40ba12aba7d76699345502aafc25ca5b675ba7683cfa2414564113c91ba31ad720d1f6867d63f70aab +DIST openj9-openjdk-jdk11-openj9-0.48.0.tar.gz 102800187 BLAKE2B 82a04892e389a5e24c59a17d2efa95a37e092480dfbbf89f47da965179aaead0b56c1cbe26efcd905bfeb018667880faf077e410bf0d689a1b99178acf398fb4 SHA512 9288f83706aeb945a479b4478b365911408a92ac703f43418f3f98fc1beaefb008c8d0b46dd055200122a9d549da89cd727a2eef8598b7ba069cf36055d1207d +DIST openj9-openjdk-jdk21-openj9-0.48.0.tar.gz 100484633 BLAKE2B c23d1325c8db43a7076cc589ea0a485cae2d0d26668f8da5cb2a2db2cc6b43052a7e848d04e7c66f03f7696a19690a0812f9aff92deedf7c426ede03b9aa36c7 SHA512 5b4a390c53643ee10affd5b0c6277f5ac6be873f34035c28fb7b75fca04f9e08e91b66ed505e8a5c0eb114f0cf00d6af2bb8c42f2495e3b6913cc253a7969836 diff --git a/dev-java/openj9-openjdk/files/omr-fam.patch b/dev-java/openj9-openjdk/files/omr-fam.patch deleted file mode 100644 index 9141ec1..0000000 --- a/dev-java/openj9-openjdk/files/omr-fam.patch +++ /dev/null @@ -1,70 +0,0 @@ -diff --git a/ddr/tools/blob_reader/blob_reader.cpp b/ddr/tools/blob_reader/blob_reader.cpp -index 028decd0c..a0212609f 100644 ---- a/ddr/tools/blob_reader/blob_reader.cpp -+++ b/ddr/tools/blob_reader/blob_reader.cpp -@@ -85,7 +85,7 @@ struct BlobHeaderV1 { - - struct BlobString { - uint16_t length; -- char data[1]; /* flexible array member */ -+ char data[]; - - void endian_swap() - { -diff --git a/include_core/ute_core.h b/include_core/ute_core.h -index 8b3b1c65d..330ea52c6 100644 ---- a/include_core/ute_core.h -+++ b/include_core/ute_core.h -@@ -125,7 +125,7 @@ typedef struct UtTraceRecord { - uint64_t threadSyn2; /* Thread synonym 2 */ - int32_t firstEntry; /* Offset to first trace entry */ - int32_t nextEntry; /* Offset to next entry */ -- char threadName[1]; /* Thread name */ -+ char threadName[]; /* Thread name */ - } UtTraceRecord; - - /* -diff --git a/include_core/ute_dataformat.h b/include_core/ute_dataformat.h -index 71d9e36ad..8a9dcb487 100644 ---- a/include_core/ute_dataformat.h -+++ b/include_core/ute_dataformat.h -@@ -180,7 +180,7 @@ typedef struct UtProcSection { - #define UT_TRACE_ACTIVE_SECTION_NAME "UTTA" - typedef struct UtActiveSection { - UtDataHeader header; /* Eyecatcher, version etc */ -- char active[1]; /* Trace activation commands */ -+ char active[]; /* Trace activation commands */ - } UtActiveSection; - - /* -@@ -191,7 +191,7 @@ typedef struct UtActiveSection { - #define UT_TRACE_SERVICE_SECTION_NAME "UTSS" - typedef struct UtServiceSection { - UtDataHeader header; /* Eyecatcher, version etc */ -- char level[1]; /* Service level info */ -+ char level[]; /* Service level info */ - } UtServiceSection; - - /* -@@ -202,7 +202,7 @@ typedef struct UtServiceSection { - #define UT_TRACE_STARTUP_SECTION_NAME "UTSO" - typedef struct UtStartupSection { - UtDataHeader header; /* Eyecatcher, version etc */ -- char options[1]; /* Startup options */ -+ char options[]; /* Startup options */ - } UtStartupSection; - - /* -diff --git a/omrtrace/omrtrace_internal.h b/omrtrace/omrtrace_internal.h -index e52347eac..a68a88abd 100644 ---- a/omrtrace/omrtrace_internal.h -+++ b/omrtrace/omrtrace_internal.h -@@ -157,7 +157,7 @@ typedef struct OMR_TraceGlobal OMR_TraceGlobal; - typedef struct UtTraceCfg { - UtDataHeader header; - struct UtTraceCfg *next; /* Next trace config command */ -- char command[1]; /* Start of variable length section */ -+ char command[]; /* Start of variable length section */ - } UtTraceCfg; - - typedef struct UtDeferredConfigInfo { diff --git a/dev-java/openj9-openjdk/files/openj9-no-o3.patch b/dev-java/openj9-openjdk/files/openj9-no-o3.patch index 63d1dcf..b332052 100644 --- a/dev-java/openj9-openjdk/files/openj9-no-o3.patch +++ b/dev-java/openj9-openjdk/files/openj9-no-o3.patch @@ -1,11 +1,10 @@ -diff -ru a/runtime/cmake/platform/toolcfg/gnu.cmake b/runtime/cmake/platform/toolcfg/gnu.cmake ---- a/runtime/cmake/platform/toolcfg/gnu.cmake 2021-07-20 17:24:52.000000000 -0400 -+++ b/runtime/cmake/platform/toolcfg/gnu.cmake 2021-08-07 09:46:15.685325927 -0400 +--- a/runtime/cmake/platform/toolcfg/gnu.cmake ++++ b/runtime/cmake/platform/toolcfg/gnu.cmake @@ -20,7 +20,6 @@ # SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 OR LicenseRef-GPL-2.0 WITH Assembly-exception ################################################################################ -list(APPEND OMR_PLATFORM_COMPILE_OPTIONS -O3 -g -fstack-protector) - list(APPEND OMR_PLATFORM_C_COMPILE_OPTIONS -Wimplicit -Wreturn-type) - list(APPEND OMR_PLATFORM_CXX_COMPILE_OPTIONS -fno-threadsafe-statics) - + if(OMR_DDR AND NOT (CMAKE_C_COMPILER_VERSION VERSION_LESS 11)) + # In gcc 11+ the default is to use DWARF version 5 which is not yet + # supported by ddrgen: tell the compiler to use DWARF version 4. diff --git a/dev-java/openj9-openjdk/files/openj9-openjdk-override-version.patch b/dev-java/openj9-openjdk/files/openj9-openjdk-override-version.patch new file mode 100644 index 0000000..1652627 --- /dev/null +++ b/dev-java/openj9-openjdk/files/openj9-openjdk-override-version.patch @@ -0,0 +1,11 @@ +--- a/closed/OpenJ9.gmk ++++ b/closed/OpenJ9.gmk +@@ -44,7 +44,7 @@ + # $4 - 'required' for a required repository, anything else for an optional one + GetVersion = $(eval $(call GetVersionHelper,$(strip $1),$(strip $2),$(strip $3),$(strip $4))) + define GetVersionHelper +- $2 := $$(if $(wildcard $3),$$(shell $(GIT) -C $3 rev-parse --short HEAD)) ++ $2 := $$(if $$($2),$$($2),$$(if $(wildcard $3),$$(shell $(GIT) -C $3 rev-parse --short HEAD))) + ifneq (,$$($2)) + VersionLabelWidth := $(shell $(ECHO) "$1" | $(AWK) "{ width = length; print (width > $(VersionLabelWidth) ? width : $(VersionLabelWidth)) }") + VersionPairs += "$1" "$$($2)" diff --git a/dev-java/openj9-openjdk/files/openj9-openjdk.env.sh b/dev-java/openj9-openjdk/files/openj9-openjdk.env.sh index 5aac9c7..8d0d130 100644 --- a/dev-java/openj9-openjdk/files/openj9-openjdk.env.sh +++ b/dev-java/openj9-openjdk/files/openj9-openjdk.env.sh @@ -1,6 +1,3 @@ -# Copyright 1999-2018 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - VERSION="OpenJDK ${SLOT} with OpenJ9 ${OPENJ9_PV}" JAVA_HOME="${EPREFIX}/usr/$(get_libdir)/${PN}-${SLOT}" JDK_HOME="${EPREFIX}/usr/$(get_libdir)/${PN}-${SLOT}" diff --git a/dev-java/openj9-openjdk/metadata.xml b/dev-java/openj9-openjdk/metadata.xml index 50669cc..dadf469 100644 --- a/dev-java/openj9-openjdk/metadata.xml +++ b/dev-java/openj9-openjdk/metadata.xml @@ -1,19 +1,17 @@ <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> <pkgmetadata> - <longdescription> - Java™ is the world's leading programming language and platform. - The code for Java is open source and available at OpenJDK™. - </longdescription> - <slots> - <slot name="11">Java™ version 11</slot> - </slots> + <maintainer type="person"> + <email>alex_y_xu@yahoo.ca</email> + <name>Alex Xu (Hello71)</name> + </maintainer> <use> <flag name="ddr">Enable Direct Dump Reader</flag> <flag name="headless-awt">Don't install the X backend for AWT, needed by some GUIs</flag> - <flag name="gentoo-vm">Allow this JDK to be recognised by Gentoo (package manager, eselect, java-config, EXPERIMENTAL!)</flag> <flag name="javafx">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="jitserver">OpenJ9 JITServer support</flag> + <flag name="numa">Enable NUMA support using sys-process/numactl (NUMA kernel support is also required)</flag> <flag name="systemtap">Enable SystemTAP/DTrace tracing</flag> </use> </pkgmetadata> diff --git a/dev-java/openj9-openjdk/openj9-openjdk-16.0.27.1.ebuild b/dev-java/openj9-openjdk/openj9-openjdk-11.0.48.0.ebuild index 12447f2..4e7eb58 100644 --- a/dev-java/openj9-openjdk/openj9-openjdk-16.0.27.1.ebuild +++ b/dev-java/openj9-openjdk/openj9-openjdk-11.0.48.0.ebuild @@ -1,17 +1,16 @@ -# Copyright 1999-2020 Gentoo Authors +# Copyright 1999-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=6 +EAPI=8 -inherit autotools check-reqs flag-o-matic java-pkg-2 java-vm-2 multiprocessing pax-utils toolchain-funcs versionator +inherit check-reqs flag-o-matic java-pkg-2 java-vm-2 multiprocessing toolchain-funcs -SLOT="$(get_major_version)" -OPENJ9_PV="$(get_version_component_range 2-4)" +SLOT="$(ver_cut 1)" +OPENJ9_PV="$(ver_cut 2-4)" OPENJ9_P=openj9-${OPENJ9_PV} -FREEMARKER_PV=2.3.30 -DESCRIPTION="Open source implementation of the Java programming language" -HOMEPAGE="https://openjdk.java.net" +DESCRIPTION="Extensions for OpenJDK for Eclipse OpenJ9" +HOMEPAGE="https://www.eclipse.org/openj9/" if [[ ${OPENJ9_PV} == 9999 ]]; then inherit git-r3 EGIT_REPO_URI="https://github.com/ibmruntimes/openj9-openjdk-jdk${SLOT}.git" @@ -19,16 +18,20 @@ if [[ ${OPENJ9_PV} == 9999 ]]; then OPENJ9_OMR_EGIT_REPO_URI="https://github.com/eclipse/openj9-omr.git" else SRC_URI=" - https://github.com/ibmruntimes/openj9-openjdk-jdk${SLOT}/archive/v${OPENJ9_PV}-release.tar.gz -> openj9-openjdk-jdk${SLOT}-${OPENJ9_P}.tar.gz - https://github.com/eclipse/openj9/archive/${OPENJ9_P}.tar.gz -> ${OPENJ9_P}.tar.gz + https://github.com/ibmruntimes/openj9-openjdk-jdk${SLOT}/archive/${OPENJ9_P}.tar.gz -> openj9-openjdk-jdk${SLOT}-${OPENJ9_P}.tar.gz + https://github.com/eclipse/openj9/archive/${OPENJ9_P}.tar.gz https://github.com/eclipse/openj9-omr/archive/${OPENJ9_P}.tar.gz -> openj9-omr-${OPENJ9_PV}.tar.gz " fi -LICENSE="GPL-2" +LICENSE="GPL-2-with-classpath-exception" KEYWORDS="~amd64" -IUSE="alsa cups ddr debug doc examples gentoo-vm headless-awt javafx +jbootstrap +pch selinux source systemtap" +IUSE="alsa cups ddr debug doc headless-awt javafx +jbootstrap jitserver numa selinux source systemtap" + +REQUIRED_USE=" + javafx? ( alsa !headless-awt ) +" COMMON_DEPEND=" media-libs/freetype:2= @@ -37,12 +40,12 @@ COMMON_DEPEND=" media-libs/libpng:0= media-libs/lcms:2= sys-libs/zlib - virtual/jpeg:0= - systemtap? ( dev-util/systemtap ) + media-libs/libjpeg-turbo:0= + systemtap? ( dev-debug/systemtap ) dev-libs/elfutils - dev-libs/libdwarf - sys-process/numactl + ddr? ( dev-libs/libdwarf ) + numa? ( sys-process/numactl ) " # Many libs are required to build, but not to run, make is possible to remove @@ -80,18 +83,14 @@ DEPEND=" x11-libs/libXtst javafx? ( dev-java/openjfx:${SLOT}= ) || ( - virtual/jdk:${SLOT} - virtual/jdk:$((SLOT-1)) + dev-java/openj9-openjdk-bin:${SLOT} + dev-java/openj9-openjdk:${SLOT} + dev-java/openjdk-bin:${SLOT} + dev-java/openjdk:${SLOT} ) " -REQUIRED_USE="javafx? ( alsa !headless-awt )" - -if [[ ${OPENJ9_PV} == 9999 ]]; then - S="${WORKDIR}/openj9-openjdk-jdk${SLOT}" -else - S="${WORKDIR}/openj9-openjdk-jdk${SLOT}-${OPENJ9_PV}-release" -fi +S="${WORKDIR}/${PN}-jdk${SLOT}-${OPENJ9_P}" # The space required to build varies wildly depending on USE flags, # ranging from 3GB to 16GB. This function is certainly not exact but @@ -110,13 +109,23 @@ pkg_pretend() { openjdk_check_requirements if [[ ${MERGE_TYPE} != binary ]]; then has ccache ${FEATURES} && die "FEATURES=ccache doesn't work with ${PN}, bug #677876" - [[ $(gcc-major-version) == 11 ]] && die "gcc 11 hangs when optimizing exploded image" + + if use jitserver && tc-is-clang; then + die "jitserver does not compile with clang" + fi fi } pkg_setup() { openjdk_check_requirements java-vm-2_pkg_setup + + [[ ${MERGE_TYPE} == "binary" ]] && return + + JAVA_PKG_WANT_BUILD_VM="openj9-openjdk-${SLOT} openj9-openjdk-bin-${SLOT} openjdk-${SLOT} openjdk-bin-${SLOT}" + JAVA_PKG_WANT_SOURCE="${SLOT}" + JAVA_PKG_WANT_TARGET="${SLOT}" + java-pkg-2_pkg_setup } @@ -142,31 +151,37 @@ src_prepare() { default + eapply -- "${FILESDIR}/openj9-openjdk-override-version.patch" eapply -d openj9 -- "${FILESDIR}/openj9-no-o3.patch" eapply -d omr -- "${FILESDIR}/omr-omrstr-iconv-failure-overflow.patch" - eapply -d omr -- "${FILESDIR}/omr-fam.patch" - if [[ ${OPENJ9_PV} != 9999 ]]; then - sed -i -e '/^OPENJDK_SHA :=/s/:=.*/:= __OPENJDK_SHA__/' \ - -e '/^OPENJ9_SHA :=/s/:=.*/:= '${OPENJ9_P}/ \ - -e '/^OPENJ9_TAG :=/s/:=.*/:= '${OPENJ9_P}/ \ - -e '/^OPENJ9OMR_SHA :=/s/:=.*/:= '${OPENJ9_P}/ \ - closed/OpenJ9.gmk - fi + find openj9/ omr/ -name CMakeLists.txt -exec sed -i -e '/set(OMR_WARNINGS_AS_ERRORS ON/s/ON/OFF/' {} + || die + sed -i -e '/^ OPENJ9_CONFIGURE_NUMA$/d' closed/autoconf/custom-hook.m4 || die chmod +x configure || die } src_configure() { - # Work around stack alignment issue, bug #647954. in case we ever have x86 + # Work around stack alignment issue, bug #647954. use x86 && append-flags -mincoming-stack-boundary=2 + # Strip some flags users may set, but should not. #818502 + filter-flags -fexceptions + + # Strip lto related flags, we rely on USE=lto and --with-jvm-features=link-time-opt + # https://bugs.gentoo.org/833097 + # https://bugs.gentoo.org/833098 + filter-lto + filter-flags -fdevirtualize-at-ltrans + # Enabling full docs appears to break doc building. If not # explicitly disabled, the flag will get auto-enabled if pandoc and # graphviz are detected. pandoc has loads of dependencies anyway. local myconf=( --disable-ccache + --disable-precompiled-headers + --disable-warnings-as-errors{,-omr,-openj9} --enable-full-docs=no --with-boot-jdk="${JDK_HOME}" --with-extra-cflags="${CFLAGS}" @@ -186,19 +201,25 @@ src_configure() { --with-vendor-vm-bug-url="https://bugs.openjdk.java.net" --with-vendor-version-string="${PVR}" --with-version-pre="" - --with-version-opt="" --with-zlib=system --enable-dtrace=$(usex systemtap yes no) --enable-headless-only=$(usex headless-awt yes no) $(tc-is-clang && echo "--with-toolchain-type=clang") - --disable-warnings-as-errors{,-omr,-openj9} --with-cmake $(use_enable ddr) + $(use_enable jitserver) ) + use lto && myconf+=( --with-jvm-features=link-time-opt ) + if use javafx; then - local zip="${EPREFIX%/}/usr/$(get_libdir)/openjfx-${SLOT}/javafx-exports.zip" + # this is not useful for users, just for upstream developers + # build system compares mesa version in md file + # https://bugs.gentoo.org/822612 + export LEGAL_EXCLUDES=mesa3d.md + + local zip="${EPREFIX}/usr/$(get_libdir)/openjfx-${SLOT}/javafx-exports.zip" if [[ -r ${zip} ]]; then myconf+=( --with-import-modules="${zip}" ) else @@ -206,13 +227,6 @@ src_configure() { fi fi - # PaX breaks pch, bug #601016 - if use pch && ! host-is-pax; then - myconf+=( --enable-precompiled-headers ) - else - myconf+=( --disable-precompiled-headers ) - fi - ( unset _JAVA_OPTIONS JAVA JAVA_TOOL_OPTIONS JAVAC XARGS CFLAGS= CXXFLAGS= LDFLAGS= \ @@ -222,21 +236,37 @@ src_configure() { } src_compile() { + # Too brittle - gets confused by e.g. -Oline + export MAKEOPTS="-j$(makeopts_jobs) -l$(makeopts_loadavg)" + unset GNUMAKEFLAGS MAKEFLAGS + + local mycmakeargsx=( + "-DCMAKE_C_FLAGS='${CFLAGS}'" + "-DJ9JIT_EXTRA_CFLAGS='${CFLAGS}'" + "-DCMAKE_CXX_FLAGS='${CXXFLAGS}'" + "-DJ9JIT_EXTRA_CXXFLAGS='${CXXFLAGS}'" + "-DCMAKE_EXE_LINKER_FLAGS='${LDFLAGS}'" + -DOMR_WARNINGS_AS_ERRORS=OFF + -DOMR_PORT_NUMA_SUPPORT=$(usex numa) + ) local myemakeargs=( JOBS=$(makeopts_jobs) - # https://github.com/ibmruntimes/openj9-openjdk-jdk14/issues/72 - #LOG=debug + LOG=debug $(usex doc docs '') $(usex jbootstrap bootcycle-images product-images) - EXTRA_CMAKE_ARGS="-DOMR_WARNINGS_AS_ERRORS=OFF" + EXTRA_CMAKE_ARGS="${mycmakeargsx[*]}" + OPENJDK_SHA=$(ver_cut 1-3) + OPENJ9_SHA=${OPENJ9_P} + OPENJ9_TAG=${OPENJ9_P} + OPENJ9OMR_SHA=${OPENJ9_P} ) emake "${myemakeargs[@]}" -j1 #nowarn } src_install() { local dest="/usr/$(get_libdir)/${PN}-${SLOT}" - local ddest="${ED}${dest#/}" + local ddest="${ED}/${dest#/}" cd "${S}"/build/*-release/images/jdk || die @@ -251,10 +281,6 @@ src_install() { rm -v lib/libjsound.* || die fi - if ! use examples ; then - rm -vr demo/ || die - fi - if ! use source ; then rm -v lib/src.zip || die fi @@ -264,34 +290,22 @@ src_install() { dodir "${dest}" cp -pPR * "${ddest}" || die - dosym ../../../../../etc/ssl/certs/java/cacerts "${dest}"/lib/security/cacerts + dosym8 -r /etc/ssl/certs/java/cacerts "${dest}"/lib/security/cacerts # must be done before running itself java-vm_set-pax-markings "${ddest}" - use gentoo-vm && java-vm_install-env "${FILESDIR}"/${PN}.env.sh + java-vm_install-env "${FILESDIR}"/${PN}.env.sh java-vm_revdep-mask java-vm_sandbox-predict /dev/random /proc/self/coredump_filter if use doc ; then docinto html dodoc -r "${S}"/build/*-release/images/docs/* - dosym ../../../usr/share/doc/"${PF}" /usr/share/doc/"${PN}-${SLOT}" + dosym -r /usr/share/doc/"${PF}" /usr/share/doc/"${PN}-${SLOT}" fi } pkg_postinst() { java-vm-2_pkg_postinst - - if use gentoo-vm ; then - ewarn "WARNING! You have enabled the gentoo-vm USE flag, making this JDK" - ewarn "recognised by the system. This will almost certainly break" - ewarn "many java ebuilds as they are not ready for openjdk-11" - else - ewarn "The experimental gentoo-vm USE flag has not been enabled so this JDK" - ewarn "will not be recognised by the system. For example, simply calling" - ewarn "\"java\" will launch a different JVM. This is necessary until Gentoo" - ewarn "fully supports Java ${SLOT}. This JDK must therefore be invoked using its" - ewarn "absolute location under ${EPREFIX}/usr/$(get_libdir)/${PN}-${SLOT}." - fi } diff --git a/dev-java/openj9-openjdk/openj9-openjdk-11.0.27.1.ebuild b/dev-java/openj9-openjdk/openj9-openjdk-21.0.48.0.ebuild index c9285f0..6bf8ca9 100644 --- a/dev-java/openj9-openjdk/openj9-openjdk-11.0.27.1.ebuild +++ b/dev-java/openj9-openjdk/openj9-openjdk-21.0.48.0.ebuild @@ -1,17 +1,16 @@ -# Copyright 1999-2020 Gentoo Authors +# Copyright 1999-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=6 +EAPI=8 -inherit autotools check-reqs flag-o-matic java-pkg-2 java-vm-2 multiprocessing pax-utils toolchain-funcs versionator +inherit check-reqs flag-o-matic java-pkg-2 java-vm-2 multiprocessing toolchain-funcs -SLOT="$(get_major_version)" -OPENJ9_PV="$(get_version_component_range 2-4)" +SLOT="$(ver_cut 1)" +OPENJ9_PV="$(ver_cut 2-4)" OPENJ9_P=openj9-${OPENJ9_PV} -FREEMARKER_PV=2.3.30 -DESCRIPTION="Open source implementation of the Java programming language" -HOMEPAGE="https://openjdk.java.net" +DESCRIPTION="Extensions for OpenJDK for Eclipse OpenJ9" +HOMEPAGE="https://www.eclipse.org/openj9/" if [[ ${OPENJ9_PV} == 9999 ]]; then inherit git-r3 EGIT_REPO_URI="https://github.com/ibmruntimes/openj9-openjdk-jdk${SLOT}.git" @@ -19,16 +18,20 @@ if [[ ${OPENJ9_PV} == 9999 ]]; then OPENJ9_OMR_EGIT_REPO_URI="https://github.com/eclipse/openj9-omr.git" else SRC_URI=" - https://github.com/ibmruntimes/openj9-openjdk-jdk${SLOT}/archive/v${OPENJ9_PV}-release.tar.gz -> openj9-openjdk-jdk${SLOT}-${OPENJ9_P}.tar.gz + https://github.com/ibmruntimes/openj9-openjdk-jdk${SLOT}/archive/${OPENJ9_P}.tar.gz -> openj9-openjdk-jdk${SLOT}-${OPENJ9_P}.tar.gz https://github.com/eclipse/openj9/archive/${OPENJ9_P}.tar.gz https://github.com/eclipse/openj9-omr/archive/${OPENJ9_P}.tar.gz -> openj9-omr-${OPENJ9_PV}.tar.gz " fi -LICENSE="GPL-2" +LICENSE="GPL-2-with-classpath-exception" KEYWORDS="~amd64" -IUSE="alsa cups ddr debug doc examples gentoo-vm headless-awt javafx +jbootstrap +pch selinux source systemtap" +IUSE="alsa cups ddr debug doc headless-awt javafx +jbootstrap jitserver lto numa selinux source systemtap" + +REQUIRED_USE=" + javafx? ( alsa !headless-awt ) +" COMMON_DEPEND=" media-libs/freetype:2= @@ -37,12 +40,12 @@ COMMON_DEPEND=" media-libs/libpng:0= media-libs/lcms:2= sys-libs/zlib - virtual/jpeg:0= - systemtap? ( dev-util/systemtap ) + media-libs/libjpeg-turbo:0= + systemtap? ( dev-debug/systemtap ) dev-libs/elfutils - dev-libs/libdwarf - sys-process/numactl + ddr? ( dev-libs/libdwarf ) + numa? ( sys-process/numactl ) " # Many libs are required to build, but not to run, make is possible to remove @@ -80,7 +83,6 @@ DEPEND=" x11-libs/libXtst javafx? ( dev-java/openjfx:${SLOT}= ) || ( - virtual/jdk:${SLOT} dev-java/openj9-openjdk-bin:${SLOT} dev-java/openj9-openjdk:${SLOT} dev-java/openjdk-bin:${SLOT} @@ -88,13 +90,7 @@ DEPEND=" ) " -REQUIRED_USE="javafx? ( alsa !headless-awt )" - -if [[ ${OPENJ9_PV} == 9999 ]]; then - S="${WORKDIR}/openj9-openjdk-jdk${SLOT}" -else - S="${WORKDIR}/openj9-openjdk-jdk${SLOT}-${OPENJ9_P}" -fi +S="${WORKDIR}/${PN}-jdk${SLOT}-${OPENJ9_P}" # The space required to build varies wildly depending on USE flags, # ranging from 3GB to 16GB. This function is certainly not exact but @@ -113,7 +109,10 @@ pkg_pretend() { openjdk_check_requirements if [[ ${MERGE_TYPE} != binary ]]; then has ccache ${FEATURES} && die "FEATURES=ccache doesn't work with ${PN}, bug #677876" - [[ $(gcc-major-version) == 11 ]] && die "gcc 11 hangs when optimizing exploded image" + + if use jitserver && tc-is-clang; then + die "jitserver does not compile with clang" + fi fi } @@ -121,6 +120,8 @@ pkg_setup() { openjdk_check_requirements java-vm-2_pkg_setup + [[ ${MERGE_TYPE} == "binary" ]] && return + JAVA_PKG_WANT_BUILD_VM="openj9-openjdk-${SLOT} openj9-openjdk-bin-${SLOT} openjdk-${SLOT} openjdk-bin-${SLOT}" JAVA_PKG_WANT_SOURCE="${SLOT}" JAVA_PKG_WANT_TARGET="${SLOT}" @@ -135,31 +136,11 @@ pkg_setup() { local vm for vm in ${JAVA_PKG_WANT_BUILD_VM}; do - if [[ -d ${EPREFIX}/usr/lib/jvm/${vm} ]]; then + if [[ -d ${BROOT}/usr/lib/jvm/${vm} ]]; then java-pkg-2_pkg_setup return fi done - - if [[ ${MERGE_TYPE} != binary ]]; then - if [[ -z ${JDK_HOME} ]]; then - for slot in ${SLOT} $((SLOT-1)); do - for variant in openj9- ''; do - if has_version --host-root dev-java/${variant}openjdk:${slot}; then - JDK_HOME=${EPREFIX}/usr/$(get_libdir)/${variant}openjdk-${slot} - break - elif has_version --host-root dev-java/${variant}openjdk-bin:${slot}; then - JDK_HOME=$(best_version --host-root dev-java/${variant}openjdk-bin:${slot}) - JDK_HOME=${JDK_HOME#*/} - JDK_HOME=${EPREFIX}/opt/${JDK_HOME%-r*} - break - fi - done - done - fi - [[ -n ${JDK_HOME} ]] || die "Build VM not found!" - export JDK_HOME - fi } src_unpack() { @@ -184,30 +165,48 @@ src_prepare() { default + eapply -- "${FILESDIR}/openj9-openjdk-override-version.patch" eapply -d openj9 -- "${FILESDIR}/openj9-no-o3.patch" eapply -d omr -- "${FILESDIR}/omr-omrstr-iconv-failure-overflow.patch" - eapply -d omr -- "${FILESDIR}/omr-fam.patch" - if [[ ${OPENJ9_PV} != 9999 ]]; then - sed -i -e '/^OPENJ9_SHA :=/s/:=.*/:= '${OPENJ9_P}/ \ - -e '/^OPENJ9_TAG :=/s/:=.*/:= '${OPENJ9_P}/ \ - -e '/^OPENJ9OMR_SHA :=/s/:=.*/:= '${OPENJ9_P}/ \ - closed/OpenJ9.gmk - fi + find openj9/ omr/ -name CMakeLists.txt -exec sed -i -e '/set(OMR_WARNINGS_AS_ERRORS ON/s/ON/OFF/' {} + || die + sed -i -e '/^ OPENJ9_CONFIGURE_NUMA$/d' closed/autoconf/custom-hook.m4 || die chmod +x configure || die } src_configure() { + for variant in openj9- ''; do + if has_version dev-java/${variant}openjdk:${SLOT}; then + JDK_HOME=${EPREFIX}/usr/$(get_libdir)/${variant}openjdk-${SLOT} + break + elif has_version dev-java/${variant}openjdk-bin:${SLOT}; then + JDK_HOME=$(best_version dev-java/${variant}openjdk-bin:${SLOT}) + JDK_HOME=${JDK_HOME#*/} + JDK_HOME=${EPREFIX}/opt/${JDK_HOME%-r*} + break + fi + done + [[ -n ${JDK_HOME} ]] || die "Build VM not found!" + export JDK_HOME + # Work around stack alignment issue, bug #647954. in case we ever have x86 use x86 && append-flags -mincoming-stack-boundary=2 + # /tmp/portage/dev-java/openj9-openjdk-21.0.48.0/work/openj9-openjdk-jdk21-openj9-0.48.0/openj9/runtime/codert_vm/thunkcrt.c:95: error: function 'icallVMprJavaSendVirtualL' redeclared as variable + # 95 | extern void * icallVMprJavaSendVirtualL; + # /tmp/portage/dev-java/openj9-openjdk-21.0.48.0/work/openj9-openjdk-jdk21-openj9-0.48.0/openj9/runtime/compiler/runtime/Runtime.cpp:341:1: note: previously declared here + # 341 | JIT_HELPER(icallVMprJavaSendVirtualL); + filter-lto + # Enabling full docs appears to break doc building. If not # explicitly disabled, the flag will get auto-enabled if pandoc and # graphviz are detected. pandoc has loads of dependencies anyway. local myconf=( --disable-ccache + --disable-precompiled-headers + --disable-warnings-as-errors{,-omr,-openj9} --enable-full-docs=no --with-boot-jdk="${JDK_HOME}" --with-extra-cflags="${CFLAGS}" @@ -227,19 +226,20 @@ src_configure() { --with-vendor-vm-bug-url="https://bugs.openjdk.java.net" --with-vendor-version-string="${PVR}" --with-version-pre="" - --with-version-opt="" --with-zlib=system - --enable-dtrace=$(usex systemtap yes no) + --enable-jvm-feature-dtrace=$(usex systemtap yes no) --enable-headless-only=$(usex headless-awt yes no) $(tc-is-clang && echo "--with-toolchain-type=clang") - --disable-warnings-as-errors{,-omr,-openj9} --with-cmake $(use_enable ddr) + $(use_enable jitserver) ) + use lto && myconf+=( --with-jvm-features=link-time-opt ) + if use javafx; then - local zip="${EPREFIX%/}/usr/$(get_libdir)/openjfx-${SLOT}/javafx-exports.zip" + local zip="${EPREFIX}/usr/$(get_libdir)/openjfx-${SLOT}/javafx-exports.zip" if [[ -r ${zip} ]]; then myconf+=( --with-import-modules="${zip}" ) else @@ -247,13 +247,6 @@ src_configure() { fi fi - # PaX breaks pch, bug #601016 - if use pch && ! host-is-pax; then - myconf+=( --enable-precompiled-headers ) - else - myconf+=( --disable-precompiled-headers ) - fi - ( unset _JAVA_OPTIONS JAVA JAVA_TOOL_OPTIONS JAVAC XARGS CFLAGS= CXXFLAGS= LDFLAGS= \ @@ -263,21 +256,33 @@ src_configure() { } src_compile() { + local mycmakeargsx=( + "-DCMAKE_C_FLAGS='${CFLAGS}'" + "-DJ9JIT_EXTRA_CFLAGS='${CFLAGS}'" + "-DCMAKE_CXX_FLAGS='${CXXFLAGS}'" + "-DJ9JIT_EXTRA_CXXFLAGS='${CXXFLAGS}'" + "-DCMAKE_EXE_LINKER_FLAGS='${LDFLAGS}'" + -DOMR_WARNINGS_AS_ERRORS=OFF + -DOMR_PORT_NUMA_SUPPORT=$(usex numa) + ) local myemakeargs=( JOBS=$(makeopts_jobs) - # https://github.com/ibmruntimes/openj9-openjdk-jdk14/issues/72 - #LOG=debug + LOG=debug $(usex doc docs '') $(usex jbootstrap bootcycle-images product-images) - EXTRA_CMAKE_ARGS="-DOMR_WARNINGS_AS_ERRORS=OFF" + EXTRA_CMAKE_ARGS="${mycmakeargsx[*]}" + OPENJDK_SHA=$(ver_cut 1-3) + OPENJ9_SHA=${OPENJ9_P} + OPENJ9_TAG=${OPENJ9_P} + OPENJ9OMR_SHA=${OPENJ9_P} ) - emake "${myemakeargs[@]}" -j1 #nowarn + emake "${myemakeargs[@]}" -j1 } src_install() { local dest="/usr/$(get_libdir)/${PN}-${SLOT}" - local ddest="${ED}${dest#/}" + local ddest="${ED}/${dest#/}" cd "${S}"/build/*-release/images/jdk || die @@ -292,10 +297,6 @@ src_install() { rm -v lib/libjsound.* || die fi - if ! use examples ; then - rm -vr demo/ || die - fi - if ! use source ; then rm -v lib/src.zip || die fi @@ -305,12 +306,12 @@ src_install() { dodir "${dest}" cp -pPR * "${ddest}" || die - dosym ../../../../../etc/ssl/certs/java/cacerts "${dest}"/lib/security/cacerts + dosym -r /etc/ssl/certs/java/cacerts "${dest}"/lib/security/cacerts # must be done before running itself java-vm_set-pax-markings "${ddest}" - use gentoo-vm && java-vm_install-env "${FILESDIR}"/${PN}.env.sh + java-vm_install-env "${FILESDIR}"/${PN}.env.sh java-vm_revdep-mask java-vm_sandbox-predict /dev/random /proc/self/coredump_filter @@ -323,16 +324,4 @@ src_install() { pkg_postinst() { java-vm-2_pkg_postinst - - if use gentoo-vm ; then - ewarn "WARNING! You have enabled the gentoo-vm USE flag, making this JDK" - ewarn "recognised by the system. This will almost certainly break" - ewarn "many java ebuilds as they are not ready for openjdk-11" - else - ewarn "The experimental gentoo-vm USE flag has not been enabled so this JDK" - ewarn "will not be recognised by the system. For example, simply calling" - ewarn "\"java\" will launch a different JVM. This is necessary until Gentoo" - ewarn "fully supports Java ${SLOT}. This JDK must therefore be invoked using its" - ewarn "absolute location under ${EPREFIX}/usr/$(get_libdir)/${PN}-${SLOT}." - fi } diff --git a/dev-java/openjdk-bin/Manifest b/dev-java/openjdk-bin/Manifest deleted file mode 100644 index 4f83a41..0000000 --- a/dev-java/openjdk-bin/Manifest +++ /dev/null @@ -1,6 +0,0 @@ -DIST OpenJDK16U-jdk_aarch64_linux_hotspot_16.0.1_9.tar.gz 203066417 SHA256 3447ec27a6dbd4f3a6180a0d4371bb09aa428c16eea9983e515a7400cc9f5c85 -DIST OpenJDK16U-jdk_arm_linux_hotspot_16.0.1_9.tar.gz 187587741 SHA256 20fc395d8ea2659e6407cd4ec233dc4399f61b7610f3a16495deb23c1e3b81df -DIST OpenJDK16U-jdk_ppc64le_linux_hotspot_16.0.1_9.tar.gz 186081896 SHA256 8d8e35ca5a7e24f16384bf32b110562921c19b4cfe65969980937bf879462bc6 -DIST OpenJDK16U-jdk_s390x_linux_hotspot_16.0.1_9.tar.gz 178964996 SHA256 421cd44661cdbf0c2da79ab3104c81a1fa171b974038e55b1b3d4a042865588f -DIST OpenJDK16U-jdk_x64_linux_hotspot_16.0.1_9.tar.gz 205449187 SHA256 7fdda042207efcedd30cd76d6295ed56b9c2e248cb3682c50898a560d4aa1c6f -DIST OpenJDK16U-jdk_x64_linux_hotspot_16.0.2_7.tar.gz 205463525 BLAKE2B 65b8cbf626840e8e3cf5daffda9aed3763ae5c4e2458e71c9854b955cbce8404d498222ec0b30ead9e718d1ee794559f2bcd7b60f630bd0c7e140f671546e873 SHA512 af25ffaeea4034c3d4b14daeacf719e9de87896069885d51c677aaddb3104bc64487fbb4ab33afb420ed88ea60771626f674d998eaed8d4237f1a7cb751c2146 diff --git a/dev-java/openjdk-bin/files/openjdk-bin.env.sh b/dev-java/openjdk-bin/files/openjdk-bin.env.sh deleted file mode 100644 index 9e9c5ec..0000000 --- a/dev-java/openjdk-bin/files/openjdk-bin.env.sh +++ /dev/null @@ -1,16 +0,0 @@ -# Copyright 1999-2018 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -VERSION="AdoptOpenJDK ${PV}" -JAVA_HOME="${EPREFIX}/opt/${P}" -JDK_HOME="${EPREFIX}/opt/${P}" -JAVAC="\${JAVA_HOME}/bin/javac" -PATH="\${JAVA_HOME}/bin" -ROOTPATH="\${JAVA_HOME}/bin" -LDPATH="\${JAVA_HOME}/lib/:\${JAVA_HOME}/lib/server/" -MANPATH="" -PROVIDES_TYPE="JDK JRE" -PROVIDES_VERSION="${SLOT}" -BOOTCLASSPATH="" -GENERATION="2" -ENV_VARS="JAVA_HOME JDK_HOME JAVAC PATH ROOTPATH LDPATH MANPATH" diff --git a/dev-java/openjdk-bin/metadata.xml b/dev-java/openjdk-bin/metadata.xml deleted file mode 100644 index 4c0b1aa..0000000 --- a/dev-java/openjdk-bin/metadata.xml +++ /dev/null @@ -1,14 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> -<pkgmetadata> - <longdescription> - Java™ is the world's leading programming language and platform. - The code for Java is open source and available at OpenJDK™. - AdoptOpenJDK provides prebuilt OpenJDK binaries from a fully open source set of build scripts and infrastructure. - </longdescription> - <use> - <flag name="headless-awt">Don't install the X backend for AWT, needed by some GUIs (used to be X flag)</flag> - <flag name="gentoo-vm">Allow this JDK to be recognised by Gentoo (package manager, eselect, java-config, EXPERIMENTAL!)</flag> - <flag name="source">Install JVM sources</flag> - </use> -</pkgmetadata> diff --git a/dev-java/openjdk-bin/openjdk-bin-16.0.2_p7.ebuild b/dev-java/openjdk-bin/openjdk-bin-16.0.2_p7.ebuild deleted file mode 100644 index 82df0fe..0000000 --- a/dev-java/openjdk-bin/openjdk-bin-16.0.2_p7.ebuild +++ /dev/null @@ -1,106 +0,0 @@ -# Copyright 1999-2020 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=6 - -inherit java-vm-2 toolchain-funcs - -abi_uri() { - echo "${2-$1}? ( - https://github.com/adoptium/temurin${SLOT}-binaries/releases/download/jdk-${MY_PV/+/%2B}/OpenJDK${SLOT}U-jdk_${1}_linux_hotspot_${MY_PV/+/_}.tar.gz - )" -} - -MY_PV=${PV/_p/+} -SLOT=${MY_PV%%[.+]*} - -SRC_URI=" - $(abi_uri aarch64 arm64) - $(abi_uri ppc64le ppc64) - $(abi_uri s390x s390) - $(abi_uri x64 amd64) -" - -DESCRIPTION="Prebuilt Java JDK binaries provided by Eclipse Temurin" -HOMEPAGE="https://adoptopenjdk.net" -LICENSE="GPL-2-with-classpath-exception" -KEYWORDS="~amd64 ~arm64 ~ppc64 ~s390" -IUSE="alsa cups +gentoo-vm headless-awt selinux source" - -RDEPEND=" - media-libs/fontconfig:1.0 - media-libs/freetype:2 - >=sys-apps/baselayout-java-0.1.0-r1 - >=sys-libs/glibc-2.2.5:* - sys-libs/zlib - alsa? ( media-libs/alsa-lib ) - cups? ( net-print/cups ) - selinux? ( sec-policy/selinux-java ) - !headless-awt? ( - x11-libs/libX11 - x11-libs/libXext - x11-libs/libXi - x11-libs/libXrender - x11-libs/libXtst - )" - -RESTRICT="preserve-libs splitdebug" -QA_PREBUILT="*" - -S="${WORKDIR}/jdk-${MY_PV}" - -pkg_pretend() { - if [[ "$(tc-is-softfloat)" != "no" ]]; then - die "These binaries require a hardfloat system." - fi -} - -src_install() { - local dest="/opt/${P}" - local ddest="${ED%/}/${dest#/}" - - # Oracle and IcedTea have libjsoundalsa.so depending on - # libasound.so.2 but AdoptOpenJDK only has libjsound.so. Weird. - if ! use alsa ; then - rm -v lib/libjsound.* || die - fi - - if use headless-awt ; then - rm -v lib/lib*{[jx]awt,splashscreen}* || die - fi - - if ! use source ; then - rm -v lib/src.zip || die - fi - - rm -v lib/security/cacerts || die - dosym ../../../../etc/ssl/certs/java/cacerts \ - "${dest}"/lib/security/cacerts - - dodir "${dest}" - cp -pPR * "${ddest}" || die - - # provide stable symlink - dosym "${P}" "/opt/${PN}-${SLOT}" - - use gentoo-vm && java-vm_install-env "${FILESDIR}"/${PN}.env.sh - java-vm_set-pax-markings "${ddest}" - java-vm_revdep-mask - java-vm_sandbox-predict /dev/random /proc/self/coredump_filter -} - -pkg_postinst() { - java-vm-2_pkg_postinst - - if use gentoo-vm ; then - ewarn "WARNING! You have enabled the gentoo-vm USE flag, making this JDK" - ewarn "recognised by the system. This will almost certainly break" - ewarn "many java ebuilds as they are not ready for openjdk-11" - else - ewarn "The experimental gentoo-vm USE flag has not been enabled so this JDK" - ewarn "will not be recognised by the system. For example, simply calling" - ewarn "\"java\" will launch a different JVM. This is necessary until Gentoo" - ewarn "fully supports Java 11. This JDK must therefore be invoked using its" - ewarn "absolute location under ${EPREFIX}/opt/${P}." - fi -} diff --git a/dev-java/openjdk-jre-bin/Manifest b/dev-java/openjdk-jre-bin/Manifest deleted file mode 100644 index 8fc1426..0000000 --- a/dev-java/openjdk-jre-bin/Manifest +++ /dev/null @@ -1,4 +0,0 @@ -DIST OpenJDK16U-jre_aarch64_linux_hotspot_16.0.1_9.tar.gz 47622188 SHA256 4e47f1cbf46190727be74cd73445ec2b693f5ba4a74542c554d6b3285811cab5 -DIST OpenJDK16U-jre_arm_linux_hotspot_16.0.1_9.tar.gz 43628046 SHA256 c1f88f3ce955cb2e9a4236a916cc6660ef55231d29c4390b1a4398ebbca358b7 -DIST OpenJDK16U-jre_ppc64le_linux_hotspot_16.0.1_9.tar.gz 44094924 SHA256 495805e2e9bcabeac0d8271623b6c92604440608286f4ce411ea48f582854930 -DIST OpenJDK16U-jre_x64_linux_hotspot_16.0.1_9.tar.gz 48818276 SHA256 5eca19d406c6d130e9c3a4b932b9cb0a6e9cd45932450668c3e911bded4bcf40 diff --git a/dev-java/openjdk-jre-bin/files/openjdk-jre-bin.env.sh b/dev-java/openjdk-jre-bin/files/openjdk-jre-bin.env.sh deleted file mode 100644 index ec0dca4..0000000 --- a/dev-java/openjdk-jre-bin/files/openjdk-jre-bin.env.sh +++ /dev/null @@ -1,16 +0,0 @@ -# Copyright 1999-2019 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -VERSION="AdoptOpenJDK JRE ${PV}" -JAVA_HOME="${EPREFIX}/opt/${P}" -JDK_HOME="${EPREFIX}/opt/${P}" -JAVAC="\${JAVA_HOME}/bin/javac" -PATH="\${JAVA_HOME}/bin" -ROOTPATH="\${JAVA_HOME}/bin" -LDPATH="\${JAVA_HOME}/lib/:\${JAVA_HOME}/lib/server/" -MANPATH="\${JAVA_HOME}/man" -PROVIDES_TYPE="JRE" -PROVIDES_VERSION="${SLOT}" -BOOTCLASSPATH="" -GENERATION="2" -ENV_VARS="JAVA_HOME JDK_HOME JAVAC PATH ROOTPATH LDPATH MANPATH" diff --git a/dev-java/openjdk-jre-bin/metadata.xml b/dev-java/openjdk-jre-bin/metadata.xml deleted file mode 100644 index 8fa79b5..0000000 --- a/dev-java/openjdk-jre-bin/metadata.xml +++ /dev/null @@ -1,21 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> -<pkgmetadata> - <maintainer type="person"> - <email>gyakovlev@gentoo.org</email> - <name>Georgy Yakovlev</name> - </maintainer> - <maintainer type="project"> - <email>java@gentoo.org</email> - <name>Java</name> - </maintainer> - <longdescription> - Java™ is the world's leading programming language and platform. - The code for Java is open source and available at OpenJDK™. - AdoptOpenJDK provides prebuilt OpenJDK JRE binaries from a fully open source set of build scripts and infrastructure. - </longdescription> - <use> - <flag name="headless-awt">Don't install the X backend for AWT, needed by some GUIs (used to be X flag)</flag> - <flag name="gentoo-vm">Allow this JDK to be recognised by Gentoo (package manager, eselect, java-config, EXPERIMENTAL!)</flag> - </use> -</pkgmetadata> diff --git a/dev-java/openjdk-jre-bin/openjdk-jre-bin-16.0.1_p9.ebuild b/dev-java/openjdk-jre-bin/openjdk-jre-bin-16.0.1_p9.ebuild deleted file mode 100644 index 8e41243..0000000 --- a/dev-java/openjdk-jre-bin/openjdk-jre-bin-16.0.1_p9.ebuild +++ /dev/null @@ -1,95 +0,0 @@ -# Copyright 1999-2020 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=6 - -inherit java-vm-2 - -abi_uri() { - echo "${2-$1}? ( - https://github.com/AdoptOpenJDK/openjdk${SLOT}-binaries/releases/download/jdk-${MY_PV/+/%2B}/OpenJDK${SLOT}U-jre_${1}_linux_hotspot_${MY_PV/+/_}.tar.gz - )" -} - -MY_PV=${PV/_p/+} -SLOT=${MY_PV%%[.+]*} - -SRC_URI=" - $(abi_uri arm) - $(abi_uri aarch64 arm64) - $(abi_uri ppc64le ppc64) - $(abi_uri x64 amd64) -" - -DESCRIPTION="Prebuilt Java JRE binaries provided by AdoptOpenJDK" -HOMEPAGE="https://adoptopenjdk.net" -LICENSE="GPL-2-with-classpath-exception" -KEYWORDS="~amd64 ~arm ~arm64 ~ppc64" -IUSE="alsa cups +gentoo-vm headless-awt selinux" - -RDEPEND=" - media-libs/fontconfig:1.0 - media-libs/freetype:2 - >net-libs/libnet-1.1 - >=sys-apps/baselayout-java-0.1.0-r1 - >=sys-libs/glibc-2.2.5:* - sys-libs/zlib - alsa? ( media-libs/alsa-lib ) - cups? ( net-print/cups ) - selinux? ( sec-policy/selinux-java ) - !headless-awt? ( - x11-libs/libX11 - x11-libs/libXext - x11-libs/libXi - x11-libs/libXrender - x11-libs/libXtst - )" - -RESTRICT="preserve-libs splitdebug" -QA_PREBUILT="*" - -S="${WORKDIR}/jdk-${MY_PV}-jre" - -src_install() { - local dest="/opt/${P}" - local ddest="${ED%/}/${dest#/}" - - # Oracle and IcedTea have libjsoundalsa.so depending on - # libasound.so.2 but AdoptOpenJDK only has libjsound.so. Weird. - if ! use alsa ; then - rm -v lib/libjsound.* || die - fi - - if use headless-awt ; then - rm -v lib/lib*{[jx]awt,splashscreen}* || die - fi - - rm -v lib/security/cacerts || die - dosym ../../../../etc/ssl/certs/java/cacerts "${dest}"/lib/security/cacerts - - dodir "${dest}" - cp -pPR * "${ddest}" || die - - # provide stable symlink - dosym "${P}" "/opt/${PN}-${SLOT}" - - use gentoo-vm && java-vm_install-env "${FILESDIR}"/${PN}.env.sh - java-vm_set-pax-markings "${ddest}" - java-vm_revdep-mask - java-vm_sandbox-predict /dev/random /proc/self/coredump_filter -} - -pkg_postinst() { - java-vm-2_pkg_postinst - - if use gentoo-vm ; then - ewarn "WARNING! You have enabled the gentoo-vm USE flag, making this JRE" - ewarn "recognised by the system. This will almost certainly break things." - else - ewarn "The experimental gentoo-vm USE flag has not been enabled so this JRE" - ewarn "will not be recognised by the system. For example, simply calling" - ewarn "\"java\" will launch a different JVM. This is necessary until Gentoo" - ewarn "fully supports Java 11. This JRE must therefore be invoked using its" - ewarn "absolute location under ${EPREFIX}/opt/${P}." - fi -} diff --git a/dev-java/openjdk/Manifest b/dev-java/openjdk/Manifest deleted file mode 100644 index d28c01e..0000000 --- a/dev-java/openjdk/Manifest +++ /dev/null @@ -1 +0,0 @@ -DIST openjdk-17.0.0_p35.tar.gz 104576069 BLAKE2B 079865c8c679836b7edf04e2341b60713bbd7dbc43a608a23c03359e2a636d9dd972d2c79ec3c45bcd3ad7ea54dd15ef697480efb86ee5ad0022fd360818696d SHA512 6f263bc78f00f42612c42282fb40370315e7c93454d69ad12ad98463a3397f6eeda21e661a42749c9807d84f672ed90bfce59c889a407f3cf60744e205233fff diff --git a/dev-java/openjdk/files/openjdk.env.sh b/dev-java/openjdk/files/openjdk.env.sh deleted file mode 100644 index 96c4be7..0000000 --- a/dev-java/openjdk/files/openjdk.env.sh +++ /dev/null @@ -1,16 +0,0 @@ -# Copyright 1999-2018 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -VERSION="OpenJDK ${PV}" -JAVA_HOME="${EPREFIX}/usr/$(get_libdir)/${PN}-${SLOT}" -JDK_HOME="${EPREFIX}/usr/$(get_libdir)/${PN}-${SLOT}" -JAVAC="\${JAVA_HOME}/bin/javac" -PATH="\${JAVA_HOME}/bin" -ROOTPATH="\${JAVA_HOME}/bin" -LDPATH="\${JAVA_HOME}/lib/:\${JAVA_HOME}/lib/server/" -MANPATH="" -PROVIDES_TYPE="JDK JRE" -PROVIDES_VERSION="${SLOT}" -BOOTCLASSPATH="" -GENERATION="2" -ENV_VARS="JAVA_HOME JDK_HOME JAVAC PATH ROOTPATH LDPATH MANPATH" diff --git a/dev-java/openjdk/metadata.xml b/dev-java/openjdk/metadata.xml deleted file mode 100644 index e95815a..0000000 --- a/dev-java/openjdk/metadata.xml +++ /dev/null @@ -1,15 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> -<pkgmetadata> - <slots> - <slot name="14">Java™ version 14</slot> - </slots> - <use> - <flag name="headless-awt">Don't install the X backend for AWT, needed by some GUIs</flag> - <flag name="gentoo-vm">Allow this JDK to be recognised by Gentoo (package manager, eselect, java-config, EXPERIMENTAL!)</flag> - <flag name="javafx">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="systemtap">Enable SystemTAP/DTrace tracing</flag> - </use> -</pkgmetadata> diff --git a/dev-java/openjdk/openjdk-17.0.0_p35.ebuild b/dev-java/openjdk/openjdk-17.0.0_p35.ebuild deleted file mode 100644 index d1b1e48..0000000 --- a/dev-java/openjdk/openjdk-17.0.0_p35.ebuild +++ /dev/null @@ -1,242 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=6 - -inherit autotools check-reqs flag-o-matic java-pkg-2 java-vm-2 multiprocessing pax-utils toolchain-funcs - -# we need -ga tag to fetch tarball and unpack it, but exact number everywhere else to -# set build version properly -MY_PV="${PV%_p*}" -MY_PV="${MY_PV%.0.0}-ga" -SLOT="${PV%%[.+]*}" - -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" - -LICENSE="GPL-2" -KEYWORDS="~amd64 ~arm ~arm64 ~ppc64" - -IUSE="alsa cups debug doc examples gentoo-vm headless-awt javafx +jbootstrap +pch selinux source systemtap" - -COMMON_DEPEND=" - media-libs/freetype:2= - media-libs/giflib:0/7 - media-libs/harfbuzz:= - media-libs/libpng:0= - media-libs/lcms:2= - sys-libs/zlib - virtual/jpeg:0= - systemtap? ( dev-util/systemtap ) -" - -# Many libs are required to build, but not to run, make is possible to remove -# by listing conditionally in RDEPEND unconditionally in DEPEND -RDEPEND=" - ${COMMON_DEPEND} - >=sys-apps/baselayout-java-0.1.0-r1 - !headless-awt? ( - x11-libs/libX11 - x11-libs/libXext - x11-libs/libXi - x11-libs/libXrandr - x11-libs/libXrender - x11-libs/libXt - x11-libs/libXtst - ) - alsa? ( media-libs/alsa-lib ) - cups? ( net-print/cups ) - selinux? ( sec-policy/selinux-java ) -" - -DEPEND=" - ${COMMON_DEPEND} - app-arch/zip - media-libs/alsa-lib - net-print/cups - x11-base/xorg-proto - x11-libs/libX11 - x11-libs/libXext - x11-libs/libXi - x11-libs/libXrandr - x11-libs/libXrender - x11-libs/libXt - x11-libs/libXtst - || ( - virtual/jdk:${SLOT} - virtual/jdk:$((SLOT-1)) - ) - javafx? ( dev-java/openjfx:${SLOT}= ) -" - -REQUIRED_USE="javafx? ( alsa !headless-awt )" - -S="${WORKDIR}/jdk${SLOT}u-jdk-${MY_PV}" - -# The space required to build varies wildly depending on USE flags, -# ranging from 2GB to 16GB. This function is certainly not exact but -# should be close enough to be useful. -openjdk_check_requirements() { - local M - M=2048 - M=$(( $(usex jbootstrap 2 1) * $M )) - M=$(( $(usex debug 3 1) * $M )) - M=$(( $(usex doc 320 0) + $(usex source 128 0) + 192 + $M )) - - CHECKREQS_DISK_BUILD=${M}M check-reqs_pkg_${EBUILD_PHASE} -} - -pkg_pretend() { - openjdk_check_requirements - if [[ ${MERGE_TYPE} != binary ]]; then - has ccache ${FEATURES} && die "FEATURES=ccache doesn't work with ${PN}, bug #677876" - fi -} - -pkg_setup() { - openjdk_check_requirements - java-vm-2_pkg_setup - java-pkg-2_pkg_setup -} - -src_prepare() { - default - chmod +x configure || die -} - -src_configure() { - # Work around stack alignment issue, bug #647954. in case we ever have x86 - use x86 && append-flags -mincoming-stack-boundary=2 - - # Enabling full docs appears to break doc building. If not - # explicitly disabled, the flag will get auto-enabled if pandoc and - # graphviz are detected. pandoc has loads of dependencies anyway. - - local myconf=( - --disable-ccache - --enable-full-docs=no - --with-boot-jdk="${JDK_HOME}" - --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-native-debug-symbols=$(usex debug internal none) - --with-vendor-name="Gentoo" - --with-vendor-url="https://gentoo.org" - --with-vendor-bug-url="https://bugs.gentoo.org" - --with-vendor-vm-bug-url="https://bugs.openjdk.java.net" - --with-vendor-version-string="${PVR}" - --with-version-pre="" - --with-version-string="${PV%_p*}" - --with-version-build="${PV#*_p}" - --with-zlib=system - --enable-dtrace=$(usex systemtap yes no) - --enable-headless-only=$(usex headless-awt yes no) - $(tc-is-clang && echo "--with-toolchain-type=clang") - ) - - if use javafx; then - local zip="${EPREFIX%/}/usr/$(get_libdir)/openjfx-${SLOT}/javafx-exports.zip" - if [[ -r ${zip} ]]; then - myconf+=( --with-import-modules="${zip}" ) - else - die "${zip} not found or not readable" - fi - fi - - # PaX breaks pch, bug #601016 - if use pch && ! host-is-pax; then - myconf+=( --enable-precompiled-headers ) - else - myconf+=( --disable-precompiled-headers ) - fi - - ( - unset _JAVA_OPTIONS JAVA JAVA_TOOL_OPTIONS JAVAC XARGS - CFLAGS= CXXFLAGS= LDFLAGS= \ - CONFIG_SITE=/dev/null \ - econf "${myconf[@]}" - ) -} - -src_compile() { - local myemakeargs=( - JOBS=$(makeopts_jobs) - LOG=debug - CFLAGS_WARNINGS_ARE_ERRORS= # No -Werror - $(usex doc docs '') - $(usex jbootstrap bootcycle-images product-images) - ) - emake "${myemakeargs[@]}" -j1 #nowarn -} - -src_install() { - local dest="/usr/$(get_libdir)/${PN}-${SLOT}" - local ddest="${ED}${dest#/}" - - cd "${S}"/build/*-release/images/jdk || die - - # Create files used as storage for system preferences. - mkdir .systemPrefs || die - touch .systemPrefs/.system.lock || die - touch .systemPrefs/.systemRootModFile || die - - # Oracle and IcedTea have libjsoundalsa.so depending on - # libasound.so.2 but OpenJDK only has libjsound.so. Weird. - if ! use alsa ; then - rm -v lib/libjsound.* || die - fi - - if ! use examples ; then - rm -vr demo/ || die - fi - - if ! use source ; then - rm -v lib/src.zip || die - fi - - rm -v lib/security/cacerts || die - - dodir "${dest}" - cp -pPR * "${ddest}" || die - - dosym ../../../../../etc/ssl/certs/java/cacerts "${dest}"/lib/security/cacerts - - # must be done before running itself - java-vm_set-pax-markings "${ddest}" - - einfo "Creating the Class Data Sharing archives and disabling usage tracking" - "${ddest}/bin/java" -server -Xshare:dump -Djdk.disableLastUsageTracking || die - - use gentoo-vm && java-vm_install-env "${FILESDIR}"/${PN}.env.sh - java-vm_revdep-mask - java-vm_sandbox-predict /dev/random /proc/self/coredump_filter - - if use doc ; then - docinto html - dodoc -r "${S}"/build/*-release/images/docs/* - dosym ../../../usr/share/doc/"${PF}" /usr/share/doc/"${PN}-${SLOT}" - fi -} - -pkg_postinst() { - java-vm-2_pkg_postinst - - if use gentoo-vm ; then - ewarn "WARNING! You have enabled the gentoo-vm USE flag, making this JDK" - ewarn "recognised by the system. This will almost certainly break" - ewarn "many java ebuilds as they are not ready for openjdk-11" - else - ewarn "The experimental gentoo-vm USE flag has not been enabled so this JDK" - ewarn "will not be recognised by the system. For example, simply calling" - ewarn "\"java\" will launch a different JVM. This is necessary until Gentoo" - ewarn "fully supports Java ${SLOT}. This JDK must therefore be invoked using its" - ewarn "absolute location under ${EPREFIX}/usr/$(get_libdir)/${PN}-${SLOT}." - fi -} |