Add static-libs sub-package
This is useful for producing an OpenJDK-based Graal VM build
This commit is contained in:
parent
688f57ed81
commit
1d75746a8b
@ -121,12 +121,12 @@
|
||||
%endif
|
||||
|
||||
%if %{bootstrap_build}
|
||||
%global release_targets bootcycle-images docs-zip
|
||||
%global release_targets bootcycle-images static-libs-image docs-zip
|
||||
%else
|
||||
%global release_targets images docs-zip
|
||||
%global release_targets images docs-zip static-libs-image
|
||||
%endif
|
||||
# No docs nor bootcycle for debug builds
|
||||
%global debug_targets images
|
||||
%global debug_targets images static-libs-image
|
||||
|
||||
|
||||
# Filter out flags from the optflags macro that cause problems with the OpenJDK build
|
||||
@ -226,7 +226,7 @@
|
||||
%global top_level_dir_name %{origin}
|
||||
%global minorver 0
|
||||
%global buildver 3
|
||||
%global rpmrelease 0
|
||||
%global rpmrelease 1
|
||||
#%%global tagsuffix ""
|
||||
# priority must be 8 digits in total; untill openjdk 1.8 we were using 18..... so when moving to 11 we had to add another digit
|
||||
%if %is_system_jdk
|
||||
@ -259,8 +259,9 @@
|
||||
# parametrized macros are order-sensitive
|
||||
%global compatiblename java-%{majorver}-%{origin}
|
||||
%global fullversion %{compatiblename}-%{version}-%{release}
|
||||
# images stub
|
||||
%global jdkimage jdk
|
||||
# images directories from upstream build
|
||||
%global jdkimage jdk
|
||||
%global static_libs_image static-libs
|
||||
# output dir stub
|
||||
%define buildoutputdir() %{expand:openjdk/build%{?1}}
|
||||
# we can copy the javadoc to not arched dir, or make it not noarch
|
||||
@ -806,6 +807,25 @@ exit 0
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/src.zip
|
||||
}
|
||||
|
||||
%define files_static_libs() %{expand:
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libj2pkcs11.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libj2pcsc.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libnio.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libprefs.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libjava.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libjli.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libnet.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libjimage.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libjaas.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libfdlibm.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libj2gss.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libsunec.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libjsig.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libextnet.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libverify.a
|
||||
%{_jvmdir}/%{sdkdir -- %{?1}}/lib/libzip.a
|
||||
}
|
||||
|
||||
%define files_javadoc() %{expand:
|
||||
%doc %{_javadocdir}/%{uniquejavadocdir -- %{?1}}
|
||||
%license %{buildoutputdir -- %{?1}}/images/%{jdkimage}/legal
|
||||
@ -911,6 +931,11 @@ Provides: java-sdk%{?1} = %{epoch}:%{version}-%{release}
|
||||
%endif
|
||||
}
|
||||
|
||||
%define java_static_libs_rpo() %{expand:
|
||||
Requires: %{name}-devel%{?1}%{?_isa} = %{epoch}:%{version}-%{release}
|
||||
OrderWithRequires: %{name}-headless%{?1}%{?_isa} = %{epoch}:%{version}-%{release}
|
||||
}
|
||||
|
||||
%define java_jmods_rpo() %{expand:
|
||||
# Requires devel package
|
||||
# as jmods are bytecode, they should be OK without any _isa
|
||||
@ -1183,6 +1208,27 @@ The %{origin_nice} development tools %{majorver}.
|
||||
%{debug_warning}
|
||||
%endif
|
||||
|
||||
%if %{include_normal_build}
|
||||
%package static-libs
|
||||
Summary: %{origin_nice} libraries for static linking %{majorver}
|
||||
|
||||
%{java_static_libs_rpo %{nil}}
|
||||
|
||||
%description static-libs
|
||||
The %{origin_nice} libraries for static linking %{majorver}.
|
||||
%endif
|
||||
|
||||
%if %{include_debug_build}
|
||||
%package static-libs-slowdebug
|
||||
Summary: %{origin_nice} libraries for static linking %{majorver} %{debug_on}
|
||||
|
||||
%{java_static_libs_rpo -- %{debug_suffix_unquoted}}
|
||||
|
||||
%description static-libs-slowdebug
|
||||
The %{origin_nice} libraries for static linking %{majorver}.
|
||||
%{debug_warning}
|
||||
%endif
|
||||
|
||||
%if %{include_normal_build}
|
||||
%package jmods
|
||||
Summary: JMods for %{origin_nice} %{majorver}
|
||||
@ -1634,6 +1680,9 @@ pushd %{buildoutputdir $suffix}/images/%{jdkimage}
|
||||
rm -rf $RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir -- $suffix}/man
|
||||
|
||||
popd
|
||||
# Install static libs artefacts
|
||||
cp -a %{buildoutputdir -- $suffix}/images/%{static_libs_image}/lib/*.a \
|
||||
$RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir -- $suffix}/lib
|
||||
|
||||
|
||||
if ! echo $suffix | grep -q "debug" ; then
|
||||
@ -1811,6 +1860,9 @@ require "copy_jdk_configs.lua"
|
||||
%files devel
|
||||
%{files_devel %{nil}}
|
||||
|
||||
%files static-libs
|
||||
%{files_static_libs %{nil}}
|
||||
|
||||
%files jmods
|
||||
%{files_jmods %{nil}}
|
||||
|
||||
@ -1841,6 +1893,9 @@ require "copy_jdk_configs.lua"
|
||||
%files devel-slowdebug
|
||||
%{files_devel -- %{debug_suffix_unquoted}}
|
||||
|
||||
%files static-libs-slowdebug
|
||||
%{files_static_libs -- %{debug_suffix_unquoted}}
|
||||
|
||||
%files jmods-slowdebug
|
||||
%{files_jmods -- %{debug_suffix_unquoted}}
|
||||
|
||||
@ -1853,6 +1908,10 @@ require "copy_jdk_configs.lua"
|
||||
|
||||
|
||||
%changelog
|
||||
* Fri May 22 2020 Severin Gehwolf <sgehwolf@redhat.com> - 1:11.0.8.3-0.1.ea
|
||||
- Build static-libs-image and add resulting files via -static-libs
|
||||
sub-package.
|
||||
|
||||
* Tue May 19 2020 Andrew Hughes <gnu.andrew@redhat.com> - 1:11.0.8.3-0.0.ea
|
||||
- Update to shenandoah-jdk-11.0.8+3 (EA)
|
||||
- Drop JDK-8233880 backport now applied upstream.
|
||||
|
Loading…
Reference in New Issue
Block a user