diff --git a/java-11-openjdk.spec b/java-11-openjdk.spec index 091151e..f0bd701 100644 --- a/java-11-openjdk.spec +++ b/java-11-openjdk.spec @@ -24,6 +24,11 @@ # Workaround for stripping of debug symbols from static libraries %define __brp_strip_static_archive %{nil} +#in rosa linux there is no tzdb.dat file +#in the timezone package we will +#use the standard one from java (temporarily) +%bcond_with timezonejava + # The -g flag says to use strip -g instead of full strip on DSOs or EXEs. # This fixes detailed NMT and other tools which need minimal debug info. # See: https://bugzilla.redhat.com/show_bug.cgi?id=1520879 @@ -904,9 +909,11 @@ Provides: jre%{?1} = %{epoch}:%{version}-%{release} Requires: ca-certificates # Require javapackages-filesystem for ownership of /usr/lib/jvm/ and macros Requires: javapackages-filesystem +%if %{with timezonejava} # Require zone-info data provided by tzdata-java sub-package # 2020a required as of JDK-8243541 in 11.0.8+4 Requires: tzdata-java >= 2020a +%endif # for support of kernel stream control # libsctp.so.1 is being `dlopen`ed on demand Requires: lksctp-tools%{?_isa} @@ -1189,8 +1196,10 @@ BuildRequires: java-%{buildjdkver}-openjdk-devel %ifnarch %{jit_arches} BuildRequires: pkgconfig(libffi) %endif +%if %{with timezonejava} # 2020a required as of JDK-8243541 in 11.0.8+4 BuildRequires: tzdata-java >= 2020a +%endif BuildRequires: gcc %if %{with_systemtap} @@ -1579,9 +1588,11 @@ export JAVA_HOME=$(pwd)/%{buildoutputdir -- $suffix}/images/%{jdkimage} # Install nss.cfg right away as we will be using the JRE above install -m 644 nss.cfg $JAVA_HOME/conf/security/ +%if %{with timezonejava} # Use system-wide tzdata rm $JAVA_HOME/lib/tzdb.dat ln -s %{_datadir}/javazi-1.8/tzdb.dat $JAVA_HOME/lib/tzdb.dat +%endif # build cycles done