Sync with RHEL 7 portable build

- Use ExclusiveArch over ExcludeArch
- pkgos definition needs to be early enough to be used in portablesuffix

- Related: RHEL-58798
This commit is contained in:
Andrew Hughes 2024-08-02 23:05:35 +01:00
parent da7462bf43
commit 9e140b3579

View File

@ -145,11 +145,6 @@
# Architecture on which we run Java only tests # Architecture on which we run Java only tests
%global jdk_test_arch x86_64 %global jdk_test_arch x86_64
# Define the OS the portable JDK is built on
# This is undefined for openjdk-portable-rhel-8 builds and
# equals 'rhel7' for openjdk-portable-rhel-7 builds
%global pkgos rhel7
# By default, we build a debug build during main build on JIT architectures # By default, we build a debug build during main build on JIT architectures
%if %{with slowdebug} %if %{with slowdebug}
%ifarch %{debug_arches} %ifarch %{debug_arches}
@ -358,13 +353,20 @@
# The tag used to create the OpenJDK tarball # The tag used to create the OpenJDK tarball
%global vcstag jdk-%{filever}+%{buildver}%{?tagsuffix:-%{tagsuffix}} %global vcstag jdk-%{filever}+%{buildver}%{?tagsuffix:-%{tagsuffix}}
# Define the OS the portable JDK is built on
# This is undefined for CentOS & openjdk-portable-rhel-8 builds and
# equals 'rhel7' for openjdk-portable-rhel-7 builds
%if 0%{?centos} == 0
%global pkgos rhel7
%endif
# Standard JPackage naming and versioning defines # Standard JPackage naming and versioning defines
%global origin openjdk %global origin openjdk
%global origin_nice OpenJDK %global origin_nice OpenJDK
%global top_level_dir_name %{vcstag} %global top_level_dir_name %{vcstag}
%global top_level_dir_name_backup %{top_level_dir_name}-backup %global top_level_dir_name_backup %{top_level_dir_name}-backup
%global buildver 7 %global buildver 7
%global rpmrelease 2 %global rpmrelease 3
# Settings used by the portable build # Settings used by the portable build
%global portablerelease 1 %global portablerelease 1
# Portable suffix differs between RHEL and CentOS # Portable suffix differs between RHEL and CentOS
@ -1119,9 +1121,6 @@ exit 0
%endif %endif
} }
# x86 is not supported by OpenJDK 17
ExcludeArch: %{ix86}
# not-duplicated requires/provides/obsoletes for normal/debug packages # not-duplicated requires/provides/obsoletes for normal/debug packages
%define java_rpo() %{expand: %define java_rpo() %{expand:
Requires: fontconfig%{?_isa} Requires: fontconfig%{?_isa}
@ -1283,6 +1282,9 @@ Provides: java-%{origin}-src%{?1} = %{epoch}:%{version}-%{release}
# Define the root name of the portable packages # Define the root name of the portable packages
%global pkgnameroot java-%{featurever}-%{origin}-portable%{?pkgos:-%{pkgos}} %global pkgnameroot java-%{featurever}-%{origin}-portable%{?pkgos:-%{pkgos}}
# Define the architectures on which we build
ExclusiveArch: %{aarch64} %{ppc64le} s390x x86_64
Name: java-%{javaver}-%{origin} Name: java-%{javaver}-%{origin}
Version: %{newjavaver}.%{buildver} Version: %{newjavaver}.%{buildver}
Release: %{?eaprefix}%{rpmrelease}%{?extraver}%{?dist} Release: %{?eaprefix}%{rpmrelease}%{?extraver}%{?dist}
@ -2529,10 +2531,13 @@ require "copy_jdk_configs.lua"
%endif %endif
%changelog %changelog
* Mon Oct 07 2024 Andrew Hughes <gnu.andrew@redhat.com> - 1:21.0.4.0.7-2 * Fri Oct 11 2024 Andrew Hughes <gnu.andrew@redhat.com> - 1:21.0.4.0.7-3
- Vary portablesuffix depending on whether we are on RHEL ('el8') or CentOS ('el9') - Vary portablesuffix depending on whether we are on RHEL ('el8') or CentOS ('el9')
- Handle debugedit being a separate package installed in /usr on RHEL/CentOS 10 - Handle debugedit being a separate package installed in /usr on RHEL/CentOS 10
- Add build scripts to repository to ease remembering all CentOS & RHEL targets and options - Add build scripts to repository to ease remembering all CentOS & RHEL targets and options
- Sync with RHEL 7 portable build:
- Use ExclusiveArch over ExcludeArch
- pkgos definition needs to be early enough to be used in portablesuffix
- Related: RHEL-58798 - Related: RHEL-58798
* Fri Jul 12 2024 Andrew Hughes <gnu.andrew@redhat.com> - 1:21.0.4.0.7-1 * Fri Jul 12 2024 Andrew Hughes <gnu.andrew@redhat.com> - 1:21.0.4.0.7-1