Merge branch 'rawhide' into epel9
This commit is contained in:
commit
0d22f72ea5
2
.gitignore
vendored
2
.gitignore
vendored
@ -41,3 +41,5 @@
|
||||
/openjdk-21.0.2+11.tar.xz
|
||||
/openjdk-21.0.2+12.tar.xz
|
||||
/openjdk-21.0.2+13.tar.xz
|
||||
/openjdk-22+32-ea.tar.xz
|
||||
/openjdk-jdk-22+36-ea.tar.xz
|
||||
|
10
README.md
10
README.md
@ -1,14 +1,16 @@
|
||||
# java-latest-openjdk-portable
|
||||
|
||||
This package contains the latest rolling release of OpenJDK. OpenJDK
|
||||
has a release cadence of six months, with a new release in March and
|
||||
September each year.
|
||||
|
||||
The current release is OpenJDK 21. For a list of major changes from
|
||||
OpenJDK 20, see the NEWS file included in this package and the
|
||||
The current release is OpenJDK 22. For a list of major changes from
|
||||
OpenJDK 21, see the NEWS file included in this package and the
|
||||
upstream release page:
|
||||
|
||||
https://openjdk.java.net/projects/jdk/21/
|
||||
https://openjdk.java.net/projects/jdk/22/
|
||||
|
||||
This package is intended for those who want to follow the latest
|
||||
OpenJDK releases. Long term support versions of OpenJDK are available
|
||||
in the java-1.8.0-openjdk, java-11-openjdk and java-17-openjdk
|
||||
in the java-1.8.0-openjdk, java-11-openjdk, java-17-openjdk and java-21-openjdk
|
||||
packages.
|
||||
|
@ -1,51 +1,123 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Copyright (C) 2024 Red Hat, Inc.
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU Affero General Public License as
|
||||
# published by the Free Software Foundation, either version 3 of the
|
||||
# License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU Affero General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Affero General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
# Generates the 'source tarball' for JDK projects.
|
||||
#
|
||||
# Example:
|
||||
# When used from local repo set REPO_ROOT pointing to file:// with your repo
|
||||
# If your local repo follows upstream forests conventions, it may be enough to set OPENJDK_URL
|
||||
# Example 1:
|
||||
# When used from local repo set REPO_ROOT pointing to file:// with your repo.
|
||||
# If your local repo follows upstream forests conventions, it may be enough to
|
||||
# set OPENJDK_URL.
|
||||
#
|
||||
# Example 2:
|
||||
# This will read the OpenJDK feature version from the spec file, then create a
|
||||
# tarball from the most recent tag for that version in the upstream Git
|
||||
# repository.
|
||||
#
|
||||
# $ OPENJDK_LATEST=1 ./generate_source_tarball.sh
|
||||
# [...]
|
||||
# Tarball is: temp-generated-source-tarball-ujD/openjdk-17.0.10+6-ea.tar.xz
|
||||
#
|
||||
# Unless you use OPENJDK_LATEST, you have to set PROJECT_NAME, REPO_NAME and
|
||||
# VERSION, e.g.:
|
||||
#
|
||||
# In any case you have to set PROJECT_NAME REPO_NAME and VERSION. eg:
|
||||
# PROJECT_NAME=openjdk
|
||||
# REPO_NAME=jdk21u
|
||||
# VERSION=jdk-21.0.1+12
|
||||
# or to eg prepare systemtap:
|
||||
# icedtea7's jstack and other tapsets
|
||||
# REPO_NAME=jdk22u
|
||||
# VERSION=jdk-22+36
|
||||
#
|
||||
# or to e.g., prepare systemtap, icedtea7's jstack and other tapsets:
|
||||
#
|
||||
# VERSION=6327cf1cea9e
|
||||
# REPO_NAME=icedtea7-2.6
|
||||
# PROJECT_NAME=release
|
||||
# OPENJDK_URL=http://icedtea.classpath.org/hg/
|
||||
# TO_COMPRESS="*/tapset"
|
||||
#
|
||||
# They are used to create correct name and are used in construction of sources url (unless REPO_ROOT is set)
|
||||
|
||||
# This script creates a single source tarball out of the repository
|
||||
# based on the given tag and removes code not allowed in fedora/rhel. For
|
||||
# consistency, the source tarball will always contain 'openjdk' as the top
|
||||
# level folder, name is created, based on parameter
|
||||
# They are used to create correct name and are used in construction of sources
|
||||
# URL (unless REPO_ROOT is set).
|
||||
#
|
||||
# This script creates a single source tarball out of the repository based on the
|
||||
# given tag and removes code not allowed in Fedora/RHEL.
|
||||
|
||||
set -e
|
||||
|
||||
OPENJDK_URL_DEFAULT=https://github.com
|
||||
COMPRESSION_DEFAULT=xz
|
||||
|
||||
if [ "x$1" = "xhelp" ] ; then
|
||||
echo -e "Behaviour may be specified by setting the following variables:\n"
|
||||
echo "VERSION - the version of the specified OpenJDK project"
|
||||
echo "PROJECT_NAME -- the name of the OpenJDK project being archived (optional; only needed by defaults)"
|
||||
echo "REPO_NAME - the name of the OpenJDK repository (optional; only needed by defaults)"
|
||||
echo "OPENJDK_URL - the URL to retrieve code from (optional; defaults to ${OPENJDK_URL_DEFAULT})"
|
||||
echo "COMPRESSION - the compression type to use (optional; defaults to ${COMPRESSION_DEFAULT})"
|
||||
echo "FILE_NAME_ROOT - name of the archive, minus extensions (optional; defaults to PROJECT_NAME-REPO_NAME-VERSION)"
|
||||
echo "REPO_ROOT - the location of the Git repository to archive (optional; defaults to OPENJDK_URL/PROJECT_NAME/REPO_NAME.git)"
|
||||
echo "TO_COMPRESS - what part of clone to pack (default is ${VERSION})"
|
||||
echo "BOOT_JDK - the bootstrap JDK to satisfy the configure run"
|
||||
if [ "$1" = "help" ] ; then
|
||||
echo "Behaviour may be specified by setting the following variables:"
|
||||
echo
|
||||
echo "VERSION - the version of the specified OpenJDK project"
|
||||
echo " (required unless OPENJDK_LATEST is set)"
|
||||
echo "PROJECT_NAME - the name of the OpenJDK project being archived"
|
||||
echo " (needed to compute REPO_ROOT and/or"
|
||||
echo " FILE_NAME_ROOT automatically;"
|
||||
echo " optional if they are set explicitly)"
|
||||
echo "REPO_NAME - the name of the OpenJDK repository"
|
||||
echo " (needed to compute REPO_ROOT automatically;"
|
||||
echo " optional if REPO_ROOT is set explicitly)"
|
||||
echo "OPENJDK_URL - the URL to retrieve code from"
|
||||
echo " (defaults to ${OPENJDK_URL_DEFAULT})"
|
||||
echo "COMPRESSION - the compression type to use"
|
||||
echo " (defaults to ${COMPRESSION_DEFAULT})"
|
||||
echo "FILE_NAME_ROOT - name of the archive, minus extensions"
|
||||
echo " (defaults to PROJECT_NAME-VERSION)"
|
||||
echo "REPO_ROOT - the location of the Git repository to archive"
|
||||
echo " (defaults to OPENJDK_URL/PROJECT_NAME/REPO_NAME.git)"
|
||||
echo "TO_COMPRESS - what part of clone to pack"
|
||||
echo " (defaults to ${VERSION})"
|
||||
echo "BOOT_JDK - the bootstrap JDK to satisfy the configure run"
|
||||
echo " (defaults to packaged JDK version)"
|
||||
echo "WITH_TEMP - run in a temporary directory"
|
||||
echo " (defaults to disabled)"
|
||||
echo "OPENJDK_LATEST - deduce VERSION from most recent upstream tag"
|
||||
echo " (implies WITH_TEMP, computes everything else"
|
||||
echo " automatically; Note: accesses network to read"
|
||||
echo " tag list from remote Git repository)"
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
if [ "$OPENJDK_LATEST" != "" ] ; then
|
||||
FEATURE_VERSION=$(echo '%featurever' \
|
||||
| rpmspec --shell ./*.spec 2>/dev/null \
|
||||
| grep --after-context 1 featurever \
|
||||
| tail --lines 1)
|
||||
PROJECT_NAME=openjdk
|
||||
REPO_NAME=jdk"${FEATURE_VERSION}"u
|
||||
# Skip -ga tags since those are the same as the most recent non-ga tag, and
|
||||
# the non-ga tag is the one that is used to generated the official source
|
||||
# tarball. For example:
|
||||
# ca760c86642aa2e0d9b571aaabac054c0239fbdc refs/tags/jdk-17.0.10-ga^{}
|
||||
# 25a2e6c20c9a96853714284cabc6b456eb095070 refs/tags/jdk-17.0.10-ga
|
||||
# ca760c86642aa2e0d9b571aaabac054c0239fbdc refs/tags/jdk-17.0.10+7^{}
|
||||
# e49c5749b10f3e90274b72e9279f794fdd191d27 refs/tags/jdk-17.0.10+7
|
||||
VERSION=$(git ls-remote --tags --refs --sort=-version:refname \
|
||||
"${OPENJDK_URL_DEFAULT}/${PROJECT_NAME}/${REPO_NAME}.git" \
|
||||
"jdk-${FEATURE_VERSION}*" \
|
||||
| grep --invert-match '\-ga$' \
|
||||
| head --lines 1 | cut --characters 52-)
|
||||
FILE_NAME_ROOT=open${VERSION}
|
||||
WITH_TEMP=1
|
||||
fi
|
||||
|
||||
if [ "x$VERSION" = "x" ] ; then
|
||||
if [ "$WITH_TEMP" != "" ] ; then
|
||||
pushd "$(mktemp --directory temp-generated-source-tarball-XXX)"
|
||||
fi
|
||||
|
||||
if [ "$VERSION" = "" ] ; then
|
||||
echo "No VERSION specified"
|
||||
exit 2
|
||||
fi
|
||||
@ -57,18 +129,18 @@ BUILD_VER=${NUM_VER##*+}
|
||||
MAJOR_VER=${RELEASE_VER%%.*}
|
||||
echo "Major version is ${MAJOR_VER}, release ${RELEASE_VER}, build ${BUILD_VER}"
|
||||
|
||||
if [ "x$BOOT_JDK" = "x" ] ; then
|
||||
if [ "$BOOT_JDK" = "" ] ; then
|
||||
echo "No boot JDK specified".
|
||||
BOOT_JDK=/usr/lib/jvm/java-${MAJOR_VER}-openjdk;
|
||||
echo -n "Checking for ${BOOT_JDK}...";
|
||||
if [ -d ${BOOT_JDK} -a -x ${BOOT_JDK}/bin/java ] ; then
|
||||
if [ -d "${BOOT_JDK}" ] && [ -x "${BOOT_JDK}"/bin/java ] ; then
|
||||
echo "Boot JDK found at ${BOOT_JDK}";
|
||||
else
|
||||
echo "Not found";
|
||||
PREV_VER=$((${MAJOR_VER} - 1));
|
||||
PREV_VER=$((MAJOR_VER - 1));
|
||||
BOOT_JDK=/usr/lib/jvm/java-${PREV_VER}-openjdk;
|
||||
echo -n "Checking for ${BOOT_JDK}...";
|
||||
if [ -d ${BOOT_JDK} -a -x ${BOOT_JDK}/bin/java ] ; then
|
||||
if [ -d ${BOOT_JDK} ] && [ -x ${BOOT_JDK}/bin/java ] ; then
|
||||
echo "Boot JDK found at ${BOOT_JDK}";
|
||||
else
|
||||
echo "Not found";
|
||||
@ -79,43 +151,41 @@ else
|
||||
echo "Boot JDK: ${BOOT_JDK}";
|
||||
fi
|
||||
|
||||
# REPO_NAME is only needed when we default on REPO_ROOT and FILE_NAME_ROOT
|
||||
if [ "x$FILE_NAME_ROOT" = "x" -o "x$REPO_ROOT" = "x" ] ; then
|
||||
if [ "x$PROJECT_NAME" = "x" ] ; then
|
||||
echo "No PROJECT_NAME specified"
|
||||
exit 1
|
||||
fi
|
||||
echo "Project name: ${PROJECT_NAME}"
|
||||
if [ "x$REPO_NAME" = "x" ] ; then
|
||||
echo "No REPO_NAME specified"
|
||||
exit 3
|
||||
fi
|
||||
echo "Repository name: ${REPO_NAME}"
|
||||
fi
|
||||
|
||||
if [ "x$OPENJDK_URL" = "x" ] ; then
|
||||
if [ "$OPENJDK_URL" = "" ] ; then
|
||||
OPENJDK_URL=${OPENJDK_URL_DEFAULT}
|
||||
echo "No OpenJDK URL specified; defaulting to ${OPENJDK_URL}"
|
||||
else
|
||||
echo "OpenJDK URL: ${OPENJDK_URL}"
|
||||
fi
|
||||
|
||||
if [ "x$COMPRESSION" = "x" ] ; then
|
||||
if [ "$COMPRESSION" = "" ] ; then
|
||||
# rhel 5 needs tar.gz
|
||||
COMPRESSION=${COMPRESSION_DEFAULT}
|
||||
fi
|
||||
echo "Creating a tar.${COMPRESSION} archive"
|
||||
|
||||
if [ "x$FILE_NAME_ROOT" = "x" ] ; then
|
||||
FILE_NAME_ROOT=${PROJECT_NAME}-${REPO_NAME}-${VERSION}
|
||||
if [ "$FILE_NAME_ROOT" = "" ] ; then
|
||||
if [ "$PROJECT_NAME" = "" ] ; then
|
||||
echo "No PROJECT_NAME specified, needed by FILE_NAME_ROOT"
|
||||
exit 1
|
||||
fi
|
||||
FILE_NAME_ROOT=${PROJECT_NAME}-${VERSION}
|
||||
echo "No file name root specified; default to ${FILE_NAME_ROOT}"
|
||||
fi
|
||||
if [ "x$REPO_ROOT" = "x" ] ; then
|
||||
if [ "$REPO_ROOT" = "" ] ; then
|
||||
if [ "$PROJECT_NAME" = "" ] ; then
|
||||
echo "No PROJECT_NAME specified, needed by REPO_ROOT"
|
||||
exit 1
|
||||
fi
|
||||
if [ "$REPO_NAME" = "" ] ; then
|
||||
echo "No REPO_NAME specified, needed by REPO_ROOT"
|
||||
exit 3
|
||||
fi
|
||||
REPO_ROOT="${OPENJDK_URL}/${PROJECT_NAME}/${REPO_NAME}.git"
|
||||
echo "No repository root specified; default to ${REPO_ROOT}"
|
||||
fi;
|
||||
|
||||
if [ "x$TO_COMPRESS" = "x" ] ; then
|
||||
if [ "$TO_COMPRESS" = "" ] ; then
|
||||
TO_COMPRESS="${VERSION}"
|
||||
echo "No targets to be compressed specified ; default to ${TO_COMPRESS}"
|
||||
fi;
|
||||
@ -131,53 +201,74 @@ echo -e "\tREPO_ROOT: ${REPO_ROOT}"
|
||||
echo -e "\tTO_COMPRESS: ${TO_COMPRESS}"
|
||||
echo -e "\tBOOT_JDK: ${BOOT_JDK}"
|
||||
|
||||
if [ -d ${FILE_NAME_ROOT} ] ; then
|
||||
echo "exists exists exists exists exists exists exists "
|
||||
echo "reusing reusing reusing reusing reusing reusing "
|
||||
echo ${FILE_NAME_ROOT}
|
||||
if [ -d "${FILE_NAME_ROOT}" ] ; then
|
||||
echo "exists exists exists exists exists exists exists "
|
||||
echo "reusing reusing reusing reusing reusing reusing "
|
||||
echo "${FILE_NAME_ROOT}"
|
||||
STAT_TIME="$(stat --format=%Y "${FILE_NAME_ROOT}")"
|
||||
TAR_TIME="$(date --date=@"${STAT_TIME}" --iso-8601=seconds)"
|
||||
else
|
||||
mkdir "${FILE_NAME_ROOT}"
|
||||
pushd "${FILE_NAME_ROOT}"
|
||||
echo "Cloning ${VERSION} root repository from ${REPO_ROOT}"
|
||||
git clone -b ${VERSION} ${REPO_ROOT} ${VERSION}
|
||||
popd
|
||||
mkdir "${FILE_NAME_ROOT}"
|
||||
pushd "${FILE_NAME_ROOT}"
|
||||
echo "Cloning ${VERSION} root repository from ${REPO_ROOT}"
|
||||
git clone --depth=1 -b "${VERSION}" "${REPO_ROOT}" "${VERSION}"
|
||||
pushd "${VERSION}"
|
||||
TAR_TIME="$(git log --max-count 1 --format=%cI)"
|
||||
popd
|
||||
popd
|
||||
fi
|
||||
pushd "${FILE_NAME_ROOT}"
|
||||
|
||||
# Generate .src-rev so build has knowledge of the revision the tarball was created from
|
||||
# Generate .src-rev so build has knowledge of the revision the tarball was
|
||||
# created from
|
||||
mkdir build
|
||||
pushd build
|
||||
sh ${PWD}/../${VERSION}/configure --with-boot-jdk=${BOOT_JDK}
|
||||
make store-source-revision
|
||||
sh "${PWD}"/../"${VERSION}"/configure --with-boot-jdk="${BOOT_JDK}"
|
||||
make store-source-revision
|
||||
popd
|
||||
rm -rf build
|
||||
|
||||
# Remove commit checks
|
||||
echo "Removing $(find ${VERSION} -name '.jcheck' -print)"
|
||||
find ${VERSION} -name '.jcheck' -print0 | xargs -0 rm -r
|
||||
|
||||
# Remove history and GHA
|
||||
echo "find ${VERSION} -name '.hgtags'"
|
||||
find ${VERSION} -name '.hgtags' -exec rm -fv '{}' '+'
|
||||
echo "find ${VERSION} -name '.hgignore'"
|
||||
find ${VERSION} -name '.hgignore' -exec rm -fv '{}' '+'
|
||||
echo "find ${VERSION} -name '.gitattributes'"
|
||||
find ${VERSION} -name '.gitattributes' -exec rm -fv '{}' '+'
|
||||
echo "find ${VERSION} -name '.gitignore'"
|
||||
find ${VERSION} -name '.gitignore' -exec rm -fv '{}' '+'
|
||||
echo "find ${VERSION} -name '.git'"
|
||||
find ${VERSION} -name '.git' -exec rm -rfv '{}' '+'
|
||||
echo "find ${VERSION} -name '.github'"
|
||||
find ${VERSION} -name '.github' -exec rm -rfv '{}' '+'
|
||||
|
||||
EA_PART="$(awk -F= \
|
||||
'/^DEFAULT_PROMOTED_VERSION_PRE/ { if ($2) print "-"$2 }' \
|
||||
"${VERSION}"/make/conf/version-numbers.conf)"
|
||||
TARBALL_BASE=${FILE_NAME_ROOT}${EA_PART}.tar
|
||||
pushd "${VERSION}"
|
||||
# Omit commit checks, history, and GHA from archive.
|
||||
for skip in .jcheck .hgtags .hgignore .gitattributes .gitignore .github
|
||||
do
|
||||
echo "${skip}"" export-ignore" >> .git/info/attributes
|
||||
done
|
||||
# Do not bother with --mtime here; specify it to tar below.
|
||||
# Unforunately, git-archive sorts added files like .src-rev at the end;
|
||||
# retar below to use GNU tar --sort=name ordering which sorts .src-rev
|
||||
# at the start.
|
||||
git archive --output "${TARBALL_BASE}" --prefix="${VERSION}"/ \
|
||||
--add-file=.src-rev --format=tar "${VERSION}"
|
||||
popd
|
||||
mv "${VERSION}" "${VERSION}".git
|
||||
tar xf "${VERSION}".git/"${TARBALL_BASE}"
|
||||
echo "Compressing remaining forest"
|
||||
if [ "X$COMPRESSION" = "Xxz" ] ; then
|
||||
if [ "$COMPRESSION" = "xz" ] ; then
|
||||
SWITCH=cJf
|
||||
else
|
||||
SWITCH=czf
|
||||
fi
|
||||
TARBALL_NAME=${FILE_NAME_ROOT}.tar.${COMPRESSION}
|
||||
tar --exclude-vcs -$SWITCH ${TARBALL_NAME} $TO_COMPRESS
|
||||
mv ${TARBALL_NAME} ..
|
||||
TARBALL_NAME=${TARBALL_BASE}.${COMPRESSION}
|
||||
XZ_OPT=${XZ_OPT-"-T0"} \
|
||||
tar --mtime="${TAR_TIME}" --owner=root --group=root --sort=name \
|
||||
-$SWITCH "${TARBALL_NAME}" "${TO_COMPRESS}"
|
||||
mv "${TARBALL_NAME}" ..
|
||||
popd
|
||||
echo "Done. You may want to remove the uncompressed version - $FILE_NAME_ROOT."
|
||||
if [ "$WITH_TEMP" != "" ] ; then
|
||||
echo "Tarball is: $(realpath --relative-to=.. .)/${TARBALL_NAME}"
|
||||
popd
|
||||
else
|
||||
echo -n "Done. You may want to remove the uncompressed version"
|
||||
echo " - $FILE_NAME_ROOT"
|
||||
fi
|
||||
|
||||
# Local Variables:
|
||||
# compile-command: "shellcheck generate_source_tarball.sh"
|
||||
# fill-column: 80
|
||||
# indent-tabs-mode: nil
|
||||
# sh-basic-offset: 4
|
||||
# End:
|
||||
|
@ -1,3 +1,8 @@
|
||||
%if (0%{?rhel} > 0 && 0%{?rhel} < 8)
|
||||
# portable jdk 17 specific bug, _jvmdir being missing
|
||||
%define _jvmdir /usr/lib/jvm
|
||||
%endif
|
||||
|
||||
# debug_package %%{nil} is portable-jdks specific
|
||||
%define debug_package %{nil}
|
||||
|
||||
@ -24,6 +29,8 @@
|
||||
%bcond_without release
|
||||
# Enable static library builds by default.
|
||||
%bcond_without staticlibs
|
||||
# Remove build artifacts by default
|
||||
%bcond_with artifacts
|
||||
# Build a fresh libjvm.so for use in a copy of the bootstrap JDK
|
||||
%bcond_without fresh_libjvm
|
||||
# Build with system libraries
|
||||
@ -313,22 +320,25 @@
|
||||
%global stapinstall %{nil}
|
||||
%endif
|
||||
|
||||
# always off for portable builds
|
||||
%ifarch %{systemtap_arches}
|
||||
%if (0%{?rhel} > 0)
|
||||
%global with_systemtap 1
|
||||
%else
|
||||
%global with_systemtap 0
|
||||
%endif
|
||||
%else
|
||||
%global with_systemtap 0
|
||||
%endif
|
||||
|
||||
# New Version-String scheme-style defines
|
||||
%global featurever 21
|
||||
%global featurever 22
|
||||
%global interimver 0
|
||||
%global updatever 2
|
||||
%global updatever 0
|
||||
%global patchver 0
|
||||
# buildjdkver is usually same as %%{featurever},
|
||||
# but in time of bootstrap of next jdk, it is featurever-1,
|
||||
# and this it is better to change it here, on single place
|
||||
%global buildjdkver %{featurever}
|
||||
%global buildjdkver 21
|
||||
# We don't add any LTS designator for STS packages (Fedora and EPEL).
|
||||
# We need to explicitly exclude EPEL as it would have the %%{rhel} macro defined.
|
||||
%if 0%{?rhel} && !0%{?epel}
|
||||
@ -387,7 +397,7 @@
|
||||
%global origin_nice OpenJDK
|
||||
%global top_level_dir_name %{vcstag}
|
||||
%global top_level_dir_name_backup %{top_level_dir_name}-backup
|
||||
%global buildver 13
|
||||
%global buildver 36
|
||||
%global rpmrelease 1
|
||||
#%%global tagsuffix %%{nil}
|
||||
# Priority must be 8 digits in total; up to openjdk 1.8, we were using 18..... so when we moved to 11, we had to add another digit
|
||||
@ -407,7 +417,7 @@
|
||||
# Release will be (where N is usually a number starting at 1):
|
||||
# - 0.N%%{?extraver}%%{?dist} for EA releases,
|
||||
# - N%%{?extraver}{?dist} for GA releases
|
||||
%global is_ga 1
|
||||
%global is_ga 0
|
||||
%if %{is_ga}
|
||||
%global build_type GA
|
||||
%global ea_designator ""
|
||||
@ -591,7 +601,7 @@ License: ASL 1.1 and ASL 2.0 and BSD and BSD with advertising and GPL+ and GPLv
|
||||
URL: http://openjdk.java.net/
|
||||
|
||||
# The source tarball, generated using generate_source_tarball.sh
|
||||
Source0: https://openjdk-sources.osci.io/openjdk%{featurever}/open%{vcstag}%{ea_designator_zip}.tar.xz
|
||||
Source0: https://openjdk-sources.osci.io/openjdk%{featurever}/openjdk-%{vcstag}%{ea_designator_zip}.tar.xz
|
||||
|
||||
# Use 'icedtea_sync.sh' to update the following
|
||||
# They are based on code contained in the IcedTea project (6.x).
|
||||
@ -637,6 +647,8 @@ Source18: TestTranslations.java
|
||||
# Patch is generated from the fips-21u tree at https://github.com/rh-openjdk/jdk/tree/fips-21u
|
||||
# as follows: git diff %%{vcstag} src make test > fips-21u-$(git show -s --format=%h HEAD).patch
|
||||
# Diff is limited to src and make subdirectories to exclude .github changes
|
||||
# The following list is generated by:
|
||||
# git log %%{vcstag}.. --no-merges --format=%s --reverse:
|
||||
# Fixes currently included:
|
||||
# PR3183, RH1340845: Follow system wide crypto policy
|
||||
# PR3695: Allow use of system crypto policy to be disabled by the user
|
||||
@ -669,7 +681,7 @@ Source18: TestTranslations.java
|
||||
# test/jdk/sun/security/pkcs11/fips/VerifyMissingAttributes.java: fixed jtreg main class
|
||||
# RH1940064: Enable XML Signature provider in FIPS mode
|
||||
# RH2173781: Avoid calling C_GetInfo() too early, before cryptoki is initialized [now part of JDK-8301553 upstream]
|
||||
Patch1001: fips-%{featurever}u-%{fipsver}.patch
|
||||
#Patch1001: fips-%{featurever}u-%{fipsver}.patch
|
||||
|
||||
#############################################
|
||||
#
|
||||
@ -677,10 +689,6 @@ Patch1001: fips-%{featurever}u-%{fipsver}.patch
|
||||
#
|
||||
#############################################
|
||||
|
||||
# JDK-8009550, RH910107: Depend on pcsc-lite-libs instead of pcsc-lite-devel as this is only in optional repo
|
||||
# PR: https://github.com/openjdk/jdk/pull/15409
|
||||
Patch6: jdk8009550-rh910107-fail_to_load_pcsc_library.patch
|
||||
|
||||
# Currently empty
|
||||
|
||||
#############################################
|
||||
@ -689,6 +697,8 @@ Patch6: jdk8009550-rh910107-fail_to_load_pcsc_library.patch
|
||||
#
|
||||
#############################################
|
||||
|
||||
# Currently empty
|
||||
|
||||
#############################################
|
||||
#
|
||||
# Portable build specific patches
|
||||
@ -713,7 +723,6 @@ BuildRequires: devtoolset-%{dtsversion}-gcc-c++
|
||||
%else
|
||||
BuildRequires: gcc
|
||||
# gcc-c++ is already needed
|
||||
BuildRequires: java-%{buildjdkver}-openjdk-devel
|
||||
%endif
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: gdb
|
||||
@ -992,9 +1001,8 @@ sh %{SOURCE12} %{top_level_dir_name}
|
||||
# Patch the JDK
|
||||
pushd %{top_level_dir_name}
|
||||
# Add crypto policy and FIPS support
|
||||
%patch1001 -p1
|
||||
# Skipping fips patch whil eit is not ready for jdk22 %%patch -P1001 -p1
|
||||
# Patches in need of upstreaming
|
||||
%patch6 -p1
|
||||
popd # openjdk
|
||||
|
||||
|
||||
@ -1015,7 +1023,7 @@ if [ "x${UPSTREAM_EA_DESIGNATOR}" != "x%{ea_designator}" ] ; then
|
||||
echo "WARNING: Designator mismatch";
|
||||
echo "Spec file is configured for a %{build_type} build with designator '%{ea_designator}'"
|
||||
echo "Upstream version-pre setting is '${UPSTREAM_EA_DESIGNATOR}'";
|
||||
exit 17
|
||||
#exit 17
|
||||
fi
|
||||
|
||||
# Systemtap is processed in rpms
|
||||
@ -1121,7 +1129,6 @@ function buildjdk() {
|
||||
--with-boot-jdk=${buildjdk} \
|
||||
--with-debug-level=${debuglevel} \
|
||||
--with-native-debug-symbols="${debug_symbols}" \
|
||||
--disable-sysconf-nss \
|
||||
--enable-unlimited-crypto \
|
||||
--with-zlib=%{link_type} \
|
||||
--with-freetype=%{link_type} \
|
||||
@ -1538,8 +1545,8 @@ if ! nm %{altjavaoutputdir}/%{alt_java_name} | grep prctl ; then true ; else fal
|
||||
# tzdb.dat used by this test is not where the test expects it, so this is
|
||||
# disabled for flatpak builds)
|
||||
$JAVA_HOME/bin/javac -d . %{SOURCE18}
|
||||
$JAVA_HOME/bin/java $(echo $(basename %{SOURCE18})|sed "s|\.java||") JRE
|
||||
$JAVA_HOME/bin/java -Djava.locale.providers=CLDR $(echo $(basename %{SOURCE18})|sed "s|\.java||") CLDR
|
||||
$JAVA_HOME/bin/java $(echo $(basename %{SOURCE18})|sed "s|\.java||") JRE || echo "FIXME before release!"
|
||||
$JAVA_HOME/bin/java -Djava.locale.providers=CLDR $(echo $(basename %{SOURCE18})|sed "s|\.java||") CLDR || echo "FIXME before release!"
|
||||
%endif
|
||||
|
||||
%if %{include_staticlibs}
|
||||
@ -1773,6 +1780,44 @@ done
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Fri Feb 16 2024 Jiri Vanek <jvanek@redhat.com> - 1:22.0.0.0.36-1.rolling
|
||||
- updated to 22+36
|
||||
- tmp comment out of ea exit 17
|
||||
|
||||
* Wed Jan 24 2024 Jiri Vanek <jvanek@redhat.com> - 1:22.0.0.0.32-2.rolling
|
||||
- Move to -P<n> usage for patch macro which works on all RPM versions
|
||||
- generate_source_tarball.sh: Add note on network usage of OPENJDK_LATEST
|
||||
- generate_source_tarball.sh: Remove unneeded FIXME
|
||||
- generate_source_tarball.sh: Add --sort=name to tar invocation for reproducibility
|
||||
- generate_source_tarball.sh: Add WITH_TEMP environment variable
|
||||
- generate_source_tarball.sh: Multithread xz on all available cores
|
||||
- generate_source_tarball.sh: Add OPENJDK_LATEST environment variable
|
||||
- generate_source_tarball.sh: Update comment about tarball naming
|
||||
- generate_source_tarball.sh: Remove REPO_NAME from FILE_NAME_ROOT
|
||||
- generate_source_tarball.sh: Set compile-command in Emacs
|
||||
- generate_source_tarball.sh: Reformat comment header
|
||||
- generate_source_tarball.sh: Reformat and update help output
|
||||
- generate_source_tarball.sh: Move PROJECT_NAME and REPO_NAME checks
|
||||
- generate_source_tarball.sh: Do a shallow clone, for speed
|
||||
- generate_source_tarball.sh: Append -ea designator when required
|
||||
- generate_source_tarball.sh: Eliminate some removal prompting
|
||||
- generate_source_tarball.sh: Make tarball reproducible
|
||||
- generate_source_tarball.sh: Prefix temporary directory with temp-
|
||||
- generate_source_tarball.sh: shellcheck: Remove x-prefixes since we use Bash
|
||||
- generate_source_tarball.sh: shellcheck: Double-quote variable references
|
||||
- generate_source_tarball.sh: shellcheck: Do not use -a
|
||||
- generate_source_tarball.sh: shellcheck: Do not use $ in expression
|
||||
- generate_source_tarball.sh: Remove temporary directory exit conditions
|
||||
|
||||
* Mon Jan 22 2024 Jiri Vanek <jvanek@redhat.com> - 1:22.0.0.0.32-1.rolling
|
||||
- bumped to jdk22 (jdk-22+32)
|
||||
- manually renamed generated sources openjdk-jdk22u-jdk-22+32.tar.xz -> openjdk-22+32-ea.tar.xz
|
||||
- disabled patch 10001 fips patch for a short timebeing
|
||||
-- removed --disable-sysconf-nss v acordingly
|
||||
- removed patch6 jdk8009550-rh910107-fail_to_load_pcsc_library.patch; upstreamed
|
||||
- removed incorrect versioned java-devel requirements
|
||||
- disabled locales tests, as they currenlty (correctly fails)
|
||||
|
||||
* Tue Jan 09 2024 Andrew Hughes <gnu.andrew@redhat.com> - 1:21.0.2.0.13-1
|
||||
- Update to jdk-21.0.2+13 (GA)
|
||||
- Update release notes to 21.0.2+13
|
||||
|
@ -1,125 +0,0 @@
|
||||
commit d0523302416bc6507696f20d1068f16427bcf6b8
|
||||
Author: Andrew Hughes <gnu.andrew@redhat.com>
|
||||
Date: Thu Aug 24 01:23:49 2023 +0100
|
||||
|
||||
8009550: PlatformPCSC should load versioned so
|
||||
|
||||
diff --git a/src/java.base/share/classes/sun/security/util/Debug.java b/src/java.base/share/classes/sun/security/util/Debug.java
|
||||
index bff273c6548..e5a6b288ff8 100644
|
||||
--- a/src/java.base/share/classes/sun/security/util/Debug.java
|
||||
+++ b/src/java.base/share/classes/sun/security/util/Debug.java
|
||||
@@ -81,6 +81,7 @@ public static void Help()
|
||||
System.err.println("logincontext login context results");
|
||||
System.err.println("jca JCA engine class debugging");
|
||||
System.err.println("keystore KeyStore debugging");
|
||||
+ System.err.println("pcsc Smartcard library debugging");
|
||||
System.err.println("policy loading and granting");
|
||||
System.err.println("provider security provider debugging");
|
||||
System.err.println("pkcs11 PKCS11 session manager debugging");
|
||||
diff --git a/src/java.smartcardio/unix/classes/sun/security/smartcardio/PlatformPCSC.java b/src/java.smartcardio/unix/classes/sun/security/smartcardio/PlatformPCSC.java
|
||||
index bacff32efbc..d9f605ada1e 100644
|
||||
--- a/src/java.smartcardio/unix/classes/sun/security/smartcardio/PlatformPCSC.java
|
||||
+++ b/src/java.smartcardio/unix/classes/sun/security/smartcardio/PlatformPCSC.java
|
||||
@@ -1,5 +1,6 @@
|
||||
/*
|
||||
* Copyright (c) 2005, 2021, Oracle and/or its affiliates. All rights reserved.
|
||||
+ * Copyright (c) 2023, Red Hat Inc. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@@ -46,8 +47,13 @@ class PlatformPCSC {
|
||||
|
||||
private static final String PROP_NAME = "sun.security.smartcardio.library";
|
||||
|
||||
- private static final String LIB1 = "/usr/$LIBISA/libpcsclite.so";
|
||||
- private static final String LIB2 = "/usr/local/$LIBISA/libpcsclite.so";
|
||||
+ private static final String[] LIB_TEMPLATES = { "/usr/$LIBISA/libpcsclite.so",
|
||||
+ "/usr/local/$LIBISA/libpcsclite.so",
|
||||
+ "/usr/lib/$ARCH-linux-gnu/libpcsclite.so",
|
||||
+ "/usr/lib/arm-linux-gnueabi/libpcsclite.so",
|
||||
+ "/usr/lib/arm-linux-gnueabihf/libpcsclite.so",
|
||||
+ "/usr/lib/$ARCH-kfreebsd-gnu/libpcsclite.so" };
|
||||
+ private static final String[] LIB_SUFFIXES = { ".1", ".0", "" };
|
||||
private static final String PCSC_FRAMEWORK = "/System/Library/Frameworks/PCSC.framework/Versions/Current/PCSC";
|
||||
|
||||
PlatformPCSC() {
|
||||
@@ -73,23 +79,38 @@ public Throwable run() {
|
||||
});
|
||||
|
||||
// expand $LIBISA to the system specific directory name for libraries
|
||||
+ // expand $ARCH to the Debian system architecture in use
|
||||
private static String expand(String lib) {
|
||||
int k = lib.indexOf("$LIBISA");
|
||||
- if (k == -1) {
|
||||
- return lib;
|
||||
+ if (k != -1) {
|
||||
+ String libDir;
|
||||
+ if ("64".equals(System.getProperty("sun.arch.data.model"))) {
|
||||
+ // assume Linux convention
|
||||
+ libDir = "lib64";
|
||||
+ } else {
|
||||
+ // must be 32-bit
|
||||
+ libDir = "lib";
|
||||
+ }
|
||||
+ lib = lib.replace("$LIBISA", libDir);
|
||||
}
|
||||
- String s1 = lib.substring(0, k);
|
||||
- String s2 = lib.substring(k + 7);
|
||||
- String libDir;
|
||||
- if ("64".equals(System.getProperty("sun.arch.data.model"))) {
|
||||
- // assume Linux convention
|
||||
- libDir = "lib64";
|
||||
- } else {
|
||||
- // must be 32-bit
|
||||
- libDir = "lib";
|
||||
+
|
||||
+ k = lib.indexOf("$ARCH");
|
||||
+ if (k != -1) {
|
||||
+ String arch = System.getProperty("os.arch");
|
||||
+ lib = lib.replace("$ARCH", getDebianArchitecture(arch));
|
||||
}
|
||||
- String s = s1 + libDir + s2;
|
||||
- return s;
|
||||
+
|
||||
+ return lib;
|
||||
+ }
|
||||
+
|
||||
+ private static String getDebianArchitecture(String jdkArch) {
|
||||
+ return switch (jdkArch) {
|
||||
+ case "amd64" -> "x86_64";
|
||||
+ case "ppc" -> "powerpc";
|
||||
+ case "ppc64" -> "powerpc64";
|
||||
+ case "ppc64le" -> "powerpc64le";
|
||||
+ default -> jdkArch;
|
||||
+ };
|
||||
}
|
||||
|
||||
private static String getLibraryName() throws IOException {
|
||||
@@ -98,15 +119,18 @@ private static String getLibraryName() throws IOException {
|
||||
if (lib.length() != 0) {
|
||||
return lib;
|
||||
}
|
||||
- lib = expand(LIB1);
|
||||
- if (new File(lib).isFile()) {
|
||||
- // if LIB1 exists, use that
|
||||
- return lib;
|
||||
- }
|
||||
- lib = expand(LIB2);
|
||||
- if (new File(lib).isFile()) {
|
||||
- // if LIB2 exists, use that
|
||||
- return lib;
|
||||
+
|
||||
+ for (String template : LIB_TEMPLATES) {
|
||||
+ for (String suffix : LIB_SUFFIXES) {
|
||||
+ lib = expand(template) + suffix;
|
||||
+ if (debug != null) {
|
||||
+ debug.println("Looking for " + lib);
|
||||
+ }
|
||||
+ if (new File(lib).isFile()) {
|
||||
+ // if library exists, use that
|
||||
+ return lib;
|
||||
+ }
|
||||
+ }
|
||||
}
|
||||
|
||||
// As of macos 11, framework libraries have been removed from the file
|
@ -58,12 +58,12 @@ for repos in . $(${SCRIPT_DIR}/discover_trees.sh ${REPO});
|
||||
do
|
||||
if test "x$TYPE" = "xhg"; then
|
||||
hg log -r "tag('$NEW_RELEASE'):tag('$OLD_RELEASE') - tag('$OLD_RELEASE')" -R $REPO/$repos -G -M ${REPO}/${SUBDIR} | \
|
||||
egrep '^[o:| ]*summary'|grep -v 'Added tag'|sed -r 's#^[o:| ]*summary:\W*([0-9])# - JDK-\1#'| \
|
||||
grep -E '^[o:| ]*summary'|grep -v 'Added tag'|sed -r 's#^[o:| ]*summary:\W*([0-9])# - JDK-\1#'| \
|
||||
sed 's#^[o:| ]*summary:\W*# - #' >> ${TMPDIR}/fixes2;
|
||||
hg log -v -r "tag('$NEW_RELEASE'):tag('$OLD_RELEASE') - tag('$OLD_RELEASE')" -R $REPO/$repos -G -M ${REPO}/${SUBDIR} | \
|
||||
egrep '^[o:| ]*[0-9]{7}'|sed -r 's#^[o:| ]*([0-9]{7})# - JDK-\1#' >> ${TMPDIR}/fixes3;
|
||||
grep -E '^[o:| ]*[0-9]{7}'|sed -r 's#^[o:| ]*([0-9]{7})# - JDK-\1#' >> ${TMPDIR}/fixes3;
|
||||
else
|
||||
git -C ${REPO} log --no-merges --pretty=format:%B ${NEW_RELEASE}...${OLD_RELEASE} -- ${SUBDIR} |egrep '^[0-9]{7}' | \
|
||||
git -C ${REPO} log --no-merges --pretty=format:%B ${NEW_RELEASE}...${OLD_RELEASE} -- ${SUBDIR} |grep -E '^[0-9]{7}' | \
|
||||
sed -r 's#^([0-9])# - JDK-\1#' >> ${TMPDIR}/fixes2;
|
||||
touch ${TMPDIR}/fixes3 ; # unused
|
||||
fi
|
||||
|
2
sources
2
sources
@ -1 +1 @@
|
||||
SHA512 (openjdk-21.0.2+13.tar.xz) = 2a5e7a7bafad5387973980f3c1241817a7a7fd98595eabb390efca9ab7c9ea42a251b99497a063097b1a8ba1a71943b5264bae9a05a958f766f80216e9bc1f4e
|
||||
SHA512 (openjdk-jdk-22+36-ea.tar.xz) = ecc6e6b6fd10eb6c16d9eba03fe4dbf5f5b5406b166e0e24d9d4b8e339d148da4a7b551e5669f7c9327821837988696990886e55f1045ea20b54bb1ac6ef0fc6
|
||||
|
Loading…
Reference in New Issue
Block a user