[java-1.8.0-openjdk/f21] policies repacked to stop spamming yum update, added mehanism to force priority size
jiri vanek
jvanek at fedoraproject.org
Thu Feb 12 16:23:41 UTC 2015
commit ae70e5d64fbe2fb042c0cee088316b39ee8bf8c9
Author: Jiri Vanek <jvanek at redhat.com>
Date: Thu Feb 12 17:23:10 2015 +0100
policies repacked to stop spamming yum update, added mehanism to force priority size
java-1.8.0-openjdk.spec | 18 ++++++++++++++++--
repackReproduciblePolycies.sh | 33 +++++++++++++++++++++++++++++++++
2 files changed, 49 insertions(+), 2 deletions(-)
---
diff --git a/java-1.8.0-openjdk.spec b/java-1.8.0-openjdk.spec
index 07bd7b8..e2f5d87 100644
--- a/java-1.8.0-openjdk.spec
+++ b/java-1.8.0-openjdk.spec
@@ -86,7 +86,7 @@
%global aarch64_updatever 40
%global aarch64_buildver b12
%global aarch64_changesetid aarch64-hs3135441ed942
-# priority must be 6 digits in total
+# priority must be 7 digits in total
%global priority 18000%{updatever}
%global javaver 1.8.0
@@ -123,7 +123,7 @@
Name: java-%{javaver}-%{origin}
Version: %{javaver}.%{updatever}
-Release: 3.%{buildver}%{?dist}
+Release: 4.%{buildver}%{?dist}
# java-1.5.0-ibm from jpackage.org set Epoch to 1 for unknown reasons,
# and this change was brought into RHEL-4. java-1.5.0-ibm packages
# also included the epoch in their virtual provides. This created a
@@ -168,6 +168,8 @@ Source12: remove-intree-libraries.sh
# Ensure we aren't using the limited crypto policy
Source13: TestCryptoLevel.java
+Source20: repackReproduciblePolycies.sh
+
# New versions of config files with aarch64 support. This is not upstream yet.
Source100: config.guess
Source101: config.sub
@@ -422,6 +424,11 @@ need to.
%prep
%setup -q -c -n %{uniquesuffix} -T -a 0
+prioritylength=`expr length %{priority}`
+if [ $prioritylength -ne 7 ] ; then
+ echo "priority must be 7 digits in total, violated"
+ exit 14
+fi
%ifarch %{aarch64}
pushd jdk8
rm -r hotspot
@@ -822,6 +829,8 @@ find $RPM_BUILD_ROOT%{_jvmdir}/%{sdkdir}/demo \
echo "" >> accessibility.properties
popd
+bash %{SOURCE20} $RPM_BUILD_ROOT/%{_jvmdir}/%{jredir} %{javaver}
+
%pretrans headless -p <lua>
-- see https://bugzilla.redhat.com/show_bug.cgi?id=1038092 for whole issue
@@ -1361,6 +1370,11 @@ exit 0
%{_jvmdir}/%{jredir}/lib/accessibility.properties
%changelog
+* Thu Feb 12 2015 Jiri Vanek <jvanek at redhat.com> - 1:1.8.0.25-4.b12
+- policies repacked to stop spamming yum update
+- added and used source20 repackReproduciblePolycies.sh
+- added mehanism to force priority size
+
* Thu Jan 22 2015 Severin Gehwolf <sgehwolf at redhat.com> - 1:1.8.0.31-3.b13
- Check for one additional md5sum in post scriptlet.
diff --git a/repackReproduciblePolycies.sh b/repackReproduciblePolycies.sh
new file mode 100644
index 0000000..12b5ff6
--- /dev/null
+++ b/repackReproduciblePolycies.sh
@@ -0,0 +1,33 @@
+#!/bin/sh
+M=META-INF/MANIFEST.MF
+#P=/usr/lib/jvm/java/jre/lib/security
+P=$1/lib/security
+for f in local_policy.jar US_export_policy.jar ; do
+ORIG=$P/$f
+echo "processing $f ($ORIG)"
+if [ ! -f $ORIG ]; then
+ echo "File not found!"
+ continue
+fi
+d=`mktemp -d`
+NW=$d/$f
+ pushd $d
+ jar xf $ORIG
+ cat $M
+# sed -i "s/Created-By.*/Created-By: 1.7.0/g" $M
+ sed -i "s/Created-By.*/Created-By: $2/g" $M
+ cat $M
+ find . -exec touch -t 201401010000 {} +
+ zip -rX $f *
+ popd
+ echo "replacing $ORIG"
+ md5sum $ORIG
+ sha256sum $ORIG
+ echo "by $NW"
+ md5sum $NW
+ sha256sum $NW
+ cp $NW $ORIG
+ md5sum $ORIG
+ sha256sum $ORIG
+ rm -rfv $d
+done
More information about the scm-commits
mailing list