Browse Source

redhat-rpm-config package update

Signed-off-by: basebuilder_pel7x64builder0 <basebuilder@powerel.org>
master
basebuilder_pel7x64builder0 6 years ago
parent
commit
8d238df042
  1. 44
      SOURCES/0001-Drop-un-setting-LANG-and-DISPLAY-in-various-build-st.patch
  2. 1558
      SOURCES/config.guess
  3. 1791
      SOURCES/config.sub
  4. 2
      SOURCES/kabi.attr
  5. 13
      SOURCES/kabi.sh
  6. 135
      SOURCES/libtool-handle-ppc64le.sh
  7. 2
      SOURCES/redhat-hardened-cc1
  8. 5
      SOURCES/redhat-hardened-ld
  9. 11
      SOURCES/redhat-rpm-config-9.0.3-latest-kernel.patch
  10. 11
      SOURCES/redhat-rpm-config-9.0.3-shebang.patch
  11. 25
      SOURCES/redhat-rpm-config-9.1.0-Add-_pkgdocdir.patch
  12. 44
      SOURCES/redhat-rpm-config-9.1.0-Fix-stripping-of-binaries.patch
  13. 13
      SOURCES/redhat-rpm-config-9.1.0-aarch64.patch
  14. 51
      SOURCES/redhat-rpm-config-9.1.0-arches-macros.patch
  15. 27
      SOURCES/redhat-rpm-config-9.1.0-arm.patch
  16. 12
      SOURCES/redhat-rpm-config-9.1.0-centos.dist.patch
  17. 147
      SOURCES/redhat-rpm-config-9.1.0-compressed-kmods-support.patch
  18. 13
      SOURCES/redhat-rpm-config-9.1.0-configfoo.patch
  19. 42
      SOURCES/redhat-rpm-config-9.1.0-dwz.patch
  20. 11
      SOURCES/redhat-rpm-config-9.1.0-fcflags.patch
  21. 13
      SOURCES/redhat-rpm-config-9.1.0-filtering-spaces-in-filename.patch
  22. 15
      SOURCES/redhat-rpm-config-9.1.0-find-provides.libtool.patch
  23. 14
      SOURCES/redhat-rpm-config-9.1.0-find-requires-fix-detection.patch
  24. 32
      SOURCES/redhat-rpm-config-9.1.0-fix-depmod-path.patch
  25. 11
      SOURCES/redhat-rpm-config-9.1.0-fix-find-provides-modalias-permissions.patch
  26. 11
      SOURCES/redhat-rpm-config-9.1.0-fix-group-owners-in-jars.patch
  27. 12
      SOURCES/redhat-rpm-config-9.1.0-fix-kabi-path.patch
  28. 86
      SOURCES/redhat-rpm-config-9.1.0-fix-ksym-requires-generation.patch
  29. 30
      SOURCES/redhat-rpm-config-9.1.0-fix-requires.patch
  30. 21
      SOURCES/redhat-rpm-config-9.1.0-hardened.patch
  31. 14
      SOURCES/redhat-rpm-config-9.1.0-jar-repack-perms.patch
  32. 16
      SOURCES/redhat-rpm-config-9.1.0-java-repack-order.patch
  33. 64
      SOURCES/redhat-rpm-config-9.1.0-java-repack-spaces-in-filenames.patch
  34. 13
      SOURCES/redhat-rpm-config-9.1.0-kernel-source.patch
  35. 99
      SOURCES/redhat-rpm-config-9.1.0-kmod-brew-build.patch
  36. 509
      SOURCES/redhat-rpm-config-9.1.0-kmod-kabi.patch
  37. 58
      SOURCES/redhat-rpm-config-9.1.0-ksym-requires-multifile.patch
  38. 31
      SOURCES/redhat-rpm-config-9.1.0-ksyms-2.patch
  39. 33
      SOURCES/redhat-rpm-config-9.1.0-ksyms.patch
  40. 10
      SOURCES/redhat-rpm-config-9.1.0-minidebuginfo.patch
  41. 6
      SOURCES/redhat-rpm-config-9.1.0-mono-ppc64le-aarch64-support.patch
  42. 19
      SOURCES/redhat-rpm-config-9.1.0-ncpus-max.patch
  43. 27
      SOURCES/redhat-rpm-config-9.1.0-no-strip-note.patch
  44. 19
      SOURCES/redhat-rpm-config-9.1.0-perfbuild.patch
  45. 11
      SOURCES/redhat-rpm-config-9.1.0-pkgconfig-private.patch
  46. 14
      SOURCES/redhat-rpm-config-9.1.0-ppc-no-minimal-toc.patch
  47. 31
      SOURCES/redhat-rpm-config-9.1.0-ppc64le.patch
  48. 15
      SOURCES/redhat-rpm-config-9.1.0-python-hardlink-spaces-in-filenames.patch
  49. 12
      SOURCES/redhat-rpm-config-9.1.0-record-switches.patch
  50. 19
      SOURCES/redhat-rpm-config-9.1.0-relro.patch
  51. 21
      SOURCES/redhat-rpm-config-9.1.0-repack-jars.patch
  52. 35
      SOURCES/redhat-rpm-config-9.1.0-rhel7-arch-optflags.patch
  53. 12
      SOURCES/redhat-rpm-config-9.1.0-stackprotector-strong.patch
  54. 36
      SOURCES/redhat-rpm-config-9.1.0-strict-python-bytecompile.patch
  55. 12
      SOURCES/redhat-rpm-config-9.1.0-use-kverrel-for-kmodtool.patch
  56. 17
      SOURCES/redhat-rpm-config-9.1.0-use-prefix-macro.patch
  57. 16
      SOURCES/redhat-rpm-config-9.1.0.Remove-hardcoded-limit-of-16-CPUs.patch
  58. 827
      SPECS/redhat-rpm-config.spec

44
SOURCES/0001-Drop-un-setting-LANG-and-DISPLAY-in-various-build-st.patch

@ -0,0 +1,44 @@ @@ -0,0 +1,44 @@
From 17d08cd3942405e20889ba7d420191993c93a12f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Ville=20Skytt=C3=A4?= <ville.skytta@iki.fi>
Date: Sun, 25 Sep 2011 11:25:34 +0300
Subject: [PATCH] Drop (un)setting LANG and DISPLAY in various build stages.

rpm >= 4.8.0 takes care of that itself.
---
macros | 21 ---------------------
1 files changed, 0 insertions(+), 21 deletions(-)

Index: redhat-rpm-config-9.1.0/macros
===================================================================
--- redhat-rpm-config-9.1.0.orig/macros
+++ redhat-rpm-config-9.1.0/macros
@@ -131,29 +131,8 @@ package or when debugging this package.\
%endif\
%{nil}

-# Bad hack to set $LANG to C during all RPM builds
-%prep \
-%%prep\
-LANG=C\
-export LANG\
-unset DISPLAY\
-%{nil}
-
-%build %%build\
-LANG=C\
-export LANG\
-unset DISPLAY\
-%{nil}
-
%install %{?_enable_debug_packages:%{?buildsubdir:%{debug_package}}}\
%%install\
-LANG=C\
-export LANG\
-unset DISPLAY\
-%{nil}
-
-%check %%check\
-unset DISPLAY\
%{nil}

#

1558
SOURCES/config.guess vendored

File diff suppressed because it is too large Load Diff

1791
SOURCES/config.sub vendored

File diff suppressed because it is too large Load Diff

2
SOURCES/kabi.attr

@ -0,0 +1,2 @@ @@ -0,0 +1,2 @@
%__kabi_provides %{_rpmconfigdir}/kabi.sh
%__kabi_path ^/boot/symvers-.*gz$

13
SOURCES/kabi.sh

@ -0,0 +1,13 @@ @@ -0,0 +1,13 @@
#!/bin/sh +x
#
# kabi.sh - Automatically extract any kernel symbol checksum from the
# symvers file and add to RPM deps. This is used to move the
# checksum checking from modprobe to rpm install for 3rd party
# modules (so they can fail during install and not at load).

IFS=$'\n'

for symvers in $(grep -E '/boot/symvers-*') $*;
do
zcat $symvers | awk ' {print "kernel(" $2 ") = " $1 }'
done

135
SOURCES/libtool-handle-ppc64le.sh

@ -0,0 +1,135 @@ @@ -0,0 +1,135 @@
#!/bin/bash

# Date: April 2, 2014
# by Aldy Hernandez

# Attempt to fix any "-m elf64ppc" linker checks in configure and
# libtool.m4 files.
#
# This script is meant to run silently as part of rpm's %configure
# macro. It either fixes the problem, or we silently ignore it, in
# which case it is up to the package maintainer to add support for
# ppc64le.

# Our two attempts at fixing the problem.
PATCH1=/tmp/$$.patch1
PATCH2=/tmp/$$.patch2

cleanup() {
rm -f $PATCH1 $PATCH2
}

trap cleanup 0 1 2 3 4 5 6 7 8 9 11 13 14 15

# There are two variants in RHEL7 so far. The first version, handled
# with $PATCH1, currently handles all but 3 packages. The $PATCH2
# version handles the remnant.
#
cat > $PATCH1 <<EOF
--- configure.orig 2014-03-18 15:56:15.575070238 -0500
+++ configure 2014-03-18 16:05:50.877861163 -0500
@@ -7714,6 +7714,9 @@
x86_64-*linux*)
LD="\${LD-ld} -m elf_i386"
;;
+ ppc64le-*linux*|powerpc64le-*linux*)
+ LD="\${LD-ld} -m elf32lppclinux"
+ ;;
ppc64-*linux*|powerpc64-*linux*)
LD="\${LD-ld} -m elf32ppclinux"
;;
@@ -7733,6 +7736,9 @@
x86_64-*linux*)
LD="\${LD-ld} -m elf_x86_64"
;;
+ ppc*le-*linux*|powerpc*le-*linux*)
+ LD="\${LD-ld} -m elf64lppc"
+ ;;
ppc*-*linux*|powerpc*-*linux*)
LD="\${LD-ld} -m elf64ppc"
;;
EOF

cat > $PATCH2 <<EOF
--- configure.orig 2014-03-18 16:35:28.942799967 -0500
+++ configure 2014-03-18 16:34:35.608519090 -0500
@@ -3798,6 +3798,9 @@
x86_64-*linux*)
LD="\${LD-ld} -m elf_i386"
;;
+ ppc64le-*linux*)
+ LD="\${LD-ld} -m elf32lppclinux"
+ ;;
ppc64-*linux*)
LD="\${LD-ld} -m elf32ppclinux"
;;
@@ -3814,6 +3817,9 @@
x86_64-*linux*)
LD="\${LD-ld} -m elf_x86_64"
;;
+ ppc*le-*linux*|powerpc*le-*linux*)
+ LD="\${LD-ld} -m elf64lppc"
+ ;;
ppc*-*linux*|powerpc*-*linux*)
LD="\${LD-ld} -m elf64ppc"
;;
EOF


FILES=`find . -name configure -o -name libtool.m4`
for f in $FILES; do
# Filter out candidates that already handle ppc64le.
if grep -s -e '-m elf64lppc' $f >/dev/null; then
continue
fi

# Filter out candidates that don't handle PPC.
if ! grep -s -e '-m elf64ppc' $f >/dev/null; then
continue
fi

echo "Broken -m elf64ppc use in $f should handle elf64lppc."
echo "Attempting automatic fix."

# Attempt to fix the offended file.
basename=`basename $f`
dirname=`dirname $f`
for p in $PATCH1 $PATCH2; do
# This is an all for nothing affair. The patch either
# applies entirely clean, or we don't even try.
#
# Tentatively try either patch cleanly, and if we succeed then
# do it for real.
pushd $dirname 2>&1 > /dev/null
if [ $basename = libtool.m4 ]; then
sed s/configure/libtool.m4/ < $p | patch --dry-run --follow-symlinks -l 2>&1 >/dev/null
else
patch --dry-run --follow-symlinks -l < $p 2>&1 > /dev/null
fi
if [ $? != 0 ]; then
echo -n "$p approach did not work for $dirname/$basename: "
pwd
# This approach didn't work, try the next one.
popd 2>&1 > /dev/null
continue
fi

# Seriously now...
if [ $basename = libtool.m4 ]; then
# Save the timestamp.
cp -p $basename /tmp/tmp.$$
sed s/configure/libtool.m4/ < $p | patch --follow-symlinks -l -s 2>&1 > /dev/null
# Use the old timestamp, to avoid anyone noticing changes
# to libtool.m4.
touch --reference=/tmp/tmp.$$ $basename
rm -f /tmp/tmp.$$
else
patch --follow-symlinks -l -s < $p 2>&1 > /dev/null
fi
echo "Fixed $f for ld -m ppc64le support."
popd 2>&1 > /dev/null
break
done
done

rm -f $PATCH1 $PATCH2

2
SOURCES/redhat-hardened-cc1

@ -0,0 +1,2 @@ @@ -0,0 +1,2 @@
*cc1_options:
+ %{!fpie:%{!fPIE:%{!fpic:%{!fPIC:%{!fno-pic:-fPIE}}}}}

5
SOURCES/redhat-hardened-ld

@ -0,0 +1,5 @@ @@ -0,0 +1,5 @@
*self_spec:
+ %{!shared:-pie}

*link:
+ -z now

11
SOURCES/redhat-rpm-config-9.0.3-latest-kernel.patch

@ -0,0 +1,11 @@ @@ -0,0 +1,11 @@
--- redhat-rpm-config-9.0.3/macros.orig 2016-01-05 16:21:18.708529423 +0100
+++ redhat-rpm-config-9.0.3/macros 2016-01-05 16:42:26.023939895 +0100
@@ -202,7 +202,7 @@
%global kmodtool %{-s*}%{!-s:/usr/lib/rpm/redhat/kmodtool} \
%global kmod_version %{-v*}%{!-v:%{version}} \
%global kmod_release %{-r*}%{!-r:%{release}} \
- %global latest_kernel %(rpm -q --qf '%{VERSION}-%{RELEASE}.%{ARCH}\\\\n' `rpm -q kernel-devel | /usr/lib/rpm/redhat/rpmsort -r | head -n 1` | head -n 1) \
+ %global latest_kernel %(rpm -q --qf '%{VERSION}-%{RELEASE}.%{ARCH}\\\\n' `rpm -qa | egrep "^kernel(-rt|-aarch64)?-devel" | /usr/lib/rpm/redhat/rpmsort -r | head -n 1` | head -n 1) \
%{!?kernel_version:%{expand:%%global kernel_version %{latest_kernel}}} \
%global kverrel %(%{kmodtool} verrel %{?kernel_version} 2>/dev/null) \
flavors="default" \

11
SOURCES/redhat-rpm-config-9.0.3-shebang.patch

@ -0,0 +1,11 @@ @@ -0,0 +1,11 @@
--- redhat-rpm-config-9.0.3/find-requires.original 2015-01-07 10:47:24.250285190 +0900
+++ redhat-rpm-config-9.0.3/find-requires 2015-01-07 10:48:01.483585227 +0900
@@ -74,7 +74,7 @@ fi
# --- Script interpreters.
for f in $scriptlist; do
[ -r $f -a -x $f ] || continue
- interp=`head -n 1 $f | sed -e 's/^\#\![ ]*//' | cut -d" " -f1`
+ interp=`head -n 1 $f | grep '^#!' | sed -e 's/^\#\![ ]*//' | cut -d" " -f1`
interplist="$interplist $interp"
case $interp in
*/perl) perllist="$perllist $f" ;;

25
SOURCES/redhat-rpm-config-9.1.0-Add-_pkgdocdir.patch

@ -0,0 +1,25 @@ @@ -0,0 +1,25 @@
From e606f56f34f55900ef4d52fd273192425fe50ba5 Mon Sep 17 00:00:00 2001
From: Kevin Fenzi <kevin@scrye.com>
Date: Wed, 24 Jul 2013 16:20:05 -0600
Subject: [PATCH] Make docdirs unversioned on Fedora 20+ (#986871)

Add macros but keep it versioned for RHEL 7
---
macros | 2 ++
1 file changed, 2 insertions(+)

diff --git a/macros b/macros
index 6994751..3776e60 100644
--- a/macros
+++ b/macros
@@ -18,6 +18,8 @@
%_mandir %{_prefix}/share/man

%_defaultdocdir %{_prefix}/share/doc
+%_pkgdocdir %{_docdir}/%{name}-%{version}
+%_docdir_fmt %%{NAME}-%%{VERSION}

%_fmoddir %{_libdir}/gfortran/modules

--
2.5.5

44
SOURCES/redhat-rpm-config-9.1.0-Fix-stripping-of-binaries.patch

@ -0,0 +1,44 @@ @@ -0,0 +1,44 @@
Based on:

From 5b4805df2085b0e7c4f09caad62638c3238b3bc1 Mon Sep 17 00:00:00 2001
From: Florian Festi <ffesti@redhat.com>
Date: Tue, 30 Jun 2015 11:39:21 +0200
Subject: [PATCH] Fix stripping of binaries for changed file output.

file will print a "warning" that it only processed up to 256 notes.

- Related: 659614aeb6fffe3b249c12b442bd85129100f73b
- Related: http://rpm.org/ticket/887
- Related: rhbz#1206312

--- redhat-rpm-config-9.1.0/brp-strip.orig 2010-02-02 10:24:04.000000000 +0100
+++ redhat-rpm-config-9.1.0/brp-strip 2016-05-11 14:21:47.846187676 +0200
@@ -9,6 +9,6 @@
for f in `find $RPM_BUILD_ROOT -type f \( -perm -0100 -or -perm -0010 -or -perm -0001 \) -exec file {} \; | \
grep -v "^${RPM_BUILD_ROOT}/\?usr/lib/debug" | \
grep -v ' shared object,' | \
- sed -n -e 's/^\(.*\):[ ]*ELF.*, not stripped/\1/p'`; do
+ sed -n -e 's/^\(.*\):[ ]*ELF.*, not stripped.*/\1/p'`; do
$STRIP -g "$f" || :
done
--- redhat-rpm-config-9.1.0/brp-strip-comment-note.orig 2010-02-02 10:24:04.000000000 +0100
+++ redhat-rpm-config-9.1.0/brp-strip-comment-note 2016-05-11 14:21:47.846187676 +0200
@@ -13,7 +13,7 @@
# for already stripped elf files in the build root
for f in `find $RPM_BUILD_ROOT -type f \( -perm -0100 -or -perm -0010 -or -perm -0001 \) -exec file {} \; | \
grep -v "^${RPM_BUILD_ROOT}/\?usr/lib/debug" | \
- sed -n -e 's/^\(.*\):[ ]*ELF.*, stripped/\1/p'`; do
+ sed -n -e 's/^\(.*\):[ ]*ELF.*, stripped.*/\1/p'`; do
note="-R .note"
if $OBJDUMP -h $f | grep '^[ ]*[0-9]*[ ]*.note[ ]' -A 1 | \
grep ALLOC >/dev/null; then
--- redhat-rpm-config-9.1.0/brp-strip-shared.orig 2010-02-02 10:24:04.000000000 +0100
+++ redhat-rpm-config-9.1.0/brp-strip-shared 2016-05-11 14:21:47.846187676 +0200
@@ -15,6 +15,6 @@
for f in `find $RPM_BUILD_ROOT -type f -a -exec file {} \; | \
grep -v "^${RPM_BUILD_ROOT}/\?usr/lib/debug" | \
grep ' shared object,' | \
- sed -n -e 's/^\(.*\):[ ]*ELF.*, not stripped/\1/p'`; do
+ sed -n -e 's/^\(.*\):[ ]*ELF.*, not stripped.*/\1/p'`; do
$STRIP --strip-unneeded "$f"
done

13
SOURCES/redhat-rpm-config-9.1.0-aarch64.patch

@ -0,0 +1,13 @@ @@ -0,0 +1,13 @@
diff --git a/rpmrc b/rpmrc
index 9127200..fe2f84b 100644
--- a/rpmrc
+++ b/rpmrc
@@ -64,6 +64,8 @@ optflags: hades %{__global_cflags}
optflags: s390 %{__global_cflags} -m31 -march=z9-109 -mtune=z10
optflags: s390x %{__global_cflags} -m64 -march=z9-109 -mtune=z10

+optflags: aarch64 %{__global_cflags}
+
# set build arch to fedora buildarches on hardware capable of running it
# saves having to do rpmbuild --target=
buildarchtranslate: athlon: i686

51
SOURCES/redhat-rpm-config-9.1.0-arches-macros.patch

@ -0,0 +1,51 @@ @@ -0,0 +1,51 @@
diff -uNr redhat-rpm-config-9.1.0-orig/macros.ghc-srpm redhat-rpm-config-9.1.0/macros.ghc-srpm
--- redhat-rpm-config-9.1.0-orig/macros.ghc-srpm 1969-12-31 18:00:00.000000000 -0600
+++ redhat-rpm-config-9.1.0/macros.ghc-srpm 2011-05-27 10:19:29.504287354 -0500
@@ -0,0 +1,3 @@
+# macro defining the archs that ghc runs on in fedora
+%ghc_arches %{ix86} x86_64 ppc ppc64 ppc64le alpha sparcv9 armv7hl armv5tel s390 s390x aarch64
+%ghc_arches_with_ghci %{ix86} x86_64 ppc sparcv9 armv7hl armv5tel
diff -uNr redhat-rpm-config-9.1.0-orig/macros.mono-srpm redhat-rpm-config-9.1.0/macros.mono-srpm
--- redhat-rpm-config-9.1.0-orig/macros.mono-srpm 1969-12-31 18:00:00.000000000 -0600
+++ redhat-rpm-config-9.1.0/macros.mono-srpm 2011-05-27 10:59:00.348201750 -0500
@@ -0,0 +1,2 @@
+# arches that mono builds on
+%mono_arches %{ix86} x86_64 sparc sparcv9 ia64 %{arm} alpha s390x ppc ppc64
diff -uNr redhat-rpm-config-9.1.0-orig/macros.nodejs-srpm redhat-rpm-config-9.1.0/macros.nodejs-srpm
--- redhat-rpm-config-9.1.0-orig/macros.nodejs-srpm 1969-12-31 17:00:00.000000000 -0700
+++ redhat-rpm-config-9.1.0/macros.nodejs-srpm 2013-05-20 19:21:20.364367765 -0700
@@ -0,0 +1,6 @@
+# nodejs_arches lists what arches Node.js and dependent packages run on.
+#
+# Enabling Node.js on other arches requires porting the V8 JavaScript JIT to
+# those arches.
+
+%nodejs_arches %{ix86} x86_64 %{arm} aarch64 ppc64le s390x
diff -uNr redhat-rpm-config-9.1.0-orig/macros.ocaml-srpm redhat-rpm-config-9.1.0/macros.ocaml-srpm
--- redhat-rpm-config-9.1.0-orig/macros.ocaml-srpm 1969-12-31 18:00:00.000000000 -0600
+++ redhat-rpm-config-9.1.0/macros.ocaml-srpm 2011-05-27 10:42:10.638194240 -0500
@@ -0,0 +1,2 @@
+# arches that ocaml runs on
+%ocaml_arches aarch64 alpha %{arm} %{ix86} ia64 x86_64 ppc ppc64 ppc64le sparc sparcv9
diff -uNr redhat-rpm-config-9.1.0-orig/macros.gnat-srpm redhat-rpm-config-9.1.0/macros.gnat-srpm
--- redhat-rpm-config-9.1.0-orig/macros.gnat-srpm 1970-01-01 01:00:00.000000000 +0100
+++ redhat-rpm-config-9.1.0/macros.gnat-srpm 2012-01-05 17:04:35.000000000 +0100
@@ -0,0 +1,4 @@
+# GNAT_arches lists the architectures where GNAT is available in Fedora. Ada
+# packages won't build on other architectures until GNAT is bootstrapped for
+# them.
+%GNAT_arches %{ix86} x86_64 ia64 ppc ppc64 ppc64le alpha aarch64
diff -uNr redhat-rpm-config-9.1.0-orig/Makefile redhat-rpm-config-9.1.0/Makefile
--- redhat-rpm-config-9.1.0-orig/Makefile 2010-02-02 03:24:04.000000000 -0600
+++ redhat-rpm-config-9.1.0/Makefile 2011-05-27 10:43:34.898205307 -0500
@@ -11,7 +11,10 @@
install:
mkdir -p $(DESTDIR)/usr/lib/rpm/redhat
cp -pr * $(DESTDIR)/usr/lib/rpm/redhat/
+ mkdir -p $(DESTDIR)/etc/rpm
+ cp -pr macros.* $(DESTDIR)/etc/rpm/
rm -f $(DESTDIR)/usr/lib/rpm/redhat/Makefile
+ rm -f $(DESTDIR)/usr/lib/rpm/redhat/macros.*

tag-archive:
@git tag -a $(CVSTAG) -m "$(NAME)-$(VERSION) release"

27
SOURCES/redhat-rpm-config-9.1.0-arm.patch

@ -0,0 +1,27 @@ @@ -0,0 +1,27 @@
diff -urNp redhat-rpm-config-9.1.0_orig/rpmrc redhat-rpm-config-9.1.0/rpmrc
--- redhat-rpm-config-9.1.0_orig/rpmrc 2010-02-02 04:24:04.000000000 -0500
+++ redhat-rpm-config-9.1.0/rpmrc 2011-07-02 04:29:11.921575635 -0400
@@ -46,10 +46,12 @@ optflags: armv3l %{__global_cflags} -fsi
optflags: armv4b %{__global_cflags} -fsigned-char -march=armv4
optflags: armv4l %{__global_cflags} -fsigned-char -march=armv4
optflags: armv4tl %{__global_cflags} -march=armv4t
-optflags: armv5tel %{__global_cflags} -march=armv5te
-optflags: armv5tejl %{__global_cflags} -march=armv5te
-optflags: armv6l %{__global_cflags} -march=armv6
-optflags: armv7l %{__global_cflags} -march=armv7
+optflags: armv5tel %{__global_cflags} -march=armv5te -mfloat-abi=soft
+optflags: armv5tejl %{__global_cflags} -march=armv5te -mfloat-abi=soft
+optflags: armv6l %{__global_cflags} -march=armv6 -mfloat-abi=soft
+optflags: armv7l %{__global_cflags} -march=armv7-a -mfloat-abi=soft
+optflags: armv7hl %{__global_cflags} -march=armv7-a -mfpu=vfpv3-d16 -mfloat-abi=hard
+optflags: armv7hnl %{__global_cflags} -march=armv7-a -mfpu=neon -mfloat-abi=hard

optflags: atarist %{__global_cflags}
optflags: atariste %{__global_cflags}
@@ -76,5 +78,7 @@ buildarchtranslate: sparcv9v: sparcv9

buildarchtranslate: armv5tejl: armv5tel
buildarchtranslate: armv6l: armv5tel
buildarchtranslate: armv7l: armv5tel
+buildarchtranslate: armv7hl: armv7hl
+buildarchtranslate: armv7hnl: armv7hl

12
SOURCES/redhat-rpm-config-9.1.0-centos.dist.patch

@ -0,0 +1,12 @@ @@ -0,0 +1,12 @@
diff -uNrp redhat-rpm-config-9.1.0.orig/dist.sh redhat-rpm-config-9.1.0/dist.sh
--- redhat-rpm-config-9.1.0.orig/dist.sh 2010-02-02 03:24:04.000000000 -0600
+++ redhat-rpm-config-9.1.0/dist.sh 2014-06-19 09:29:04.064790458 -0500
@@ -25,7 +25,7 @@ function check_rhl {
}

function check_rhel {
- egrep -q "(Enterprise|Advanced)" $RELEASEFILE && echo $DISTNUM
+ egrep -q "(Enterprise|Advanced|CentOS)" $RELEASEFILE && echo $DISTNUM
}

function check_fedora {

147
SOURCES/redhat-rpm-config-9.1.0-compressed-kmods-support.patch

@ -0,0 +1,147 @@ @@ -0,0 +1,147 @@
Index: redhat-rpm-config-9.1.0/find-requires
===================================================================
--- redhat-rpm-config-9.1.0.orig/find-requires 2018-08-24 09:58:45.437193389 +0200
+++ redhat-rpm-config-9.1.0/find-requires 2018-08-24 09:59:31.902739176 +0200
@@ -143,7 +143,7 @@
unset is_kmod

for f in $filelist; do
- if [ $(echo "$f" | sed -r -ne 's:^.*/lib/modules/(.*)/(.*).ko$:\2:p') ]
+ if [ $(echo "$f" | sed -r -ne 's:^.*/lib/modules/(.*)/(.*)\.ko(\.gz|\.bz2|\.xz)?$:\2:p') ]
then
is_kmod=1;
elif [ $(echo "$f" | sed -r -ne 's:^.*/boot/(.*):\1:p') ]
Index: redhat-rpm-config-9.1.0/find-requires.ksyms
===================================================================
--- redhat-rpm-config-9.1.0.orig/find-requires.ksyms 2018-08-24 09:55:19.122210171 +0200
+++ redhat-rpm-config-9.1.0/find-requires.ksyms 2018-08-24 10:01:02.895849695 +0200
@@ -9,24 +9,49 @@

# Extract all of the symbols provided by this module.
all_provides() {
- if [[ -n $(nm "$@" | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p') ]]; then
- nm "$@" \
- | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p' \
- | awk --non-decimal-data '{printf("%s:0x%08x\n", $2, $1)}' \
- | LC_ALL=C sort -k1,1 -u
- else
- ELFRODATA=$(readelf -R .rodata "$@" | awk '/0x/{printf $2$3$4$5}')
- if [[ -n $(readelf -h "$@" | grep "little endian") ]]; then
- RODATA=$(echo $ELFRODATA | sed 's/\(..\)\(..\)\(..\)\(..\)/\4\3\2\1/g')
+ for module in "$@"; do
+ tmpfile=""
+ if [ "x${module%.ko}" = "x${module}" ]; then
+ tmpfile=$(mktemp -t ${0##*/}.XXXXXX.ko)
+ proc_bin=
+ case "${module##*.}" in
+ xz)
+ proc_bin=xz
+ ;;
+ bz2)
+ proc_bin=bzip2
+ ;;
+ gz)
+ proc_bin=gzip
+ ;;
+ esac
+
+ [ -n "$proc_bin" ] || continue
+
+ "$proc_bin" -d -c - < "$module" > "$tmpfile"
+ module="$tmpfile"
+ fi
+
+ if [[ -n $(nm "$module" | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p') ]]; then
+ nm "$module" \
+ | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p' \
+ | awk --non-decimal-data '{printf("%s:0x%08x\n", $2, $1)}'
else
- RODATA=$ELFRODATA
+ ELFRODATA=$(readelf -R .rodata "$module" | awk '/0x/{printf $2$3$4$5}')
+ if [[ -n $(readelf -h "$module" | grep "little endian") ]]; then
+ RODATA=$(echo $ELFRODATA | sed 's/\(..\)\(..\)\(..\)\(..\)/\4\3\2\1/g')
+ else
+ RODATA=$ELFRODATA
+ fi
+ for sym in $(nm "$module" | sed -r -ne 's:^0*([0-9a-f]+) R __crc_(.+):0x\1 \2:p'); do
+ echo $sym $RODATA
+ done \
+ | awk --non-decimal-data '{printf("%s:0x%08s\n", $2, substr($3,($1*2)+1,8))}'
fi
- for sym in $(nm "$@" | sed -r -ne 's:^0*([0-9a-f]+) R __crc_(.+):0x\1 \2:p'); do
- echo $sym $RODATA
- done \
- | awk --non-decimal-data '{printf("%s:0x%08s\n", $2, substr($3,($1*2)+1,8))}' \
- | LC_ALL=C sort -k1,1 -u
- fi
+
+ [ -z "$tmpfile" ] || rm -f -- "$tmpfile"
+ done \
+ | LC_ALL=C sort -k1,1 -u
}

# Extract all of the requirements of this module.
@@ -100,7 +125,7 @@
fi
}

-modules=($(grep -E '/lib/modules/.+\.ko$'))
+modules=($(grep -E '/lib/modules/.+\.ko(\.gz|\.bz2|\.xz)?$'))
if [ ${#modules[@]} -gt 0 ]; then
kernel=$(/sbin/modinfo -F vermagic "${modules[0]}" | sed -e 's: .*::' -e q)

Index: redhat-rpm-config-9.1.0/find-provides
===================================================================
--- redhat-rpm-config-9.1.0.orig/find-provides 2010-02-02 10:24:04.000000000 +0100
+++ redhat-rpm-config-9.1.0/find-provides 2018-08-24 10:02:26.666030820 +0200
@@ -92,7 +92,7 @@

is_kmod=1
for f in $filelist; do
- if [ $(echo "$f" | sed -r -ne 's:^.*/lib/modules/(.*)/(.*).ko$:\2:p') ]
+ if [ $(echo "$f" | sed -r -ne 's:^.*/lib/modules/(.*)/(.*)\.ko(\.gz|\.bz2|\.xz)?$:\2:p') ]
then
is_kernel=1;
fi
Index: redhat-rpm-config-9.1.0/find-provides.ksyms
===================================================================
--- redhat-rpm-config-9.1.0.orig/find-provides.ksyms 2018-08-24 09:55:19.065210728 +0200
+++ redhat-rpm-config-9.1.0/find-provides.ksyms 2018-08-24 10:03:17.727531681 +0200
@@ -2,7 +2,29 @@

IFS=$'\n'

-for module in $(grep -E '/lib/modules/.+\.ko$'); do
+for module in $(grep -E '/lib/modules/.+\.ko(\.gz|\.bz2|\.xz)?$'); do
+ tmpfile=""
+ if [ "x${module%.ko}" = "x${module}" ]; then
+ tmpfile=$(mktemp -t ${0##*/}.XXXXXX.ko)
+ proc_bin=
+ case "${module##*.}" in
+ xz)
+ proc_bin=xz
+ ;;
+ bz2)
+ proc_bin=bzip2
+ ;;
+ gz)
+ proc_bin=gzip
+ ;;
+ esac
+
+ [ -n "$proc_bin" ] || continue
+
+ "$proc_bin" -d -c - < "$module" > "$tmpfile"
+ module="$tmpfile"
+ fi
+
if [[ -n $(nm $module | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p') ]]; then
nm $module \
| sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p' \
@@ -21,4 +43,6 @@
| awk --non-decimal-data '{printf("ksym(%s) = 0x%08s\n", $2, substr($3,($1*2)+1,8))}' \
| LC_ALL=C sort -u
fi
+
+ [ -z "$tmpfile" ] || rm -f -- "$tmpfile"
done

13
SOURCES/redhat-rpm-config-9.1.0-configfoo.patch

@ -0,0 +1,13 @@ @@ -0,0 +1,13 @@
diff -up redhat-rpm-config-9.1.0/macros.configfoo redhat-rpm-config-9.1.0/macros
--- redhat-rpm-config-9.1.0/macros.configfoo 2013-04-22 13:42:25.984613491 +0300
+++ redhat-rpm-config-9.1.0/macros 2013-04-22 13:43:27.053420367 +0300
@@ -33,6 +33,9 @@
CXXFLAGS="${CXXFLAGS:-%optflags}" ; export CXXFLAGS ; \
FFLAGS="${FFLAGS:-%optflags -I%_fmoddir}" ; export FFLAGS ; \
LDFLAGS="${LDFLAGS:-%__global_ldflags}"; export LDFLAGS; \
+ for i in $(find . -name config.guess -o -name config.sub) ; do \
+ [ -f /usr/lib/rpm/redhat/$(basename $i) ] && %{__rm} -f $i && %{__cp} -fv /usr/lib/rpm/redhat/$(basename $i) $i ; \
+ done ; \
%{_configure} --build=%{_build} --host=%{_host} \\\
--program-prefix=%{?_program_prefix} \\\
--disable-dependency-tracking \\\

42
SOURCES/redhat-rpm-config-9.1.0-dwz.patch

@ -0,0 +1,42 @@ @@ -0,0 +1,42 @@
--- redhat-rpm-config-9.1.0/macros.dwz.jj 2012-06-25 13:08:44.854489913 +0200
+++ redhat-rpm-config-9.1.0/macros.dwz 2012-06-25 13:03:55.520112180 +0200
@@ -0,0 +1,39 @@
+# Macros for reducing debug info size using dwz(1) utility.
+
+# The two default values below should result in dwz taking at most
+# 3GB of RAM or so on 64-bit hosts and 2.5GB on 32-bit hosts
+# on the largest *.debug files (in mid 2012 those are
+# libreoffice-debuginfo, debuginfos containing
+# libxul.so.debug and libwebkitgtk-*.so.*.debug).
+# This needs to be tuned based on the amount of available RAM
+# on build boxes for each architecture as well as virtual address
+# space limitations if dwz is 32-bit program. While it needs less
+# memory than 64-bit program because pointers are smaller, it can
+# never have more than 4GB-epsilon of RAM and on some architecture
+# even less than that (e.g. 2GB).
+
+# Number of debugging information entries (DIEs) above which
+# dwz will stop considering file for multifile optimizations
+# and enter a low memory mode, in which it will optimize
+# in about half the memory needed otherwise.
+%_dwz_low_mem_die_limit 10000000
+# Number of DIEs above which dwz will stop processing
+# a file altogether.
+%_dwz_max_die_limit 50000000
+
+# On x86_64 increase the higher limit to make libwebkit* optimizable.
+# libwebkit* in mid 2012 contains roughly 87mil DIEs, and 64-bit
+# dwz is able to optimize it from ~1.1GB to ~410MB using 5.2GB of RAM.
+%_dwz_max_die_limit_x86_64 110000000
+
+# On ARM, build boxes often have only 512MB of RAM and are very slow.
+# Lower both the limits.
+%_dwz_low_mem_die_limit_armv5tel 4000000
+%_dwz_low_mem_die_limit_armv7hl 4000000
+%_dwz_max_die_limit_armv5tel 10000000
+%_dwz_max_die_limit_armv7hl 10000000
+
+%_dwz_limit() %{expand:%%{?%{1}_%{_arch}}%%{!?%{1}_%{_arch}:%%%{1}}}
+%_find_debuginfo_dwz_opts --run-dwz\\\
+ --dwz-low-mem-die-limit %{_dwz_limit _dwz_low_mem_die_limit}\\\
+ --dwz-max-die-limit %{_dwz_limit _dwz_max_die_limit}

11
SOURCES/redhat-rpm-config-9.1.0-fcflags.patch

@ -0,0 +1,11 @@ @@ -0,0 +1,11 @@
diff -up redhat-rpm-config-9.1.0/macros.fcflags redhat-rpm-config-9.1.0/macros
--- redhat-rpm-config-9.1.0/macros.fcflags 2013-04-23 07:26:57.202073011 +0300
+++ redhat-rpm-config-9.1.0/macros 2013-04-23 07:29:21.401036883 +0300
@@ -32,6 +32,7 @@
CFLAGS="${CFLAGS:-%optflags}" ; export CFLAGS ; \
CXXFLAGS="${CXXFLAGS:-%optflags}" ; export CXXFLAGS ; \
FFLAGS="${FFLAGS:-%optflags -I%_fmoddir}" ; export FFLAGS ; \
+ FCFLAGS="${FCFLAGS:-%optflags -I%_fmoddir}" ; export FCFLAGS ; \
LDFLAGS="${LDFLAGS:-%__global_ldflags}"; export LDFLAGS; \
for i in $(find . -name config.guess -o -name config.sub) ; do \
[ -f /usr/lib/rpm/redhat/$(basename $i) ] && %{__rm} -f $i && %{__cp} -fv /usr/lib/rpm/redhat/$(basename $i) $i ; \

13
SOURCES/redhat-rpm-config-9.1.0-filtering-spaces-in-filename.patch

@ -0,0 +1,13 @@ @@ -0,0 +1,13 @@
Index: redhat-rpm-config-9.1.0/macros
===================================================================
--- redhat-rpm-config-9.1.0.orig/macros
+++ redhat-rpm-config-9.1.0/macros
@@ -262,7 +262,7 @@ kernel_module_package_release 1
# actually set up the filtering bits
%filter_setup %{expand: \
%global _use_internal_dependency_generator 0 \
-%global __deploop() while read FILE; do /usr/lib/rpm/rpmdeps -%{1} ${FILE}; done | /bin/sort -u \
+%global __deploop() while read FILE; do echo "${FILE}" | /usr/lib/rpm/rpmdeps -%{1}; done | /bin/sort -u \
%global __find_provides /bin/sh -c "%{?__filter_prov_cmd} %{__deploop P} %{?__filter_from_prov}" \
%global __find_requires /bin/sh -c "%{?__filter_req_cmd} %{__deploop R} %{?__filter_from_req}" \
}

15
SOURCES/redhat-rpm-config-9.1.0-find-provides.libtool.patch

@ -0,0 +1,15 @@ @@ -0,0 +1,15 @@
--- redhat-rpm-config-9.1.0/find-provides.libtool.orig 2016-05-11 14:36:17.082744500 +0200
+++ redhat-rpm-config-9.1.0/find-provides.libtool 2016-05-11 14:38:49.404192547 +0200
@@ -2,9 +2,9 @@
while read possible ; do
case "$possible" in
*.la)
- if grep -iq '^# Generated by ltmain.sh' "$possible" 2> /dev/null ; then
- echo "libtool($possible)"
- fi
+ if grep -Eiq '^# Generated by (libtool|ltmain.sh)' "$possible" 2> /dev/null ; then
+ echo "libtool($possible)"
+ fi
;;
esac
done

14
SOURCES/redhat-rpm-config-9.1.0-find-requires-fix-detection.patch

@ -0,0 +1,14 @@ @@ -0,0 +1,14 @@
--- current/find-requires.orig 2016-06-13 17:31:21.689322870 +0200
+++ current/find-requires 2016-06-13 17:42:04.779855644 +0200
@@ -21,10 +21,10 @@
# --- Grab the file manifest and classify files.
#filelist=`sed "s/['\"]/\\\&/g"`
filelist=`sed "s/[]['\"*?{}]/\\\\\&/g"`
-exelist=`echo $filelist | xargs -r file | egrep -v ":.* (commands|script) " | \
+exelist=`echo $filelist | xargs -r file | egrep -v ":.* (commands|script)[, ]" | \
grep ":.*executable" | cut -d: -f1`
scriptlist=`echo $filelist | xargs -r file | \
- egrep ":.* (commands|script) " | cut -d: -f1`
+ egrep ":.* (commands|script)[, ]" | cut -d: -f1`
liblist=`echo $filelist | xargs -r file | \
grep ":.*shared object" | cut -d : -f1`

32
SOURCES/redhat-rpm-config-9.1.0-fix-depmod-path.patch

@ -0,0 +1,32 @@ @@ -0,0 +1,32 @@
diff -Nuar redhat-rpm-config-9.1.0_old/kmodtool redhat-rpm-config-9.1.0/kmodtool
--- redhat-rpm-config-9.1.0_old/kmodtool 2013-09-22 10:15:55.903436121 +0800
+++ redhat-rpm-config-9.1.0/kmodtool 2013-09-22 10:18:24.230435836 +0800
@@ -154,8 +154,8 @@
cat <<EOF
Provides: kernel-modules >= ${verrel_dep}${dotvariant}
Provides: ${kmod_name}-kmod = %{?epoch:%{epoch}:}%{version}-%{release}
-Requires(post): /sbin/depmod
-Requires(postun): /sbin/depmod
+Requires(post): /usr/sbin/depmod
+Requires(postun): /usr/sbin/depmod
EOF

if [ "yes" != "$nobuildreqs" ]
@@ -183,7 +183,7 @@
cat <<EOF
%post -n kmod-${kmod_name}${dashvariant}
if [ -e "/boot/System.map-${verrel}${dotvariant}" ]; then
- /sbin/depmod -aeF "/boot/System.map-${verrel}${dotvariant}" "${verrel}${dotvariant}" > /dev/null || :
+ /usr/sbin/depmod -aeF "/boot/System.map-${verrel}${dotvariant}" "${verrel}${dotvariant}" > /dev/null || :
fi

modules=( \$(find /lib/modules/${verrel}${dotvariant}/extra/${kmod_name} | grep '\.ko$') )
@@ -201,7 +201,7 @@
cat <<EOF
%postun -n kmod-${kmod_name}${dashvariant}
if [ -e "/boot/System.map-${verrel}${dotvariant}" ]; then
- /sbin/depmod -aeF "/boot/System.map-${verrel}${dotvariant}" "${verrel}${dotvariant}" > /dev/null || :
+ /usr/sbin/depmod -aeF "/boot/System.map-${verrel}${dotvariant}" "${verrel}${dotvariant}" > /dev/null || :
fi

modules=( \$(cat /var/run/rpm-kmod-${kmod_name}${dashvariant}-modules) )

11
SOURCES/redhat-rpm-config-9.1.0-fix-find-provides-modalias-permissions.patch

@ -0,0 +1,11 @@ @@ -0,0 +1,11 @@
diff -Nuar redhat-rpm-config-9.1.0_old/Makefile redhat-rpm-config-9.1.0/Makefile
--- redhat-rpm-config-9.1.0_old/Makefile 2013-08-26 10:54:34.040834006 +0800
+++ redhat-rpm-config-9.1.0/Makefile 2013-08-26 10:57:03.315833999 +0800
@@ -15,6 +15,7 @@
cp -pr macros.* $(DESTDIR)/etc/rpm/
rm -f $(DESTDIR)/usr/lib/rpm/redhat/Makefile
rm -f $(DESTDIR)/usr/lib/rpm/redhat/macros.*
+ chmod +x $(DESTDIR)/usr/lib/rpm/redhat/find-provides.d/modalias.prov

tag-archive:
@git tag -a $(CVSTAG) -m "$(NAME)-$(VERSION) release"

11
SOURCES/redhat-rpm-config-9.1.0-fix-group-owners-in-jars.patch

@ -0,0 +1,11 @@ @@ -0,0 +1,11 @@
--- redhat-rpm-config-9.1.0/brp-java-repack-jars.old 2018-04-23 11:17:21.121577268 +0200
+++ redhat-rpm-config-9.1.0/brp-java-repack-jars 2018-05-09 12:54:52.018083468 +0200
@@ -29,7 +29,7 @@
IFS=$(printf '\n\t')
for j in $JARS ; do
JAROWN=`ls -l $j | cut -d' ' -f3`
- JARGRP=`ls -l $j | cut -d' ' -f4`
+ JARGRP=`stat $j --printf="%G"`
JARNAME=`basename "$j"`
JTMPDIR=`mktemp -d -p $RPM_BUILD_ROOT/tmp "$JARNAME.tmpdir.XXXXXXXXXX"` || exit 1
JARDIR=`mktemp -d -p $RPM_BUILD_ROOT/tmp "$JARNAME.jardir.XXXXXXXXXX"` || exit 1

12
SOURCES/redhat-rpm-config-9.1.0-fix-kabi-path.patch

@ -0,0 +1,12 @@ @@ -0,0 +1,12 @@
diff -Nuar redhat-rpm-config-9.1.0_bak/find-requires.ksyms redhat-rpm-config-9.1.0/find-requires.ksyms
--- redhat-rpm-config-9.1.0_bak/find-requires.ksyms 2014-11-12 02:24:19.883051779 -0500
+++ redhat-rpm-config-9.1.0/find-requires.ksyms 2014-11-12 02:24:35.005003931 -0500
@@ -45,7 +45,7 @@

check_kabi() {
arch=$(uname -m)
- kabi_file="/lib/modules/kabi/kabi_whitelist_$arch"
+ kabi_file="/lib/modules/kabi-current/kabi_whitelist_$arch"

# If not installed, output a warning and return (continue)
if [ ! -f "$kabi_file" ]; then

86
SOURCES/redhat-rpm-config-9.1.0-fix-ksym-requires-generation.patch

@ -0,0 +1,86 @@ @@ -0,0 +1,86 @@
Index: redhat-rpm-config-9.1.0/find-requires.ksyms
===================================================================
--- redhat-rpm-config-9.1.0.orig/find-requires.ksyms 2018-08-24 09:55:19.094210445 +0200
+++ redhat-rpm-config-9.1.0/find-requires.ksyms 2018-09-14 12:40:34.744601952 +0200
@@ -12,8 +12,8 @@
if [[ -n $(nm "$@" | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p') ]]; then
nm "$@" \
| sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p' \
- | awk --non-decimal-data '{printf("0x%08x\t%s\n", $1, $2)}' \
- | LC_ALL=C sort -k2,2 -u
+ | awk --non-decimal-data '{printf("%s:0x%08x\n", $2, $1)}' \
+ | LC_ALL=C sort -k1,1 -u
else
ELFRODATA=$(readelf -R .rodata "$@" | awk '/0x/{printf $2$3$4$5}')
if [[ -n $(readelf -h "$@" | grep "little endian") ]]; then
@@ -24,8 +24,8 @@
for sym in $(nm "$@" | sed -r -ne 's:^0*([0-9a-f]+) R __crc_(.+):0x\1 \2:p'); do
echo $sym $RODATA
done \
- | awk --non-decimal-data '{printf("0x%08s\t%s\n", substr($3,($1*2)+1,8), $2)}' \
- | LC_ALL=C sort -k2,2 -u
+ | awk --non-decimal-data '{printf("%s:0x%08s\n", $2, substr($3,($1*2)+1,8))}' \
+ | LC_ALL=C sort -k1,1 -u
fi
}

@@ -36,15 +36,15 @@
/sbin/modprobe --dump-modversions "$module" \
| awk --non-decimal-data '
BEGIN { FS = "\t" ; OFS = "\t" }
- {printf("0x%08x\t%s\n", $1, $2)}' \
+ {printf("%s:0x%08x\n", $2, $1)}' \
| sed -r -e 's:$:\t'"$1"':'
done \
- | LC_ALL=C sort -k2,2 -u
+ | LC_ALL=C sort -k1,1 -u
}

# Filter out requirements fulfilled by the module itself.
mod_requires() {
- LC_ALL=C join -t $'\t' -j 2 -v 1 \
+ LC_ALL=C join -t $'\t' -j 1 -v 1 \
<(all_requires "$@") \
<(all_provides "$@") \
| LC_ALL=C sort -k1,1 -u
@@ -55,6 +55,8 @@
exit 0
fi

+export LC_ALL=C
+
check_kabi() {
arch=$(uname -m)
kabi_file="/lib/modules/kabi-current/kabi_whitelist_$arch"
@@ -107,22 +109,24 @@

cat /usr/src/kernels/$kernel/Module.symvers | awk '
BEGIN { FS = "\t" ; OFS = "\t" }
- { print $2 "\t" $1 }
+ { print $2 ":" $1 }
' \
| sed -r -e 's:$:\t'"$kernel"':' \
| LC_ALL=C sort -k1,1 -u > $symvers

# Symbols matching with the kernel get a "kernel" dependency
- LC_ALL=C join -t $'\t' -j 1 $symvers <(mod_requires "${modules[@]}") | LC_ALL=C sort -u \
- | awk '{ FS = "\t" ; OFS = "\t" } { print "kernel(" $1 ") = " $2 }'
+ mod_req=$(mktemp -t mod_req.XXXXX)
+ mod_requires "${modules[@]}" > "$mod_req"
+ LC_ALL=C join -t $'\t' -j 1 $symvers "$mod_req" | LC_ALL=C sort -u \
+ | awk 'BEGIN { FS = "[\t:]" ; OFS = "\t" } { print "kernel(" $1 ") = " $2 }'

# Symbols from elsewhere get a "ksym" dependency
- LC_ALL=C join -t $'\t' -j 1 -v 2 $symvers <(mod_requires "${modules[@]}") | LC_ALL=C sort -u \
- | awk '{ FS = "\t" ; OFS = "\t" } { print "ksym(" $1 ") = " $2 }'
+ LC_ALL=C join -t $'\t' -j 1 -v 2 $symvers "$mod_req" | LC_ALL=C sort -u \
+ | awk 'BEGIN { FS = "[\t:]" ; OFS = "\t" } { print "ksym(" $1 ") = " $2 }'

# Check kABI if the kabi-whitelists package is installed
# Do this last so we can try to output this error at the end
- kabi_check_symbols=($(LC_ALL=C join -t $'\t' -j 1 $symvers <(mod_requires "${modules[@]}") | LC_ALL=C sort -u \
- | awk '{ FS = "\t" ; OFS = "\t" } { print $1 }'))
+ kabi_check_symbols=($(LC_ALL=C join -t $'\t' -j 1 $symvers "$mod_req" | LC_ALL=C sort -u \
+ | awk 'BEGIN { FS = "[\t:]" ; OFS = "\t" } { print $1 }'))
check_kabi "${kabi_check_symbols[@]}"
fi

30
SOURCES/redhat-rpm-config-9.1.0-fix-requires.patch

@ -0,0 +1,30 @@ @@ -0,0 +1,30 @@
commit 635437c7bfe6053dcfe112705b809bb78aba1a73
Author: Panu Matilainen <pmatilai@redhat.com>
Date: Mon Feb 15 13:42:36 2010 +0200

Unbreak find-requires (#443015, #564527)
- regression originating from commit 9ed9b4e3459e3125befd324f579f751a239c26ca
which was supposed to fix something for on ARM but broke pretty much
all else
- this should've been in 9.1.0 but somehow gone missing, ugh...
- fix originally from Bill Nottingham

diff --git a/find-requires b/find-requires
index fa5ab95..eb3ee54 100755
--- a/find-requires
+++ b/find-requires
@@ -106,6 +106,7 @@ for f in $liblist $exelist ; do
print $2 ;
}
}
+ (START==2) && /^[A-Za-z]/ { START=3; }
/^Version References:$/ { START=2; }
(START==2) && /required from/ {
sub(/:/, "", $3);
@@ -114,7 +115,6 @@ for f in $liblist $exelist ; do
(START==2) && (LIBNAME!="") && ($4!="") {
print LIBNAME "(" $4 ")'$lib64'";
}
- /^[A-Za-z]/ { START=3; }
'
done | sort -u

21
SOURCES/redhat-rpm-config-9.1.0-hardened.patch

@ -0,0 +1,21 @@ @@ -0,0 +1,21 @@
diff -up redhat-rpm-config-9.1.0/macros.jx redhat-rpm-config-9.1.0/macros
--- redhat-rpm-config-9.1.0/macros.jx 2011-08-03 15:42:20.267064981 -0400
+++ redhat-rpm-config-9.1.0/macros 2011-08-03 15:44:46.581058603 -0400
@@ -184,8 +184,15 @@ unset DISPLAY\
%__find_provides /usr/lib/rpm/redhat/find-provides
%__find_requires /usr/lib/rpm/redhat/find-requires

-%__global_cflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4
-%__global_ldflags -Wl,-z,relro
+%_hardening_cflags -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1
+%_hardening_ldflags -specs=/usr/lib/rpm/redhat/redhat-hardened-ld
+
+#_hardened_build 0
+%_hardened_cflags %{?_hardened_build:%{_hardening_cflags}}
+%_hardened_ldflags %{?_hardened_build:%{_hardening_ldflags}}
+
+%__global_cflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 %{_hardened_cflags}
+%__global_ldflags -Wl,-z,relro %{_hardened_ldflags}

# Use these macros to differentiate between RH and other KMP implementation(s).
redhat_kernel_module_package 1

14
SOURCES/redhat-rpm-config-9.1.0-jar-repack-perms.patch

@ -0,0 +1,14 @@ @@ -0,0 +1,14 @@
diff -up redhat-rpm-config-9.1.0/brp-java-repack-jars.jar-repack-perms redhat-rpm-config-9.1.0/brp-java-repack-jars
--- redhat-rpm-config-9.1.0/brp-java-repack-jars.jar-repack-perms 2013-07-05 13:21:56.548998671 +0300
+++ redhat-rpm-config-9.1.0/brp-java-repack-jars 2013-07-05 13:22:50.962398381 +0300
@@ -35,8 +35,8 @@ if [ ! -z "$JARS" ]; then

pushd "$JTMPDIR" > /dev/null
/usr/bin/unzip -qq -o "$j"
- find -type d -exec chmod a+rx {} \;
- find -type f -exec chmod a+r {} \;
+ find -type d -exec chmod a+rx,u+w {} \;
+ find -type f -exec chmod a+r,u+w {} \;
rm -f "$j"

# Create the directories first.

16
SOURCES/redhat-rpm-config-9.1.0-java-repack-order.patch

@ -0,0 +1,16 @@ @@ -0,0 +1,16 @@
Index: redhat-rpm-config-9.1.0/brp-java-repack-jars
===================================================================
--- redhat-rpm-config-9.1.0.orig/brp-java-repack-jars
+++ redhat-rpm-config-9.1.0/brp-java-repack-jars
@@ -79,7 +79,10 @@ if [ ! -z "$JARS" ]; then
pushd $JARDIR > /dev/null

if [ -n "`find -not -name '.'`" ]; then
- find * -not -name '.' | LC_ALL=C sort | /usr/bin/zip -q -X -9 $j -@
+ if [ -e META-INF/MANIFEST.MF ]; then
+ /usr/bin/zip -q -X -9 $j META-INF/MANIFEST.MF
+ fi
+ find * -not -name '.' | LC_ALL=C sort | /usr/bin/zip -u -q -X -9 $j -@
else
# Put the empty jar back
touch $j

64
SOURCES/redhat-rpm-config-9.1.0-java-repack-spaces-in-filenames.patch

@ -0,0 +1,64 @@ @@ -0,0 +1,64 @@
Index: redhat-rpm-config-9.1.0/brp-java-repack-jars
===================================================================
--- redhat-rpm-config-9.1.0.orig/brp-java-repack-jars
+++ redhat-rpm-config-9.1.0/brp-java-repack-jars
@@ -25,17 +25,19 @@ if [ ! -z "$JARS" ]; then

# unpack every jar, set the date of the files and directories and
# repack the jar
+ OLD_IFS="$IFS"
+ IFS=$(printf '\n\t')
for j in $JARS ; do
- JARNAME=`basename $j`
- JTMPDIR=`mktemp -d -p $RPM_BUILD_ROOT/tmp $JARNAME.tmpdir.XXXXXXXXXX` || exit 1
- JARDIR=`mktemp -d -p $RPM_BUILD_ROOT/tmp $JARNAME.jardir.XXXXXXXXXX` || exit 1
- TIMEREF=`mktemp -p $RPM_BUILD_ROOT/tmp $JARNAME.timeref.XXXXXXXXXX` || exit 1
+ JARNAME=`basename "$j"`
+ JTMPDIR=`mktemp -d -p $RPM_BUILD_ROOT/tmp "$JARNAME.tmpdir.XXXXXXXXXX"` || exit 1
+ JARDIR=`mktemp -d -p $RPM_BUILD_ROOT/tmp "$JARNAME.jardir.XXXXXXXXXX"` || exit 1
+ TIMEREF=`mktemp -p $RPM_BUILD_ROOT/tmp "$JARNAME.timeref.XXXXXXXXXX"` || exit 1

- pushd $JTMPDIR > /dev/null
- /usr/bin/unzip -qq -o $j
+ pushd "$JTMPDIR" > /dev/null
+ /usr/bin/unzip -qq -o "$j"
find -type d -exec chmod a+rx {} \;
find -type f -exec chmod a+r {} \;
- rm -f $j
+ rm -f "$j"

# Create the directories first.
find -type d | LC_ALL=C sort | while read d; do
@@ -76,24 +78,25 @@ if [ ! -z "$JARS" ]; then
done

# make the jar
- pushd $JARDIR > /dev/null
+ pushd "$JARDIR" > /dev/null

if [ -n "`find -not -name '.'`" ]; then
if [ -e META-INF/MANIFEST.MF ]; then
- /usr/bin/zip -q -X -9 $j META-INF/MANIFEST.MF
+ /usr/bin/zip -q -X -9 "$j" META-INF/MANIFEST.MF
fi
- find * -not -name '.' | LC_ALL=C sort | /usr/bin/zip -u -q -X -9 $j -@
+ find * -not -name '.' | LC_ALL=C sort | /usr/bin/zip -u -q -X -9 "$j" -@
else
# Put the empty jar back
- touch $j
+ touch "$j"
fi
popd > /dev/null

# Cleanup.
- rm -rf $JTMPDIR
- rm -rf $JARDIR
- rm -f $TIMEREF
+ rm -rf "$JTMPDIR"
+ rm -rf "$JARDIR"
+ rm -f "$TIMEREF"
done
+ IFS="$OLD_IFS"

# remove $RPM_BUILD_ROOT/tmp if we created it
if [ $rmtmp -eq 1 ]; then

13
SOURCES/redhat-rpm-config-9.1.0-kernel-source.patch

@ -0,0 +1,13 @@ @@ -0,0 +1,13 @@
Index: redhat-rpm-config-9.1.0/macros
===================================================================
--- redhat-rpm-config-9.1.0.orig/macros
+++ redhat-rpm-config-9.1.0/macros
@@ -239,7 +239,7 @@ kernel_module_package_release 1
done \
fi \
echo "%%global flavors_to_build ${flavors_to_build:-%%nil}" \
- echo "%%global kernel_source() /usr/src/kernels/%kverrel-\\\$([ %%%%{1} = default ] || echo "%%%%{1}-")%_target_cpu" \
+ echo "%%global kernel_source() /usr/src/kernels/%kverrel-\\\$([ %%%%{1} = default ] || echo "%%%%{1}.")%_target_cpu" \
if [ ! -z "%{-f*}" ] \
then \
filelist="%{-f*}" \

99
SOURCES/redhat-rpm-config-9.1.0-kmod-brew-build.patch

@ -0,0 +1,99 @@ @@ -0,0 +1,99 @@
From: Jiri Benc <jbenc@redhat.com>
Subject: Build correctly with z-stream kernels

In brew, there's usually a newer kernel installed than the one used for
installation. Handle this situation correctly by allowing the spec file to
define kernel_version to be used in rpm dependencies, while building against
a compatible newer (z-stream) kernel.

Signed-off-by: Jiri Benc <jbenc@redhat.com>

---
kmodtool | 31 ++++++++++++++++++++++++++++---
macros | 2 +-
2 files changed, 29 insertions(+), 4 deletions(-)

--- a/kmodtool
+++ b/kmodtool
@@ -9,6 +9,7 @@
# Copyright (c) 2003-2010 Ville Skyttä <ville.skytta@iki.fi>,
# Thorsten Leemhuis <fedora@leemhuis.info>
# Jon Masters <jcm@redhat.com>
+# Copyright (c) 2012-2013 Jiri Benc <jbenc@redhat.com>
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
@@ -49,9 +50,25 @@ kver=
verrel=
variant=

+get_kernel_release ()
+{
+ if [[ -z $1 ]]; then
+ uname -r
+ return
+ fi
+ local arch=$(arch)
+ local verrel=${1%.$arch}
+ local verprefix=${verrel%.*}
+ local versuffix=${verrel#$verprefix}
+ verrel=$(ls -Ud /usr/src/kernels/$verprefix*$versuffix.$arch | sort -V | tail -n 1)
+ verrel=${verrel##*/}
+ [[ -z $verrel ]] && verrel=$1.$arch
+ echo "$verrel"
+}
+
get_verrel ()
{
- verrel=${1:-$(uname -r)}
+ verrel=$(get_kernel_release "$1")
verrel=${verrel/%.$knownvariants/}
}

@@ -61,10 +78,16 @@ print_verrel ()
echo "${verrel}"
}

+get_verrel_for_deps ()
+{
+ verrel_dep=${1:-$(uname -r)}
+ verrel_dep=${verrel_dep/%.$knownvariants/}
+}
+
get_variant ()
{
get_verrel $@
- variant=${1:-$(uname -r)}
+ variant=$(get_kernel_release "$1")
variant=${variant/#$verrel?(.)/}
variant=${variant:-'""'}
}
@@ -129,7 +152,7 @@ get_rpmtemplate ()
echo "%global _use_internal_dependency_generator 0"

cat <<EOF
-Provides: kernel-modules >= ${verrel}${dotvariant}
+Provides: kernel-modules >= ${verrel_dep}${dotvariant}
Provides: ${kmod_name}-kmod = %{?epoch:%{epoch}:}%{version}-%{release}
Requires(post): /sbin/depmod
Requires(postun): /sbin/depmod
@@ -206,6 +229,8 @@ print_rpmtemplate ()
shift
kver="${1}"
get_verrel "${1}"
+ get_verrel_for_deps "${1}"
+ [[ -z $kver ]] && kver=$verrel
shift
if [ -z "${kmod_name}" ] ; then
echo "Please provide the kmodule-name as first parameter." >&2
--- a/macros
+++ b/macros
@@ -218,7 +218,7 @@ package or when debugging this package.\
then \
nobuildreqs="yes" \
fi \
- override_filelist="$filelist" override_preamble="$preamble" nobuildreqs="$nobuildreqs" kmod_version=%kmod_version kmod_release=%kmod_release %{kmodtool} rpmtemplate %{-n*}%{!-n:%name} %{kverrel} $flavors_to_build 2>/dev/null \
+ override_filelist="$filelist" override_preamble="$preamble" nobuildreqs="$nobuildreqs" kmod_version=%kmod_version kmod_release=%kmod_release %{kmodtool} rpmtemplate %{-n*}%{!-n:%name} %{kernel_version} $flavors_to_build 2>/dev/null \
)}

#==============================================================================

509
SOURCES/redhat-rpm-config-9.1.0-kmod-kabi.patch

@ -0,0 +1,509 @@ @@ -0,0 +1,509 @@
diff -Nuar redhat-rpm-config-9.1.0_old/find-provides.ksyms redhat-rpm-config-9.1.0/find-provides.ksyms
--- redhat-rpm-config-9.1.0_old/find-provides.ksyms 2013-03-22 10:48:56.344881194 +0800
+++ redhat-rpm-config-9.1.0/find-provides.ksyms 2013-03-22 10:49:31.727892674 +0800
@@ -4,6 +4,7 @@

for module in $(grep -E '/lib/modules/.+\.ko$'); do
nm $module \
- | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):ksym(\2) = \1:p'
+ | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p' \
+ | awk --non-decimal-data '{printf("ksym(%s) = 0x%08x\n", $2, $1)}'
done \
| sort -u
diff -Nuar redhat-rpm-config-9.1.0_old/find-requires redhat-rpm-config-9.1.0/find-requires
--- redhat-rpm-config-9.1.0_old/find-requires 2013-03-22 10:48:56.343881193 +0800
+++ redhat-rpm-config-9.1.0/find-requires 2013-03-22 10:49:31.727892674 +0800
@@ -153,8 +153,7 @@
fi
done

-# Disabling for now while the Fedora kernel doesn't produce kABI deps.
-#[ -x /usr/lib/rpm/redhat/find-requires.ksyms ] && [ "$is_kmod" ] &&
-# printf "%s\n" "${filelist[@]}" | /usr/lib/rpm/redhat/find-requires.ksyms
+[ -x /usr/lib/rpm/redhat/find-requires.ksyms ] && [ "$is_kmod" ] &&
+ printf "%s\n" "${filelist[@]}" | /usr/lib/rpm/redhat/find-requires.ksyms

exit 0
diff -Nuar redhat-rpm-config-9.1.0_old/find-requires.ksyms redhat-rpm-config-9.1.0/find-requires.ksyms
--- redhat-rpm-config-9.1.0_old/find-requires.ksyms 2013-03-22 10:48:56.343881193 +0800
+++ redhat-rpm-config-9.1.0/find-requires.ksyms 2013-03-22 10:49:31.728892676 +0800
@@ -1,20 +1,41 @@
#! /bin/bash
+#
+# This script is called during external module building to create dependencies
+# both upon the RHEL kernel, and on additional external modules. Symbols that
+# cannot be reconciled against those provided by the kernel are assumed to be
+# provided by an external module and "ksym" replaces th regular "kernel" dep.

IFS=$'\n'

+# Extract all of the symbols provided by this module.
all_provides() {
nm "$@" \
- | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):\1\t\2:p' \
- | sort -k2 -u
+ | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p' \
+ | awk --non-decimal-data '{printf("0x%08x\t%s\n", $1, $2)}' \
+ | LANG=C sort -k2,2 -u
}

+# Extract all of the requirements of this module.
all_requires() {
for module in "$@"; do
set -- $(/sbin/modinfo -F vermagic "$module" | sed -e 's: .*::' -e q)
/sbin/modprobe --dump-modversions "$module" \
- | sed -r -e 's:^0x0*::' -e 's:$:\t'"$1"':'
+ | awk --non-decimal-data '
+ BEGIN { FS = "\t" ; OFS = "\t" }
+ {printf("0x%08x\t%s\n", $1, $2)}' \
+ | sed -r -e 's:$:\t'"$1"':'
done \
- | sort -k2 -u
+ | LANG=C sort -k2,2 -u
+}
+
+# Filter out requirements fulfilled by the module itself.
+mod_requires() {
+ module=$1
+
+ LANG=C join -t $'\t' -j 2 -v 1 \
+ <(all_requires "$module") \
+ <(all_provides "$module") \
+ | LANG=C sort -k1,1 -u
}

if ! [ -e /sbin/modinfo -a -e /sbin/modprobe ]; then
@@ -22,27 +43,72 @@
exit 0
fi

+check_kabi() {
+ arch=$(uname -m)
+ kabi_file="/lib/modules/kabi/kabi_whitelist_$arch"
+
+ # If not installed, output a warning and return (continue)
+ if [ ! -f "$kabi_file" ]; then
+ echo "" >&2
+ echo "********************************************************************************" >&2
+ echo "*********************** KERNEL ABI COMPATIBILITY WARNING ***********************" >&2
+ echo "********************************************************************************" >&2
+ echo "The kernel ABI reference files (provided by "kabi-whitelists") were not found." >&2
+ echo "No compatibility check was performed. Please install the kABI reference files" >&2
+ echo "and rebuild if you would like to verify compatibility with kernel ABI." >&2
+ echo "" >&2
+ return
+ fi
+
+ unset non_kabi
+ for symbol in "$@"; do
+ if ! egrep "^[[:space:]]$symbol\$" $kabi_file >/dev/null; then
+ non_kabi=("${non_kabi[@]}" "$symbol")
+ fi
+ done
+
+ if [ ${#non_kabi[@]} -gt 0 ]; then
+ echo "" >&2
+ echo "********************************************************************************" >&2
+ echo "*********************** KERNEL ABI COMPATIBILITY WARNING ***********************" >&2
+ echo "********************************************************************************" >&2
+ echo "The following kernel symbols are not guaranteed to remain compatible with" >&2
+ echo "future kernel updates to this RHEL release:" >&2
+ echo "" >&2
+ for symbol in "${non_kabi[@]}"; do
+ printf "\t$symbol\n" >&2
+ done
+ echo "" >&2
+ echo "Red Hat recommends that you consider using only official kernel ABI symbols" >&2
+ echo "where possible. Requests for additions to the kernel ABI can be filed with" >&2
+ echo "your partner or customer representative (component: driver-update-program)." >&2
+ echo "" >&2
+ fi
+}
+
modules=($(grep -E '/lib/modules/.+\.ko$'))
if [ ${#modules[@]} -gt 0 ]; then
- symset_table=$(mktemp -t ${0##*/}.XXXXX)
- /usr/lib/rpm/redhat/symset-table | sort > $symset_table
+ kernel=$(/sbin/modinfo -F vermagic "${modules[0]}" | sed -e 's: .*::' -e q)
+ symvers=$(mktemp -t ${0##*/}.XXXXX)

- join -t $'\t' -j 1 -a 2 $symset_table <(
- # Filter out requirements that we fulfill ourself.
- join -t $'\t' -j 2 -v 1 \
- <(all_requires "${modules[@]}") \
- <(all_provides "${modules[@]}") \
- | awk '
+ cat /usr/src/kernels/$kernel/Module.symvers | awk '
BEGIN { FS = "\t" ; OFS = "\t" }
- { print $3 "/" $2 "/" $1 }
- ' \
- | sort -u) \
- | sort -u \
- | awk '
- { FS = "\t" ; OFS = "\t" }
- NF == 3 { print "kernel(" $2 ") = " $3
- next }
- { split($1, arr, "/")
- print "ksym(" arr[3] ") = " arr[2] }
- '
+ { print $2 "\t" $1 }
+ ' \
+ | sed -r -e 's:$:\t'"$kernel"':' \
+ | LANG=C sort -k1,1 -u > $symvers
+
+ # Symbols matching with the kernel get a "kernel" dependency
+ LANG=C join -t '\t' -j 1 $symvers <(mod_requires "${modules[@]}") | LANG=C sort -u \
+ | awk '{ FS = "\t" ; OFS = "\t" } { print "kernel(" $1 ") = " $2 }'
+
+ # Symbols from elsewhere get a "ksym" dependency
+ LANG=C join -t '\t' -j 1 -v 2 $symvers <(mod_requires "${modules[@]}") | LANG=C sort -u \
+ | awk '{ FS = "\t" ; OFS = "\t" } { print "ksym(" $1 ") = " $2 }'
+
+ # Check kABI if the kabi-whitelists package is installed
+ # Do this last so we can try to output this error at the end
+ kabi_check_symbols=($(LANG=C join -t '\t' -j 1 $symvers <(mod_requires "${modules[@]}") | LANG=C sort -u \
+ | awk '{ FS = "\t" ; OFS = "\t" } { print $1 }'))
+ check_kabi "${kabi_check_symbols[@]}"
fi
diff -Nuar redhat-rpm-config-9.1.0_old/kmodtool redhat-rpm-config-9.1.0/kmodtool
--- redhat-rpm-config-9.1.0_old/kmodtool 2013-03-22 10:48:56.344881194 +0800
+++ redhat-rpm-config-9.1.0/kmodtool 2013-03-22 10:49:58.453903908 +0800
@@ -1,7 +1,12 @@
#!/bin/bash

# kmodtool - Helper script for building kernel module RPMs
-# Copyright (c) 2003-2006 Ville Skyttä <ville.skytta@iki.fi>,
+# An original version appeared in Fedora. This version is
+# generally called only by the %kernel_module_package RPM macro
+# during the process of building Driver Update Packages (which
+# are also known as "kmods" in the Fedora community).
+#
+# Copyright (c) 2003-2010 Ville Skyttä <ville.skytta@iki.fi>,
# Thorsten Leemhuis <fedora@leemhuis.info>
# Jon Masters <jcm@redhat.com>
#
@@ -24,21 +29,30 @@
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

+# Changelog:
+#
+# 2010/07/28 - Add fixes for filelists in line with LF standard
+# - Remove now defunct "framepointer" kernel variant
+# - Change version to "rhel6-rh2" as a consequence.
+#
+# 2010/01/10 - Simplified for RHEL6. We are working on upstream
+# moving to a newer format and in any case do not
+# need to retain support for really old systems.
+
shopt -s extglob

myprog="kmodtool"
myver="0.10.10_kmp2"
-knownvariants=@(BOOT|PAE|@(big|huge)mem|debug|enterprise|kdump|?(large)smp|uml|xen[0U]?(-PAE)|xen)
+knownvariants=@(debug|kdump)
kmod_name=
kver=
verrel=
variant=
-kmp=

get_verrel ()
{
verrel=${1:-$(uname -r)}
- verrel=${verrel%%$knownvariants}
+ verrel=${verrel/%.$knownvariants/}
}

print_verrel ()
@@ -51,7 +65,7 @@
{
get_verrel $@
variant=${1:-$(uname -r)}
- variant=${variant##$verrel}
+ variant=${variant/#$verrel?(.)/}
variant=${variant:-'""'}
}

@@ -61,117 +75,128 @@
echo "${variant}"
}

+get_filelist() {
+ local IFS=$'\n'
+ filelist=($(cat))
+
+ if [ ${#filelist[@]} -gt 0 ];
+ then
+ for ((n = 0; n < ${#filelist[@]}; n++));
+ do
+ line="${filelist[n]}"
+ line=$(echo "$line" \
+ | sed -e "s/%verrel/$verrel/g" \
+ | sed -e "s/%variant/$variant/g" \
+ | sed -e "s/%dashvariant/$dashvariant/g" \
+ | sed -e "s/%dotvariant/$dotvariant/g" \
+ | sed -e "s/\.%1/$dotvariant/g" \
+ | sed -e "s/\-%1/$dotvariant/g" \
+ | sed -e "s/%2/$verrel/g")
+ echo "$line"
+ done
+ else
+ echo "%defattr(644,root,root,755)"
+ echo "/lib/modules/${verrel}${dotvariant}"
+ fi
+}
+
+
get_rpmtemplate ()
{
local variant="${1}"
local dashvariant="${variant:+-${variant}}"
- case "$verrel" in
- *.el*) kdep="kernel${dashvariant}-%{_target_cpu} = ${verrel}" ;;
- *.EL*) kdep="kernel${dashvariant}-%{_target_cpu} = ${verrel}" ;;
- *) kdep="kernel-%{_target_cpu} = ${verrel}${variant}" ;;
- esac
+ local dotvariant="${variant:+.${variant}}"

echo "%package -n kmod-${kmod_name}${dashvariant}"

- if [ -z "$kmp_provides_summary" ]; then
+ if [ -z "$kmod_provides_summary" ]; then
echo "Summary: ${kmod_name} kernel module(s)"
fi

- if [ -z "$kmp_provides_group" ]; then
+ if [ -z "$kmod_provides_group" ]; then
echo "Group: System Environment/Kernel"
fi

- if [ ! -z "$kmp_version" ]; then
- echo "Version: %{kmp_version}"
+ if [ ! -z "$kmod_version" ]; then
+ echo "Version: %{kmod_version}"
fi

- if [ ! -z "$kmp_release" ]; then
- echo "Release: %{kmp_release}"
+ if [ ! -z "$kmod_release" ]; then
+ echo "Release: %{kmod_release}"
fi

- if [ ! -z "$kmp" ]; then
- echo "%global _use_internal_dependency_generator 0"
- fi
-
- cat <<EOF
-Provides: kernel-modules = ${verrel}${variant}
-Provides: ${kmod_name}-kmod = %{?epoch:%{epoch}:}%{version}-%{release}
-EOF
-
- if [ -z "$kmp" ]; then
- echo "Requires: ${kdep}"
- fi
-
-#
-# RHEL5 - Remove common package requirement on general kmod packages.
-# Requires: ${kmod_name}-kmod-common >= %{?epoch:%{epoch}:}%{version}
-#
+ # Turn of the internal dep generator so we will use the kmod scripts.
+ echo "%global _use_internal_dependency_generator 0"

cat <<EOF
+Provides: kernel-modules >= ${verrel}${dotvariant}
+Provides: ${kmod_name}-kmod = %{?epoch:%{epoch}:}%{version}-%{release}
Requires(post): /sbin/depmod
Requires(postun): /sbin/depmod
EOF

-if [ "no" != "$kmp_nobuildreqs" ]
-then
- echo "BuildRequires: kernel${dashvariant}-devel-%{_target_cpu} = ${verrel}"
-fi
+ if [ "yes" != "$nobuildreqs" ]
+ then
+ echo "BuildRequires: kernel${dashvariant}-devel"
+ fi

-if [ "" != "$kmp_override_preamble" ]
-then
- cat "$kmp_override_preamble"
-fi
+ if [ "" != "$override_preamble" ]
+ then
+ cat "$override_preamble"
+ fi

cat <<EOF
%description -n kmod-${kmod_name}${dashvariant}
-This package provides the ${kmod_name} kernel modules built for the Linux
-kernel ${verrel}${variant} for the %{_target_cpu} family of processors.
+This package provides the ${kmod_name} kernel modules built for
+the Linux kernel ${verrel}${dotvariant} for the %{_target_cpu}
+family of processors.
+EOF
+
+##############################################################################
+## The following are not part of this script directly, they are scripts ##
+## that will be executed by RPM during various stages of package processing ##
+##############################################################################
+
+cat <<EOF
%post -n kmod-${kmod_name}${dashvariant}
-if [ -e "/boot/System.map-${verrel}${variant}" ]; then
- /sbin/depmod -aeF "/boot/System.map-${verrel}${variant}" "${verrel}${variant}" > /dev/null || :
+if [ -e "/boot/System.map-${verrel}${dotvariant}" ]; then
+ /sbin/depmod -aeF "/boot/System.map-${verrel}${dotvariant}" "${verrel}${dotvariant}" > /dev/null || :
fi
-EOF
-
- if [ ! -z "$kmp" ]; then
- cat <<EOF

-modules=( \$(find /lib/modules/${verrel}${variant}/extra/${kmod_name}) )
+modules=( \$(find /lib/modules/${verrel}${dotvariant}/extra/${kmod_name} | grep '\.ko$') )
if [ -x "/sbin/weak-modules" ]; then
printf '%s\n' "\${modules[@]}" \
| /sbin/weak-modules --add-modules
fi
+EOF
+
+cat <<EOF
%preun -n kmod-${kmod_name}${dashvariant}
-rpm -ql kmod-${kmod_name}${dashvariant} | grep '\.ko$' \
- > /var/run/rpm-kmod-${kmod_name}${dashvariant}-modules
+rpm -ql kmod-${kmod_name}${dashvariant}-%{kmod_version}-%{kmod_release}.$(arch) | grep '\.ko$' > /var/run/rpm-kmod-${kmod_name}${dashvariant}-modules
EOF

- fi
-
- cat <<EOF
+cat <<EOF
%postun -n kmod-${kmod_name}${dashvariant}
-/sbin/depmod -aF /boot/System.map-${verrel}${variant} ${verrel}${variant} &> /dev/null || :
-EOF
-
- if [ ! -z "$kmp" ]; then
- cat <<EOF
+if [ -e "/boot/System.map-${verrel}${dotvariant}" ]; then
+ /sbin/depmod -aeF "/boot/System.map-${verrel}${dotvariant}" "${verrel}${dotvariant}" > /dev/null || :
+fi
+
modules=( \$(cat /var/run/rpm-kmod-${kmod_name}${dashvariant}-modules) )
-#rm /var/run/rpm-kmod-${kmod_name}${dashvariant}-modules
+rm /var/run/rpm-kmod-${kmod_name}${dashvariant}-modules
if [ -x "/sbin/weak-modules" ]; then
printf '%s\n' "\${modules[@]}" \
| /sbin/weak-modules --remove-modules
fi
EOF
- fi

echo "%files -n kmod-${kmod_name}${dashvariant}"

-if [ "" == "$kmp_override_filelist" ];
+if [ "" == "$override_filelist" ];
then
echo "%defattr(644,root,root,755)"
- echo "/lib/modules/${verrel}${variant}/"
- echo "/lib/firmware/"
+ echo "/lib/modules/${verrel}${dotvariant}"
else
- cat "$kmp_override_filelist"
+ cat "$override_filelist" | get_filelist
fi
}

@@ -216,8 +241,6 @@
- Get variant from uname.
rpmtemplate <mainpgkname> <uname> <variants>
- Return a template for use in a source RPM
- rpmtemplate_kmp <mainpgkname> <uname> <variants>
- - Return a template for use in a source RPM with KMP dependencies
version
- Output version number and exit.
EOF
@@ -241,12 +264,6 @@
print_rpmtemplate "$@"
exit $?
;;
- rpmtemplate_kmp)
- shift
- kmp=1
- print_rpmtemplate "$@"
- exit $?
- ;;
version)
echo "${myprog} ${myver}"
exit 0
diff -Nuar redhat-rpm-config-9.1.0_old/macros redhat-rpm-config-9.1.0/macros
--- redhat-rpm-config-9.1.0_old/macros 2013-03-22 10:48:56.344881194 +0800
+++ redhat-rpm-config-9.1.0/macros 2013-03-22 10:49:31.730892680 +0800
@@ -175,8 +175,8 @@
%__global_ldflags -Wl,-z,relro %{_hardened_ldflags}

# Use these macros to differentiate between RH and other KMP implementation(s).
-redhat_kernel_module_package 1
-kernel_module_package_release 1
+%global redhat_kernel_module_package 1
+%global kernel_module_package_release 1

#kernel_module_package [ -n name ] [ -v version ] [ -r release ] [ -s script ]
# [ -f filelist] [ -x ] [ -p preamble ] flavor flavor ...
@@ -185,40 +185,27 @@
kernel-devel

%kernel_module_package(n:v:r:s:f:xp:) %{expand:%( \
- %define kmodtool %{-s*}%{!-s:/usr/lib/rpm/redhat/kmodtool} \
- %define kmp_version %{-v*}%{!-v:%{version}} \
- %define kmp_release %{-r*}%{!-r:%{release}} \
- %define latest_kernel %(rpm -q --qf '%{VERSION}-%{RELEASE}\\\\n' `rpm -q kernel-devel | /usr/lib/rpm/redhat/rpmsort -r | head -n 1` | head -n 1) \
+ %global kmodtool %{-s*}%{!-s:/usr/lib/rpm/redhat/kmodtool} \
+ %global kmod_version %{-v*}%{!-v:%{version}} \
+ %global kmod_release %{-r*}%{!-r:%{release}} \
+ %global latest_kernel %(rpm -q --qf '%{VERSION}-%{RELEASE}.%{ARCH}\\\\n' `rpm -q kernel-devel | /usr/lib/rpm/redhat/rpmsort -r | head -n 1` | head -n 1) \
%{!?kernel_version:%{expand:%%global kernel_version %{latest_kernel}}} \
%global kverrel %(%{kmodtool} verrel %{?kernel_version} 2>/dev/null) \
flavors="default" \
- if [ "i686" == "%{_target_cpu}" ] || [ "x86_64" == "%{_target_cpu}" ] \
- then \
- xenver=$(rpm -q kernel-xen-devel-%{kverrel}|head -n 1)\
- kdver=$(rpm -q kernel-kdump-devel-%{kverrel}|head -n 1)\
- if [ "kernel-xen-devel-%{kverrel}" == "$xenver" ] \
- then \
- flavors="$flavors xen" \
- fi \
- if [ "kernel-kdump-devel-%{kverrel}" == "$kdver" ] \
- then \
- flavors="$flavors kdump" \
- fi \
- fi \
if [ -z "%*" ]; then \
flavors_to_build=$flavors \
elif [ -z "%{-x}" ]; then \
flavors_to_build="%*" \
else \
flavors_to_build=" $flavors "\
- echo "[$flavors_to_build]" >/tmp/tmp.txt
for i in %* \
do \
flavors_to_build=${flavors_to_build//$i /}
done \
fi \
echo "%%global flavors_to_build ${flavors_to_build:-%%nil}" \
- echo "%%global kernel_source() /usr/src/kernels/%kverrel-\\\$([ %%%%{1} = default ] || echo "%%%%{1}.")%_target_cpu" \
+ echo "%%global kernel_source() /usr/src/kernels/%kverrel\\\$([ %%%%{1} = default ] || echo ".%%%%{1}")" \
+ echo "%%global kernel_module_package_moddir() extra" \
if [ ! -z "%{-f*}" ] \
then \
filelist="%{-f*}" \
@@ -231,7 +218,7 @@
then \
nobuildreqs="yes" \
fi \
- kmp_override_filelist="$filelist" kmp_override_preamble="$preamble" kmp_nobuildreqs="$buildreqs" %{kmodtool} rpmtemplate_kmp %{-n*}%{!-n:%name} %{kverrel} $flavors_to_build 2>/dev/null \
+ override_filelist="$filelist" override_preamble="$preamble" nobuildreqs="$nobuildreqs" kmod_version=%kmod_version kmod_release=%kmod_release %{kmodtool} rpmtemplate %{-n*}%{!-n:%name} %{kverrel} $flavors_to_build 2>/dev/null \
)}

#==============================================================================

58
SOURCES/redhat-rpm-config-9.1.0-ksym-requires-multifile.patch

@ -0,0 +1,58 @@ @@ -0,0 +1,58 @@
--- redhat-rpm-config-9.1.0/find-requires.ksyms.old 2017-07-24 13:41:12.836294124 +0200
+++ redhat-rpm-config-9.1.0/find-requires.ksyms 2017-07-24 13:42:09.445228749 +0200
@@ -25,17 +25,15 @@ all_requires() {
{printf("0x%08x\t%s\n", $1, $2)}' \
| sed -r -e 's:$:\t'"$1"':'
done \
- | LANG=C sort -k2,2 -u
+ | LC_ALL=C sort -k2,2 -u
}

# Filter out requirements fulfilled by the module itself.
mod_requires() {
- module=$1
-
- LANG=C join -t $'\t' -j 2 -v 1 \
- <(all_requires "$module") \
- <(all_provides "$module") \
- | LANG=C sort -k1,1 -u
+ LC_ALL=C join -t $'\t' -j 2 -v 1 \
+ <(all_requires "$@") \
+ <(all_provides "$@") \
+ | LC_ALL=C sort -k1,1 -u
}

if ! [ -e /sbin/modinfo -a -e /sbin/modprobe ]; then
@@ -89,6 +87,8 @@ check_kabi() {
modules=($(grep -E '/lib/modules/.+\.ko$'))
if [ ${#modules[@]} -gt 0 ]; then
kernel=$(/sbin/modinfo -F vermagic "${modules[0]}" | sed -e 's: .*::' -e q)
+
+ # get all that kernel provides
symvers=$(mktemp -t ${0##*/}.XXXXX)

cat /usr/src/kernels/$kernel/Module.symvers | awk '
@@ -96,19 +96,19 @@ if [ ${#modules[@]} -gt 0 ]; then
{ print $2 "\t" $1 }
' \
| sed -r -e 's:$:\t'"$kernel"':' \
- | LANG=C sort -k1,1 -u > $symvers
+ | LC_ALL=C sort -k1,1 -u > $symvers

# Symbols matching with the kernel get a "kernel" dependency
- LANG=C join -t '\t' -j 1 $symvers <(mod_requires "${modules[@]}") | LANG=C sort -u \
+ LC_ALL=C join -t $'\t' -j 1 $symvers <(mod_requires "${modules[@]}") | LC_ALL=C sort -u \
| awk '{ FS = "\t" ; OFS = "\t" } { print "kernel(" $1 ") = " $2 }'

# Symbols from elsewhere get a "ksym" dependency
- LANG=C join -t '\t' -j 1 -v 2 $symvers <(mod_requires "${modules[@]}") | LANG=C sort -u \
+ LC_ALL=C join -t $'\t' -j 1 -v 2 $symvers <(mod_requires "${modules[@]}") | LC_ALL=C sort -u \
| awk '{ FS = "\t" ; OFS = "\t" } { print "ksym(" $1 ") = " $2 }'

# Check kABI if the kabi-whitelists package is installed
# Do this last so we can try to output this error at the end
- kabi_check_symbols=($(LANG=C join -t '\t' -j 1 $symvers <(mod_requires "${modules[@]}") | LANG=C sort -u \
+ kabi_check_symbols=($(LC_ALL=C join -t $'\t' -j 1 $symvers <(mod_requires "${modules[@]}") | LC_ALL=C sort -u \
| awk '{ FS = "\t" ; OFS = "\t" } { print $1 }'))
check_kabi "${kabi_check_symbols[@]}"
fi

31
SOURCES/redhat-rpm-config-9.1.0-ksyms-2.patch

@ -0,0 +1,31 @@ @@ -0,0 +1,31 @@
--- redhat-rpm-config-9.1.0/find-requires.ksyms.old 2017-11-14 10:18:23.231861697 +0100
+++ redhat-rpm-config-9.1.0/find-requires.ksyms 2017-11-14 10:51:09.064436672 +0100
@@ -9,10 +9,24 @@ IFS=$'\n'

# Extract all of the symbols provided by this module.
all_provides() {
- nm "$@" \
- | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p' \
- | awk --non-decimal-data '{printf("0x%08x\t%s\n", $1, $2)}' \
- | LANG=C sort -k2,2 -u
+ if [[ -n $(nm "$@" | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p') ]]; then
+ nm "$@" \
+ | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p' \
+ | awk --non-decimal-data '{printf("0x%08x\t%s\n", $1, $2)}' \
+ | LC_ALL=C sort -k2,2 -u
+ else
+ ELFRODATA=$(readelf -R .rodata "$@" | awk '/0x/{printf $2$3$4$5}')
+ if [[ -n $(readelf -h "$@" | grep "little endian") ]]; then
+ RODATA=$(echo $ELFRODATA | sed 's/\(..\)\(..\)\(..\)\(..\)/\4\3\2\1/g')
+ else
+ RODATA=$ELFRODATA
+ fi
+ for sym in $(nm "$@" | sed -r -ne 's:^0*([0-9a-f]+) R __crc_(.+):0x\1 \2:p'); do
+ echo $sym $RODATA
+ done \
+ | awk --non-decimal-data '{printf("0x%08s\t%s\n", substr($3,($1*2)+1,8), $2)}' \
+ | LC_ALL=C sort -k2,2 -u
+ fi
}

# Extract all of the requirements of this module.

33
SOURCES/redhat-rpm-config-9.1.0-ksyms.patch

@ -0,0 +1,33 @@ @@ -0,0 +1,33 @@
--- current/find-provides.ksyms.orig 2017-10-04 15:25:12.448353956 +0200
+++ current/find-provides.ksyms 2017-10-04 15:29:10.086785421 +0200
@@ -1,10 +1,24 @@
-#! /bin/sh
+#! /bin/bash

IFS=$'\n'

for module in $(grep -E '/lib/modules/.+\.ko$'); do
- nm $module \
- | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p' \
- | awk --non-decimal-data '{printf("ksym(%s) = 0x%08x\n", $2, $1)}'
-done \
-| sort -u
+ if [[ -n $(nm $module | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p') ]]; then
+ nm $module \
+ | sed -r -ne 's:^0*([0-9a-f]+) A __crc_(.+):0x\1 \2:p' \
+ | awk --non-decimal-data '{printf("ksym(%s) = 0x%08x\n", $2, $1)}' \
+ | LC_ALL=C sort -u
+ else
+ ELFRODATA=$(readelf -R .rodata $module | awk '/0x/{printf $2$3$4$5}')
+ if [[ -n $(readelf -h $module | grep "little endian") ]]; then
+ RODATA=$(echo $ELFRODATA | sed 's/\(..\)\(..\)\(..\)\(..\)/\4\3\2\1/g')
+ else
+ RODATA=$ELFRODATA
+ fi
+ for sym in $(nm $module | sed -r -ne 's:^0*([0-9a-f]+) R __crc_(.+):0x\1 \2:p'); do
+ echo $sym $RODATA
+ done \
+ | awk --non-decimal-data '{printf("ksym(%s) = 0x%08s\n", $2, substr($3,($1*2)+1,8))}' \
+ | LC_ALL=C sort -u
+ fi
+done

10
SOURCES/redhat-rpm-config-9.1.0-minidebuginfo.patch

@ -0,0 +1,10 @@ @@ -0,0 +1,10 @@
--- redhat-rpm-config-9.1.0/macros 2012-06-11 11:48:58.144578684 +0200
+++ redhat-rpm-config-9.1.0/macros.minidebug 2012-06-11 11:49:18.444255286 +0200
@@ -22,6 +22,7 @@
%_fmoddir %{_libdir}/gfortran/modules

%_enable_debug_packages 1
+%_include_minidebuginfo 1

#==============================================================================
# ---- configure and makeinstall.

6
SOURCES/redhat-rpm-config-9.1.0-mono-ppc64le-aarch64-support.patch

@ -0,0 +1,6 @@ @@ -0,0 +1,6 @@
--- redhat-rpm-config-9.1.0/macros.mono-srpm.old 2018-04-23 11:17:21.066577176 +0200
+++ redhat-rpm-config-9.1.0/macros.mono-srpm 2018-04-23 11:19:05.557896608 +0200
@@ -1,2 +1,2 @@
# arches that mono builds on
-%mono_arches %{ix86} x86_64 sparc sparcv9 ia64 %{arm} alpha s390x ppc ppc64
+%mono_arches %{ix86} x86_64 sparc sparcv9 ia64 %{arm} aarch64 alpha s390x ppc ppc64 ppc64le

19
SOURCES/redhat-rpm-config-9.1.0-ncpus-max.patch

@ -0,0 +1,19 @@ @@ -0,0 +1,19 @@
diff -up redhat-rpm-config-9.1.0/macros.ncpus redhat-rpm-config-9.1.0/macros
--- redhat-rpm-config-9.1.0/macros.ncpus 2013-06-27 09:54:38.663039820 +0300
+++ redhat-rpm-config-9.1.0/macros 2013-06-27 09:54:50.746135882 +0300
@@ -71,10 +71,13 @@
infodir=%{?buildroot:%{buildroot}}%{_infodir} \\\
install

+# Maximum number of CPU's to use when building, 0 for unlimited.
+%_smp_ncpus_max 16
%_smp_mflags %([ -z "$RPM_BUILD_NCPUS" ] \\\
&& RPM_BUILD_NCPUS="`/usr/bin/getconf _NPROCESSORS_ONLN`"; \\\
- if [ "$RPM_BUILD_NCPUS" -gt 16 ]; then echo "-j16"; \\\
- elif [ "$RPM_BUILD_NCPUS" -gt 1 ]; then echo "-j$RPM_BUILD_NCPUS"; fi)
+ ncpus_max=%{?_smp_ncpus_max}; \\\
+ if [ -n "$ncpus_max" ] && [ "$ncpus_max" -gt 0 ] && [ "$RPM_BUILD_NCPUS" -gt "$ncpus_max" ]; then RPM_BUILD_NCPUS="$ncpus_max"; fi; \\\
+ if [ "$RPM_BUILD_NCPUS" -gt 1 ]; then echo "-j$RPM_BUILD_NCPUS"; fi)

#==============================================================================
# ---- Build policy macros.

27
SOURCES/redhat-rpm-config-9.1.0-no-strip-note.patch

@ -0,0 +1,27 @@ @@ -0,0 +1,27 @@
commit 055d0b77e1e2823daef60a4c2b201531dc0c7248
Author: Panu Matilainen <pmatilai@redhat.com>
Date: Mon Mar 1 10:58:17 2010 +0200

Don't run brp-strip-comment-note when find-debuginfo.sh is run (#568924)
- brp-strip-comment-note is not only unnecessary here but is also
now messing up things by resetting EI_OSABI to zero (#568921)
- patch from Roland McGrath

diff --git a/macros b/macros
index 7721fe0..1ac46d7 100644
--- a/macros
+++ b/macros
@@ -92,9 +92,11 @@

%__os_install_post \
/usr/lib/rpm/redhat/brp-compress \
- %{!?__debug_package:/usr/lib/rpm/redhat/brp-strip %{__strip}} \
- /usr/lib/rpm/redhat/brp-strip-static-archive %{__strip} \
+ %{!?__debug_package:\
+ /usr/lib/rpm/redhat/brp-strip %{__strip} \
/usr/lib/rpm/redhat/brp-strip-comment-note %{__strip} %{__objdump} \
+ } \
+ /usr/lib/rpm/redhat/brp-strip-static-archive %{__strip} \
/usr/lib/rpm/brp-python-bytecompile %{__python} %{?_python_bytecompile_errors_terminate_build} \
/usr/lib/rpm/redhat/brp-python-hardlink \
%{!?__jar_repack:/usr/lib/rpm/redhat/brp-java-repack-jars} \

19
SOURCES/redhat-rpm-config-9.1.0-perfbuild.patch

@ -0,0 +1,19 @@ @@ -0,0 +1,19 @@
diff -up redhat-rpm-config-9.1.0/macros.perf_build redhat-rpm-config-9.1.0/macros
--- redhat-rpm-config-9.1.0/macros.perf_build 2014-01-10 14:27:21.038112706 +0200
+++ redhat-rpm-config-9.1.0/macros 2014-01-10 14:27:25.410106657 +0200
@@ -178,7 +178,14 @@ package or when debugging this package.\
%_hardened_cflags %{?_hardened_build:%{_hardening_cflags}}
%_hardened_ldflags %{?_hardened_build:%{_hardening_ldflags}}

-%__global_cflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches %{_hardened_cflags}
+#%_performance_build 0
+%_performance_cflags %{?_performance_build:%{lua:\
+local tcpu = rpm.expand("%{_target_cpu}")
+if string.find(tcpu, "^ppc64") then\
+ print("-O3")\
+end}}
+
+%__global_cflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches %{_hardened_cflags} %{_performance_cflags}
%__global_ldflags -Wl,-z,relro %{_hardened_ldflags}

# Use these macros to differentiate between RH and other KMP implementation(s).

11
SOURCES/redhat-rpm-config-9.1.0-pkgconfig-private.patch

@ -0,0 +1,11 @@ @@ -0,0 +1,11 @@
--- redhat-rpm-config-9.1.0/find-requires.pkgconfig 2010-05-26 19:38:28.892598734 -0400
+++ redhat-rpm-config-9.1.0/find-requires.pkgconfig.new-pkgconfig 2010-05-26 19:39:40.174602325 -0400
@@ -4,7 +4,7 @@ test -x $pkgconfig || exit 0
while read filename ; do
case "${filename}" in
*.pc)
- $pkgconfig --print-requires "$filename" 2> /dev/null | while read n r v ; do
+ $pkgconfig --print-requires --print-requires-private "$filename" 2> /dev/null | while read n r v ; do
echo "pkgconfig($n)" "$r" "$v"
done
esac

14
SOURCES/redhat-rpm-config-9.1.0-ppc-no-minimal-toc.patch

@ -0,0 +1,14 @@ @@ -0,0 +1,14 @@
--- redhat-rpm-config-9.1.0-orig/rpmrc 2012-01-15 12:17:17.320694234 -0600
+++ redhat-rpm-config-9.1.0/rpmrc 2012-01-15 12:19:36.883275451 -0600
@@ -27,9 +27,9 @@
optflags: ppc %{__global_cflags} -m32
optflags: ppciseries %{__global_cflags} -m32
optflags: ppcpseries %{__global_cflags} -m32
-optflags: ppc64 %{__global_cflags} -m64 -mminimal-toc
-optflags: ppc64iseries %{__global_cflags} -m64 -mminimal-toc
-optflags: ppc64pseries %{__global_cflags} -m64 -mminimal-toc
+optflags: ppc64 %{__global_cflags} -m64
+optflags: ppc64iseries %{__global_cflags} -m64
+optflags: ppc64pseries %{__global_cflags} -m64
optflags: ppc8260 %{__global_cflags} -m32
optflags: ppc8560 %{__global_cflags} -m32

31
SOURCES/redhat-rpm-config-9.1.0-ppc64le.patch

@ -0,0 +1,31 @@ @@ -0,0 +1,31 @@
--- ./redhat-rpm-config-9.1.0/macros.orig 2014-04-03 14:16:43.268991281 -0500
+++ ./redhat-rpm-config-9.1.0/macros 2014-04-03 14:16:49.720110279 -0500
@@ -24,6 +24,10 @@
%_enable_debug_packages 1
%_include_minidebuginfo 1

+# Set to enforce patching libtool.m4 and associated configure files
+# to handle ppc64le.
+%_libtool_ppc64le_fix 1
+
#==============================================================================
# ---- configure and makeinstall.
#
@@ -34,6 +36,7 @@
FFLAGS="${FFLAGS:-%optflags -I%_fmoddir}" ; export FFLAGS ; \
FCFLAGS="${FCFLAGS:-%optflags -I%_fmoddir}" ; export FCFLAGS ; \
LDFLAGS="${LDFLAGS:-%__global_ldflags}"; export LDFLAGS; \
+ [ "%_libtool_ppc64le_fix" == 1 ] && [ "%_arch" == ppc64le ] && /usr/lib/rpm/redhat/libtool-handle-ppc64le.sh ; \
for i in $(find . -name config.guess -o -name config.sub) ; do \
[ -f /usr/lib/rpm/redhat/$(basename $i) ] && %{__rm} -f $i && %{__cp} -fv /usr/lib/rpm/redhat/$(basename $i) $i ; \
done ; \
--- ./redhat-rpm-config-9.1.0/rpmrc.orig 2014-04-07 14:11:22.818988723 -0700
+++ ./redhat-rpm-config-9.1.0/rpmrc 2014-04-07 14:16:50.407258196 -0700
@@ -28,6 +28,7 @@
optflags: ppciseries %{__global_cflags} -m32
optflags: ppcpseries %{__global_cflags} -m32
optflags: ppc64 %{__global_cflags} -m64 -mcpu=power7 -mtune=power7
+optflags: ppc64le %{__global_cflags} -m64 -mcpu=power8 -mtune=power8
optflags: ppc64iseries %{__global_cflags} -m64
optflags: ppc64pseries %{__global_cflags} -m64
optflags: ppc8260 %{__global_cflags} -m32

15
SOURCES/redhat-rpm-config-9.1.0-python-hardlink-spaces-in-filenames.patch

@ -0,0 +1,15 @@ @@ -0,0 +1,15 @@
diff --git a/brp-python-hardlink b/brp-python-hardlink
index a937529..210d69c 100755
--- a/brp-python-hardlink
+++ b/brp-python-hardlink
@@ -10,8 +10,8 @@ fi
find "$RPM_BUILD_ROOT" -type f -name "*.pyc" | while read pyc ; do
pyo="$(echo $pyc | sed -e 's/.pyc$/.pyo/')"
if [ -f "$pyo" ] ; then
- csha="$(sha1sum -b $pyc | cut -d' ' -f 1)" && \
- osha="$(sha1sum -b $pyo | cut -d' ' -f 1)" && \
+ csha="$(sha1sum -b "$pyc" | cut -d' ' -f 1)" && \
+ osha="$(sha1sum -b "$pyo" | cut -d' ' -f 1)" && \
if [ "$csha" = "$osha" ] ; then
ln -f "$pyc" "$pyo"
fi

12
SOURCES/redhat-rpm-config-9.1.0-record-switches.patch

@ -0,0 +1,12 @@ @@ -0,0 +1,12 @@
diff -up redhat-rpm-config-9.1.0/macros.record-switches redhat-rpm-config-9.1.0/macros
--- redhat-rpm-config-9.1.0/macros.record-switches 2013-04-22 13:17:29.319358036 +0300
+++ redhat-rpm-config-9.1.0/macros 2013-04-22 13:17:44.665308442 +0300
@@ -171,7 +171,7 @@ package or when debugging this package.\
%_hardened_cflags %{?_hardened_build:%{_hardening_cflags}}
%_hardened_ldflags %{?_hardened_build:%{_hardening_ldflags}}

-%__global_cflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 %{_hardened_cflags}
+%__global_cflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -grecord-gcc-switches %{_hardened_cflags}
%__global_ldflags -Wl,-z,relro %{_hardened_ldflags}

# Use these macros to differentiate between RH and other KMP implementation(s).

19
SOURCES/redhat-rpm-config-9.1.0-relro.patch

@ -0,0 +1,19 @@ @@ -0,0 +1,19 @@
diff -up redhat-rpm-config-9.1.0/macros.jx redhat-rpm-config-9.1.0/macros
--- redhat-rpm-config-9.1.0/macros.jx 2011-07-07 13:10:18.000000000 -0400
+++ redhat-rpm-config-9.1.0/macros 2011-07-07 13:12:00.299594529 -0400
@@ -31,6 +31,7 @@
CFLAGS="${CFLAGS:-%optflags}" ; export CFLAGS ; \
CXXFLAGS="${CXXFLAGS:-%optflags}" ; export CXXFLAGS ; \
FFLAGS="${FFLAGS:-%optflags -I%_fmoddir}" ; export FFLAGS ; \
+ LDFLAGS="${LDFLAGS:-%__global_ldflags}"; export LDFLAGS; \
%{_configure} --build=%{_build} --host=%{_host} \\\
--program-prefix=%{?_program_prefix} \\\
--disable-dependency-tracking \\\
@@ -184,6 +185,7 @@ unset DISPLAY\
%__find_requires /usr/lib/rpm/redhat/find-requires

%__global_cflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4
+%__global_ldflags -Wl,-z,relro

# Use these macros to differentiate between RH and other KMP implementation(s).
redhat_kernel_module_package 1

21
SOURCES/redhat-rpm-config-9.1.0-repack-jars.patch

@ -0,0 +1,21 @@ @@ -0,0 +1,21 @@
--- redhat-rpm-config-9.1.0/brp-java-repack-jars.orig 2016-05-11 16:19:41.026993150 +0200
+++ redhat-rpm-config-9.1.0/brp-java-repack-jars 2016-05-11 16:22:14.621444942 +0200
@@ -28,6 +28,8 @@
OLD_IFS="$IFS"
IFS=$(printf '\n\t')
for j in $JARS ; do
+ JAROWN=`ls -l $j | cut -d' ' -f3`
+ JARGRP=`ls -l $j | cut -d' ' -f4`
JARNAME=`basename "$j"`
JTMPDIR=`mktemp -d -p $RPM_BUILD_ROOT/tmp "$JARNAME.tmpdir.XXXXXXXXXX"` || exit 1
JARDIR=`mktemp -d -p $RPM_BUILD_ROOT/tmp "$JARNAME.jardir.XXXXXXXXXX"` || exit 1
@@ -91,6 +93,9 @@
fi
popd > /dev/null

+ chown $JAROWN $j
+ chgrp $JARGRP $j
+
# Cleanup.
rm -rf "$JTMPDIR"
rm -rf "$JARDIR"

35
SOURCES/redhat-rpm-config-9.1.0-rhel7-arch-optflags.patch

@ -0,0 +1,35 @@ @@ -0,0 +1,35 @@
diff -up redhat-rpm-config-9.1.0/rpmrc.arch-optflags redhat-rpm-config-9.1.0/rpmrc
--- redhat-rpm-config-9.1.0/rpmrc.arch-optflags 2013-09-13 08:48:58.573383192 +0300
+++ redhat-rpm-config-9.1.0/rpmrc 2013-09-13 08:52:22.535847799 +0300
@@ -3,7 +3,7 @@ include: /usr/lib/rpm/rpmrc
optflags: i386 %{__global_cflags} -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables
optflags: i486 %{__global_cflags} -m32 -march=i486 -fasynchronous-unwind-tables
optflags: i586 %{__global_cflags} -m32 -march=i586 -mtune=generic -fasynchronous-unwind-tables
-optflags: i686 %{__global_cflags} -m32 -march=i686 -mtune=atom -fasynchronous-unwind-tables
+optflags: i686 %{__global_cflags} -m32 -march=x86-64 -mtune=generic -mfpmath=sse -fasynchronous-unwind-tables
optflags: athlon %{__global_cflags} -m32 -march=athlon -fasynchronous-unwind-tables
optflags: ia64 %{__global_cflags}
optflags: x86_64 %{__global_cflags} -m64 -mtune=generic
@@ -24,10 +24,10 @@ optflags: sparc64v %{__global_cflags} -m

optflags: m68k %{__global_cflags}

-optflags: ppc %{__global_cflags} -m32
+optflags: ppc %{__global_cflags} -m32 -mcpu=power7 -mtune=power7
optflags: ppciseries %{__global_cflags} -m32
optflags: ppcpseries %{__global_cflags} -m32
-optflags: ppc64 %{__global_cflags} -m64
+optflags: ppc64 %{__global_cflags} -m64 -mcpu=power7 -mtune=power7
optflags: ppc64iseries %{__global_cflags} -m64
optflags: ppc64pseries %{__global_cflags} -m64
optflags: ppc8260 %{__global_cflags} -m32
@@ -61,8 +61,8 @@ optflags: atariclone %{__global_cflags}
optflags: milan %{__global_cflags}
optflags: hades %{__global_cflags}

-optflags: s390 %{__global_cflags} -m31 -march=z9-109 -mtune=z10
-optflags: s390x %{__global_cflags} -m64 -march=z9-109 -mtune=z10
+optflags: s390 %{__global_cflags} -m31 -march=z196 -mtune=zEC12
+optflags: s390x %{__global_cflags} -m64 -march=z196 -mtune=zEC12

optflags: aarch64 %{__global_cflags}

12
SOURCES/redhat-rpm-config-9.1.0-stackprotector-strong.patch

@ -0,0 +1,12 @@ @@ -0,0 +1,12 @@
diff -up redhat-rpm-config-9.1.0/macros.stackprotector-strong redhat-rpm-config-9.1.0/macros
--- redhat-rpm-config-9.1.0/macros.stackprotector-strong 2013-07-04 10:21:30.078245504 +0300
+++ redhat-rpm-config-9.1.0/macros 2013-07-04 10:21:44.509357128 +0300
@@ -178,7 +178,7 @@ package or when debugging this package.\
%_hardened_cflags %{?_hardened_build:%{_hardening_cflags}}
%_hardened_ldflags %{?_hardened_build:%{_hardening_ldflags}}

-%__global_cflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -grecord-gcc-switches %{_hardened_cflags}
+%__global_cflags -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches %{_hardened_cflags}
%__global_ldflags -Wl,-z,relro %{_hardened_ldflags}

# Use these macros to differentiate between RH and other KMP implementation(s).

36
SOURCES/redhat-rpm-config-9.1.0-strict-python-bytecompile.patch

@ -0,0 +1,36 @@ @@ -0,0 +1,36 @@
commit 7cf1ad2dbb5af9b9012ba67b9687ad28c02578d6
Author: Panu Matilainen <pmatilai@redhat.com>
Date: Wed Feb 3 12:52:30 2010 +0200

Enable strict python bytecompile mode (if rpm supports it)
- with %_python_bytecompile_errors_terminate_build set to non-zero,
byte-compilation errors will abort the build, this helps catch out
silly "improt foo" syntax errors early on
- not all .py files are valid python (they can be templates, inteded for
jython consumption etc), and what's valid can depend on the python
version (notably 2.x vs 3.x) so allow overriding from spec

diff --git a/macros b/macros
index 77844f0..7721fe0 100644
--- a/macros
+++ b/macros
@@ -95,7 +95,7 @@
%{!?__debug_package:/usr/lib/rpm/redhat/brp-strip %{__strip}} \
/usr/lib/rpm/redhat/brp-strip-static-archive %{__strip} \
/usr/lib/rpm/redhat/brp-strip-comment-note %{__strip} %{__objdump} \
- /usr/lib/rpm/brp-python-bytecompile %{__python} \
+ /usr/lib/rpm/brp-python-bytecompile %{__python} %{?_python_bytecompile_errors_terminate_build} \
/usr/lib/rpm/redhat/brp-python-hardlink \
%{!?__jar_repack:/usr/lib/rpm/redhat/brp-java-repack-jars} \
%{nil}
@@ -167,6 +167,10 @@ unset DISPLAY\
# Should unpackaged files in a build root terminate a build?
%_unpackaged_files_terminate_build 1

+#
+## Should python bytecompilation errors terminate a build?
+%_python_bytecompile_errors_terminate_build 1
+
# Use SHA-256 for FILEDIGESTS instead of default MD5
%_source_filedigest_algorithm 8
%_binary_filedigest_algorithm 8

12
SOURCES/redhat-rpm-config-9.1.0-use-kverrel-for-kmodtool.patch

@ -0,0 +1,12 @@ @@ -0,0 +1,12 @@
diff -Nuar redhat-rpm-config-9.1.0_old/macros redhat-rpm-config-9.1.0/macros
--- redhat-rpm-config-9.1.0_old/macros 2014-01-15 15:29:28.259001613 +0800
+++ redhat-rpm-config-9.1.0/macros 2014-01-15 15:30:16.044001574 +0800
@@ -232,7 +232,7 @@
then \
nobuildreqs="yes" \
fi \
- override_filelist="$filelist" override_preamble="$preamble" nobuildreqs="$nobuildreqs" kmod_version=%kmod_version kmod_release=%kmod_release %{kmodtool} rpmtemplate %{-n*}%{!-n:%name} %{kernel_version} $flavors_to_build 2>/dev/null \
+ override_filelist="$filelist" override_preamble="$preamble" nobuildreqs="$nobuildreqs" kmod_version=%kmod_version kmod_release=%kmod_release %{kmodtool} rpmtemplate %{-n*}%{!-n:%name} %{kverrel} $flavors_to_build 2>/dev/null \
)}

#==============================================================================

17
SOURCES/redhat-rpm-config-9.1.0-use-prefix-macro.patch

@ -0,0 +1,17 @@ @@ -0,0 +1,17 @@
Index: redhat-rpm-config-9.1.0/macros
===================================================================
--- redhat-rpm-config-9.1.0.orig/macros
+++ redhat-rpm-config-9.1.0/macros
@@ -14,10 +14,10 @@
%_prefix /usr
%_sysconfdir /etc
%_localstatedir /var
-%_infodir /usr/share/info
-%_mandir /usr/share/man
+%_infodir %{_prefix}/share/info
+%_mandir %{_prefix}/share/man

-%_defaultdocdir %{_usr}/share/doc
+%_defaultdocdir %{_prefix}/share/doc

%_fmoddir %{_libdir}/gfortran/modules

16
SOURCES/redhat-rpm-config-9.1.0.Remove-hardcoded-limit-of-16-CPUs.patch

@ -0,0 +1,16 @@ @@ -0,0 +1,16 @@
--- current/macros.orig 2017-10-11 13:34:32.288393926 +0200
+++ current/macros 2017-10-11 13:34:44.519416133 +0200
@@ -74,7 +74,12 @@
install

# Maximum number of CPU's to use when building, 0 for unlimited.
-%_smp_ncpus_max 16
+#
+# This was for some time capped at 16. Please see
+# https://bugzilla.redhat.com/show_bug.cgi?id=669638 and
+# https://bugzilla.redhat.com/show_bug.cgi?id=1384938 for the situation
+# surrounding this.
+#%_smp_ncpus_max 0
%_smp_mflags %([ -z "$RPM_BUILD_NCPUS" ] \\\
&& RPM_BUILD_NCPUS="`/usr/bin/getconf _NPROCESSORS_ONLN`"; \\\
ncpus_max=%{?_smp_ncpus_max}; \\\

827
SPECS/redhat-rpm-config.spec

@ -0,0 +1,827 @@ @@ -0,0 +1,827 @@
Summary: Red Hat specific rpm configuration files
Name: redhat-rpm-config
Version: 9.1.0
Release: 87%{?dist}
# No version specified.
License: GPL+
Group: Development/System
URL: https://src.fedoraproject.org/rpms/redhat-rpm-config
Source: redhat-rpm-config-%{version}.tar.bz2

# gcc specs files for hardened builds
Source1: redhat-hardened-cc1
Source2: redhat-hardened-ld

# up-to-date copies of config.guess and config.sub (from automake 1.13.1)
Source10: config.guess
Source11: config.sub

# kabi provides generator
Source20: kabi.attr
Source21: kabi.sh

# Script to handle ppc64le in libtool and associated configure files.
Source30: libtool-handle-ppc64le.sh

Patch0: redhat-rpm-config-9.1.0-strict-python-bytecompile.patch
Patch1: redhat-rpm-config-9.1.0-fix-requires.patch
Patch2: redhat-rpm-config-9.1.0-no-strip-note.patch
Patch3: redhat-rpm-config-9.1.0-pkgconfig-private.patch
# the macros defined by this patch are for things that need to be defined
# at srpm creation time when it is not feasable to require the base packages
# that would otherwise be providing the macros. other language/arch specific
# macros should not be defined here but instead in the base packages that can
# be pulled in at rpm build time, this is specific for srpm creation.
Patch4: redhat-rpm-config-9.1.0-arches-macros.patch
Patch5: redhat-rpm-config-9.1.0-arm.patch
Patch6: redhat-rpm-config-9.1.0-relro.patch
Patch7: redhat-rpm-config-9.1.0-hardened.patch
Patch8: redhat-rpm-config-9.1.0-ppc-no-minimal-toc.patch
Patch9: redhat-rpm-config-9.1.0-dwz.patch
Patch10: redhat-rpm-config-9.1.0-minidebuginfo.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=783433
Patch11: redhat-rpm-config-9.1.0-python-hardlink-spaces-in-filenames.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=853216
Patch12:redhat-rpm-config-9.1.0-use-prefix-macro.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=648996
Patch13: redhat-rpm-config-9.1.0-kernel-source.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=465664
Patch14: redhat-rpm-config-9.1.0-java-repack-order.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=741089
Patch15: 0001-Drop-un-setting-LANG-and-DISPLAY-in-various-build-st.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=783932
Patch16: redhat-rpm-config-9.1.0-filtering-spaces-in-filename.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=872737
Patch17: redhat-rpm-config-9.1.0-java-repack-spaces-in-filenames.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=951669
Patch18: redhat-rpm-config-9.1.0-record-switches.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=951442
Patch19: redhat-rpm-config-9.1.0-configfoo.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=909788
Patch20: redhat-rpm-config-9.1.0-aarch64.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=914831
Patch21: redhat-rpm-config-9.1.0-fcflags.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=669638
Patch22: redhat-rpm-config-9.1.0-ncpus-max.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=905573
Patch23: redhat-rpm-config-9.1.0-jar-repack-perms.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=805266
Patch24: redhat-rpm-config-9.1.0-rhel7-arch-optflags.patch
# forward-port of various kABI-fixes from rhel-6
Patch25: redhat-rpm-config-9.1.0-kmod-kabi.patch
# allow kmod building against z-stream kernels
Patch26: redhat-rpm-config-9.1.0-kmod-brew-build.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=833747
Patch27: redhat-rpm-config-9.1.0-fix-find-provides-modalias-permissions.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1002618
Patch28: redhat-rpm-config-9.1.0-fix-depmod-path.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1040025
Patch29: redhat-rpm-config-9.1.0-stackprotector-strong.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1051558
Patch30: redhat-rpm-config-9.1.0-perfbuild.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1049175
Patch31: redhat-rpm-config-9.1.0-use-kverrel-for-kmodtool.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1126086
Patch32: redhat-rpm-config-9.1.0-fix-kabi-path.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1179523
Patch33: redhat-rpm-config-9.0.3-shebang.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1250015
Patch34: redhat-rpm-config-9.1.0-Fix-stripping-of-binaries.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1061619
Patch35: redhat-rpm-config-9.1.0-find-provides.libtool.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1270053
Patch36: redhat-rpm-config-9.1.0-repack-jars.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1323087
Patch37: redhat-rpm-config-9.0.3-latest-kernel.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1057327
Patch38: redhat-rpm-config-9.1.0-Add-_pkgdocdir.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1324003
Patch39: redhat-rpm-config-9.1.0-find-requires-fix-detection.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1494262
Patch40: redhat-rpm-config-9.1.0-ksyms.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1386840
Patch41: redhat-rpm-config-9.1.0.Remove-hardcoded-limit-of-16-CPUs.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1494262
Patch42: redhat-rpm-config-9.1.0-ksyms-2.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1467319
Patch43: redhat-rpm-config-9.1.0-ksym-requires-multifile.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1445632
Patch44: redhat-rpm-config-9.1.0-mono-ppc64le-aarch64-support.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1460628
Patch45: redhat-rpm-config-9.1.0-fix-group-owners-in-jars.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1619235
Patch46: redhat-rpm-config-9.1.0-fix-ksym-requires-generation.patch
# https://bugzilla.redhat.com/show_bug.cgi?id=1619891
Patch47: redhat-rpm-config-9.1.0-compressed-kmods-support.patch

# ppc64 little endian support
Patch99: redhat-rpm-config-9.1.0-ppc64le.patch


BuildArch: noarch
Requires: coreutils
Requires: perl-srpm-macros
Requires: rpm >= 4.9.0
Requires: dwz >= 0.4
Requires: zip
Provides: system-rpm-config = %{version}-%{release}

%description
Red Hat specific rpm configuration files.

%prep
%setup -q
%patch0 -p1
%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1
%patch5 -p1
%patch6 -p1
%patch7 -p1
%patch8 -p1
%patch9 -p1
%patch10 -p1
%patch11 -p1
%patch12 -p1
%patch13 -p1
%patch14 -p1
%patch15 -p1
%patch16 -p1
%patch17 -p1
%patch18 -p1
%patch19 -p1
%patch20 -p1
%patch21 -p1
%patch22 -p1
%patch23 -p1
%patch24 -p1
%patch25 -p1
%patch26 -p1
%patch27 -p1
%patch28 -p1
%patch29 -p1
%patch30 -p1
%patch31 -p1
%patch32 -p1
%patch33 -p1
%patch34 -p1
%patch35 -p1
%patch36 -p1
%patch37 -p1
%patch38 -p1
%patch39 -p1
%patch40 -p1
%patch41 -p1
%patch42 -p1
%patch43 -p1
%patch44 -p1
%patch45 -p1
%patch46 -p1
%patch47 -p1

%patch99 -p2

%build

%install
make DESTDIR=${RPM_BUILD_ROOT} install
install -m 0444 %{SOURCE1} %{SOURCE2} ${RPM_BUILD_ROOT}/usr/lib/rpm/redhat
install -m 0755 %{SOURCE10} %{SOURCE11} ${RPM_BUILD_ROOT}/usr/lib/rpm/redhat
install -m 0755 %{SOURCE30} ${RPM_BUILD_ROOT}/usr/lib/rpm/redhat

install -D -m 0644 %{SOURCE20} ${RPM_BUILD_ROOT}/usr/lib/rpm/fileattrs/kabi.attr
install -m 0755 %{SOURCE21} ${RPM_BUILD_ROOT}/usr/lib/rpm/kabi.sh

find ${RPM_BUILD_ROOT} -name \*.orig -delete
# buggy makefile in 9.1.0 leaves changelog in wrong place
find ${RPM_BUILD_ROOT} -name ChangeLog -delete

%clean
rm -rf ${RPM_BUILD_ROOT}

%files
%defattr(-,root,root)
%doc ChangeLog
%{_prefix}/lib/rpm/redhat
%{_prefix}/lib/rpm/fileattrs/kabi.attr
%{_prefix}/lib/rpm//kabi.sh
%{_sysconfdir}/rpm/*

%changelog
* Fri Sep 14 2018 Eugene Syromiatnikov <esyr@redhat.com> - 9.1.0-87
- Revert to usage of join instead of comm in find-requires.ksym:mod_requires()
as generated "Requires:" and "Provides:" lists have different format
and unsuitable for processing with comm (#1619235)

* Fri Aug 24 2018 Eugene Syromiatnikov <esyr@redhat.com> - 9.1.0-86
- Add support for compressed kernel modules to find-provides,
find-provides.ksyms, find-requires, find-requires.ksyms (#1619891)

* Fri Aug 24 2018 Eugene Syromiatnikov <esyr@redhat.com> - 9.1.0-85
- Fix generation of kernel module versioned symbol dependencies for the case
when module depends on a symbol with the same name as the one present
in kernel but with a different version (#1619235)

* Wed May 9 2018 Pavlina Moravcova Varekova <pmoravco@redhat.com> - 9.1.0-84
- Revert dropping brp-java-repack-jars
- fix generating group owner name when processing a jar file (#1460628)

* Fri May 4 2018 Pavlina Moravcova Varekova <pmoravco@redhat.com> - 9.1.0-83
- Drop brp-java-repack-jars (#1460628)

* Mon Apr 30 2018 Pavlina Moravcova Varekova <pmoravco@redhat.com> - 9.1.0-82
- Add mono support for ppc64le and aarch64 (#1445632)

* Mon Apr 23 2018 Pavlina Moravcova Varekova <pmoravco@redhat.com> - 9.1.0-81
- Upgrade URL tag (#1502411)

* Thu Nov 30 2017 Florian Festi <ffesti@redhat.com> - 9.1.0-80
- More support for CONFIG_MODULE_REL_CRCS style kernel symbols (#1494262)

* Mon Oct 30 2017 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-79
- Fix ksym dependency generator for more than one .ko per package (#1467319)

* Wed Oct 11 2017 Florian Festi <ffesti@redhat.com> - 9.1.0-78
- Remove hardcoded limit of 16 CPUs for makefile parallelism (#1386840)

* Wed Oct 04 2017 Florian Festi <ffesti@redhat.com> - 9.1.0-77
- Add support for CONFIG_MODULE_REL_CRCS style kernel symbols (#1494262)

* Tue Feb 14 2017 Yaakov Selkowitz <yselkowi@redhat.com> - 9.1.0-76
- Add aarch64/ppc64le/s390x to nodejs_arches (#1417800)

* Thu Jan 12 2017 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-75
- _pkgdocdir macro is supposed to be versioned on RHEL-7 (#1392354)

* Fri Dec 16 2016 Florian Festi <ffesti@redhat.com> - 9.1.0-74
- Temporarily disable hardening again (#1387475)

* Wed Nov 30 2016 Florian Festi <ffesti@redhat.com> - 9.1.0-73
- Enable hardening (#1387475)

* Mon Aug 29 2016 Florian Festi <ffesti@redhat.com> - 9.1.0-72
- Rebuild for fixed _docdir_fmt

* Thu Jul 28 2016 Florian Festi <ffesti@redhat.com> - 9.1.0-71
- Set _docdir_fmt macro to old default (#1057327)

* Tue Jul 26 2016 Florian Festi <ffesti@redhat.com> - 9.1.0-70
- Be stricter with she bang lines in find-requires (#1179523)
- Use --with-cpu=power8 for ppc64le (#1213268)
- Fix stripping of binaries for changed file output (#1250015)
- Fix find-provides.libtool for new libtool style (#1061619)
- Restore UID/ GID on jar files (#1270053)
- Fix latest_kernel macro (#1323087)
- Add _pkgdocdir and _docdir_fmt macro (#1057327)
- Fix detection for perl files in old depencency generator (#1324003)

* Tue Dec 08 2015 Yaakov Selkowitz <yselkowi@redhat.com> - 9.1.0-69
- Add aarch64 and ppc64le to ghc, ocaml, and GNAT arches (#1193178)

* Wed Nov 12 2014 Weiping Pan <wpan@redhat.com> - 9.1.0-68
- fix kabi path (#1126086)

* Tue Aug 12 2014 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-67
- Enable stack protector on aarch64 (#1073677)

* Fri Aug 01 2014 Florian Festi <ffesti@redhat.com> - 9.1.0-66
- use -mtune=power8 for ppc64le (#1123485)

* Fri Jul 25 2014 Florian Festi <ffesti@redhat.com> - 9.1.0-65
- Fix fix for ppc64le libtool issues (#1113618)
- As this package is noarch we need to have a runtime solution

* Thu Jul 24 2014 Florian Festi <ffesti@redhat.com> - 9.1.0-64
- Fix ppc64le libtool issues (#1113618)

* Tue Feb 18 2014 Weiping Pan <wpan@redhat.com> - 9.1.0-61
- use kverrel as the parameter for kmodtool (#1049175)

* Fri Feb 07 2014 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-62
- config.guess/sub don't need to be group-writable (#1061762)

* Tue Jan 21 2014 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-61
- Bump s390(x) up to -march=z196 (#805266)

* Fri Jan 10 2014 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-60
- Add %%_performance_build macro for enabling extra optimizations (#1051558)

* Tue Jan 07 2014 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-59
- Update config.{sub,guess} for ppc64p7 support (#1048751)

* Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 9.1.0-58
- Mass rebuild 2013-12-27

* Thu Dec 19 2013 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-57
- Switch from -fstack-protector to -fstack-protector-strong (#1040025)

* Thu Oct 03 2013 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-56
- Drop accidentally added second -m32 switch from i686 build flags
- Use -mcpu=power7 for ppc and ppc64 builds (#789116)

* Thu Oct 03 2013 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-55
- Add dependency generator for kABI provides (#1004930)
- Explicitly require rpm >= 4.9.0 for the above

* Sun Sep 22 2013 Weiping Pan <wpan@redhat.com> - 9.1.0-54
- Fix depmod path

* Fri Sep 13 2013 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-53
- adjust ppc(64), s390(x) and i686 arch optflags as per #805266 and #789116

* Tue Aug 06 2013 Weiping Pan <wpan@redhat.com> - 9.1.0-52
- Fix permissions on /usr/lib/rpm/redhat/find-provides.d/modalias.prov

* Tue Jul 09 2013 Dan Horák <dhorak@redhat.com> - 9.1.0-51
- disable the s390 architecture build options (patch24) until new hardware is installed

* Tue Jul 09 2013 Dan Horák <dhorak@redhat.com> - 9.1.0-50
- fix s390 architecture build options as per #805266

* Tue Jul 09 2013 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-49
- Re-add various kABI-related bits (Jon Masters)
- Allow kmod building against z-stream kernels (Jiri Benc)

* Mon Jul 08 2013 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-48
- update s390 architecture build options as per #805266

* Fri Jul 05 2013 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-47
- fix brp-java-repack-jars failing on strange permissions (#905573)

* Thu Jun 27 2013 Panu Matilainen <pmatilai@redhat.com> - - 9.1.0-46
- make cpu limit for building configurable through _smp_ncpus_max macro

* Tue May 21 2013 T.C. Hollingsworth <tchollingsworth@gmail.com> - 9.1.0-45
- add nodejs_arches macro for ExclusiveArch for Node.js packages

* Mon May 13 2013 Adam Jackson <ajax@redhat.com> 9.1.0-44
- redhat-config-*: Use + to append rather than %%rename, to protect against
multiple -specs= ending up in the command line. (#892837)

* Tue Apr 23 2013 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-43
- Add optflags stack protector override for AArch64 (#909788)
- Also set FCFLAGS from %%configure (#914831)

* Mon Apr 22 2013 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-42
- Switch back to manual config.guess/sub copies for reproducability
- Replace config.guess/sub from %%configure again (#951442)

* Mon Apr 22 2013 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-41
- Add -grecord-gcc-switches to global CFLAGS (#951669)

* Mon Mar 25 2013 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-40
- Add virtual system-rpm-config provide

* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 9.1.0-39
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild

* Sat Nov 17 2012 Jens Petersen <petersen@redhat.com> - 9.1.0-38
- add ARM to ghc_arches_with_ghci for ghc-7.4.2 ghci support
(NB this change should not be backported before ghc-7.4.2)

* Fri Nov 9 2012 Toshio Kuratomi <toshio@fedoraproject.org> - 9.1.0-37
- Patch to fix spaces in java jar files
https://bugzilla.redhat.com/show_bug.cgi?id=872737

* Fri Nov 9 2012 Toshio Kuratomi <toshio@fedoraproject.org> - 9.1.0-36
- Patch to fix spaces in files used in filtering macros
https://bugzilla.redhat.com/show_bug.cgi?id=783932

* Wed Oct 3 2012 Ville Skyttä <ville.skytta@iki.fi> - 9.1.0-35
- Drop (un)setting LANG and DISPLAY in build stages, require rpm >= 4.8.0.

* Wed Oct 3 2012 Toshio Kuratomi <toshio@fedoraproject.org> - 9.1.0-34
- Add patch from https://bugzilla.redhat.com/show_bug.cgi?id=783433
to fix spaces in files and directories that are fed to the
brp-python-hardlink script
- Require zip since java repack jars requires it
https://bugzilla.redhat.com/show_bug.cgi?id=857479
- Java jars need the MANIFEST.MF file to be first in the archive
https://bugzilla.redhat.com/show_bug.cgi?id=465664
- Fix kernel_source macro to match the directory that kernel sources are installed in
https://bugzilla.redhat.com/show_bug.cgi?id=648996
- Patch _mandir, _infodir, and _defaultocdir to use _prefix
https://bugzilla.redhat.com/show_bug.cgi?id=853216

* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 9.1.0-33
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild

* Wed Jun 27 2012 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-32
- enable minidebuginfo generation (#834073)

* Mon Jun 25 2012 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-31
- revert back to plain -g, -g3 seems to cancel dwz size improvements

* Mon Jun 25 2012 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-30
- require dwz, enable dwarf compression for debuginfo packages (#833311)

* Wed Jun 06 2012 Petr Pisar <ppisar@redhat.com> - 9.1.0-29
- Pull in dependency with macros specific for building Perl source packages

* Sat Mar 3 2012 Jens Petersen <petersen@redhat.com> - 9.1.0-28
- add s390 and s390x to ghc_arches

* Wed Feb 22 2012 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-27
- add GNAT arch definitions

* Sun Jan 15 2012 Dennis Gilmore <dennis@ausil.us> - 9.1.0-26
- per ppc team request drop -mminimal-toc on ppc64

* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 9.1.0-25
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild

* Tue Dec 27 2011 Jens Petersen <petersen@redhat.com> - 9.1.0-24
- add ghc_arches_with_ghci

* Wed Nov 09 2011 Dennis Gilmore <dennis@ausil.us> - 9.1.0-23
- remove patch that forces --disable-silent-rules to configure
- it breaks anything set to not ignore unknown configure options

* Tue Oct 18 2011 Jens Petersen <petersen@redhat.com> - 9.1.0-22
- add armv5tel to ghc_arches

* Wed Sep 28 2011 Dennis Gilmore <dennis@ausil.us> - 9.1.0-21
- build armv5tel on armv7l since they are the same abi armv7hl is
- a incompatable ABI

* Wed Sep 28 2011 Jens Petersen <petersen@redhat.com> - 9.1.0-20
- add armv7hl to ghc_arches

* Sun Sep 25 2011 Ville Skyttä <ville.skytta@iki.fi> - 9.1.0-19
- Fix URL.

* Thu Sep 22 2011 Adam Jackson <ajax@redhat.com> 9.1.0-18
- redhat-hardened-cc1: Inject -fPIE, not -fPIC.
cf. http://lists.fedoraproject.org/pipermail/devel/2011-September/157365.html

* Fri Sep 16 2011 Adam Jackson <ajax@redhat.com> 9.1.0-17
- Expose %%_hardening_{c,ld}flags independently to make it easier for
packages to apply them to selected components

* Wed Aug 10 2011 Colin Walters <walters@verbum.org> - 9.1.0-16
- Globally disable silent rules

* Wed Aug 03 2011 Adam Jackson <ajax@redhat.com> 9.1.0-15
- redhat-hardened-{cc1,ld}: Move some of the rewrite magic to gcc specs so
we don't end up with both -fPIC and -fPIE on the command line

* Mon Aug 01 2011 Adam Jackson <ajax@redhat.com> 9.1.0-14
- redhat-rpm-config-9.1.0-hardened.patch: Add macro magic for %%_hardened_build

* Thu Jul 07 2011 Adam Jackson <ajax@redhat.com> 9.1.0-13
- redhat-rpm-config-9.1.0-relro.patch: LDFLAGS, not CFLAGS.

* Sat Jul 02 2011 Jon Masters <jcm@jonmasters.org> - 9.1.0-12
- redhat-rpm-config-9.1.0-arm.patch: Make armv7hl default on all v7 ARM

* Mon Jun 27 2011 Adam Jackson <ajax@redhat.com> - 9.1.0-11
- redhat-rpm-config-9.1.0-relro.patch: Add -Wl,-z,relro to __global_cflags

* Tue Jun 21 2011 Jens Petersen <petersen@redhat.com> - 9.1.0-10
- revert last build since releng prefers exclusivearch here

* Sat Jun 18 2011 Jens Petersen <petersen@redhat.com> - 9.1.0-9
- replace ghc_archs with ghc_excluded_archs

* Mon Jun 13 2011 Dennis Gilmore <dennis@ausil.us> - 9.1.0-8
- add arm hardware float macros, fix up armv7l

* Mon May 30 2011 Dennis Gilmore <dennis@ausil.us> - 9.1.0-7
- add -srpm to the arches files so that the base language macros can
be parallel installable with these

* Fri May 27 2011 Dennis Gilmore <dennis@ausil.us> - 9.1.0-6
- add some specific macros needed at srpm creation time

* Thu May 27 2010 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-5
- adjust to new pkg-config behavior wrt private dependencies (#596433)

* Mon Mar 01 2010 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-4
- avoid unnecessarily running brp-strip-comment-note (#568924)

* Mon Feb 15 2010 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-3
- unbreak find-requires again, doh (#564527)

* Wed Feb 3 2010 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-2
- python byte-compilation errors abort the build by default

* Tue Feb 2 2010 Panu Matilainen <pmatilai@redhat.com> - 9.1.0-1
- new version, lose merged patches (fixes #521141, #455279, #496522, #458648)
- require rpm for parent dir, version >= 4.6.0 for sane keyserver behavior
- buildrequire libtool to grab copies of config.guess and config.sub
- add URL to the git repo and upstream changelog as documentation

* Mon Nov 23 2009 Orion Poplawski <orion@cora.nwra.com> - 9.0.3-19
- Change configure macro to use _configure to allow override (bug #489942)

* Mon Sep 28 2009 Bill Nottingham <notting@redhat.com>
- Drop xz compression level to 2

* Thu Sep 03 2009 Adam Jackson <ajax@redhat.com>
- Delete *.orig in %%install

* Thu Sep 03 2009 Paul Howarth <paul@city-fan.org> 9.0.3-17
- redhat-rpm-config-9.0.3-filtering-macros.patch: Rediff so we don't ship a .orig file
- add (empty) %%build section
- fix unescaped macros in changelog

* Tue Aug 18 2009 Chris Weyl <cweyl@alumni.drew.edu> 9.0.3-16
- add the filtering framework approved by the FPC/FESCo. (#516240)

* Thu Aug 13 2009 Adam Jackson <ajax@redhat.com> 9.0.3-15
- redhat-rpm-config-9.0.4-brpssa-speedup.patch: When looking for static
archives, only run file(1) on files named *.a. (#517101)

* Wed Aug 12 2009 Adam Jackson <ajax@redhat.com> 9.0.3-14
- redhat-rpm-config-9.0.3-jars-with-spaces.patch: Handle repacking jars
whose filenames contain spaces. (#461854)

* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 9.0.3-13
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild

* Wed Jul 22 2009 Bill Nottingham <notting@redhat.com> 9.0.3-12
- use XZ payload compression for binary packages

* Tue Jul 21 2009 Tom "spot" Callaway <tcallawa@redhat.com> - 9.0.3-10
- always delete %%buildroot as first step of %%install (as long as %%buildroot is not /)

* Fri Jul 17 2009 Bill Nottingham <notting@redhat.com> 9.0.3-10
- apply fedora 12 default buildflags

* Wed Jun 03 2009 Adam Jackson <ajax@redhat.com> 9.0.3-9
- limit-smp-16-threads.patch: Rediff so we don't ship a .orig file (#500316)

* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 9.0.3-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild

* Mon Feb 23 2009 Jon Masters <jcm@redhat.com> - 9.0.3-7
- Change default hashing algorithm in file digests to SHA-256
- Resolves: #485826.

* Tue Feb 17 2009 Dennis Gilmore <dennis@ausil.us> - 9.0.3-6
- add missing armv7l arch
- set the default build arch to match fedora arm build target

* Mon Feb 16 2009 Dennis Gilmore <dennis@ausil.us> - 9.0.3-5
- apply fedora 11 default buildflags
- set 32 bit intel build arch to i586 on compatiable hardware
- set 32 bit sparc build arch to sparcv9 on compatiable hardware

* Mon Feb 16 2009 Dennis Gilmore <dennis@ausil.us> - 9.0.3-4
- limit _smp_flags to -j16

* Wed Sep 3 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 9.0.3-3
- fix license tag
- nuke ancient conflicts

* Mon Aug 11 2008 Panu Matilainen <pmatilai@redhat.com> - 9.0.3-2
- Unbreak find-requires (#443015)

* Tue May 06 2008 Jon Masters <jcm@redhat.com> - 9.0.3-1
- Ensure Java Jar files have readable files within.
- Remove overwritten config.guess|sub files (testing).
- Fix Fortran flags for building using _fmoddir.
- Pull in objdump fix to upstream find-requires.

* Thu Apr 03 2008 Jon Masters <jcm@redhat.com> - 9.0.2-1
- Remove smp dependencies
- Update config.guess|sub files
- Don't call find-requires.ksyms for kmod packages (kernel kABI scripts).

* Thu Jul 05 2007 Jesse Keating <jkeating@redhat.com> - 9.0.1-1
- Remove dist defines, fedora-release does that now
- Enable post-build buildroot checking by default

* Tue Jun 19 2007 Jeremy Katz <katzj@redhat.com> - 9.0.0-1
- use stock find-lang.sh (#213041)
- arm fixes (Lennert Buytenhek, #243523)
- allow jar repacking to be disabled (#219731)
- fix running dist.sh --fc (#223651)
- hardlink identical .pyc and .pyo files to save space (Ville Skyttä)
- fix TMPDIR usage (Matthew Miller, #235614)

* Tue Jun 19 2007 Jeremy Katz <katzj@redhat.com> - 8.1.0-1
- add modalias tags to kmod packages and other kmod changes (jcm)
- recompress jars to avoid multilib conflicts (bkonrath)

* Fri May 18 2007 Jesse Keating <jkeating@redhat.com> 8.0.45-16
- Update macros for F8
- hardcode dist in release string, as we provide it. chicken/egg.

* Wed Apr 11 2007 Jon Masters <jcm@redhat.com> 8.0.45-15
- Add modalias tags to kernel module packages (kmods) for tracking.
- Further information is available at http://www.kerneldrivers.org/.

* Tue Apr 03 2007 Jon Masters <jcm@redhat.com> 8.0.45-14
- Rebased all previous patches (since java fix introduced offset).
- Added Fedora per-release macros to platforms section of macros.
Further debate may see these move elsewhere in the ordering.

* Tue Mar 13 2007 Ben Konrath <bkonrath@redhat.com> 8.0.45-13
- Update brp-java-repack-jars to fix issue with tomcat.

* Wed Oct 18 2006 Jon Masters <jcm@redhat.com> 8.0.45-12
- Synced kernel_module_package semantics with SuSE.
- Updated kmodtool.

* Tue Oct 17 2006 Jon Masters <jcm@redhat.com> 8.0.45-10
- Updated kernel_module_package.

* Mon Oct 16 2006 Jon Masters <jcm@redhat.com> 8.0.45-9
- Added kernel_module_package macro. Working on unified packaging.

* Thu Oct 12 2006 Jon Masters <jcm@redhat.com> 8.0.45-8
- Added patch for find-requires. Waiting on write access to public CVS.

* Tue Sep 12 2006 Deepak Bhole <dbhole@redhat.com> 8.0.45-6
- Fix brp-java-repack-jars to work with builddirs that aren't %%name-%%version

* Mon Sep 11 2006 Fernando Nasser <fnasser@redhat.com> - 8.0.45-5
- Fix order of tokens in find command (thanks mikeb@redhat.com)

* Thu Sep 7 2006 Ben Konrath <bkonrath@redhat.com> - 8.0.45-4
- Fix bug in repack jars script.

* Wed Sep 6 2006 Jeremy Katz <katzj@redhat.com> - 8.0.45-3
- path fix

* Tue Sep 5 2006 Jeremy Katz <katzj@redhat.com> - 8.0.45-2
- Add script from Ben Konrath <bkonrath@redhat.com> to repack jars to
avoid multilib conflicts

* Sun Jul 30 2006 Jon Masters <jcm@redhat.com> - 8.0.45-1
- Fix inverted kernel test.

* Sun Jul 30 2006 Jon Masters <jcm@redhat.com> - 8.0.44-1
- Add a better check for a kernel vs. kmod.

* Thu Jun 15 2006 Jon Masters <jcm@redhat.com> - 8.0.43-1
- Workaround bug in find-requires/find-provides for kmods.

* Thu Jun 15 2006 Jon Masters <jcm@redhat.com> - 8.0.42-1
- Fix a typo in KMP find-requires.

* Tue Jun 13 2006 Jon Masters <jcm@redhat.com> - 8.0.41-1
- Add support for KMP Fedora Extras packaging.

* Fri Feb 3 2006 Jeremy Katz <katzj@redhat.com> - 8.0.40-1
- use -mtune=generic for x86 and x86_64

* Tue Aug 16 2005 Elliot Lee <sopwith@redhat.com> - 8.0.39-1
- Fix #165416

* Mon Aug 01 2005 Elliot Lee <sopwith@redhat.com> - 8.0.38-1
- Add -Wall into cflags

* Mon Aug 01 2005 Elliot Lee <sopwith@redhat.com> - 8.0.37-1
- Patch from Uli: enable stack protector, fix sparc & ppc cflags

* Thu Jun 16 2005 Elliot Lee <sopwith@redhat.com> - 8.0.36-1
- Fix the fix

* Wed Apr 6 2005 Elliot Lee <sopwith@redhat.com> - 8.0.35-1
- Fix #129025 (enable python byte compilation)

* Wed Mar 23 2005 Elliot Lee <sopwith@redhat.com> 8.0.34-1
- Bug fixes
- Cflags change by drepper

* Wed Feb 9 2005 Elliot Lee <sopwith@redhat.com> 8.0.33-1
- Change -D to -Wp,-D to make java happy
- Add -D_FORTIFY_SOURCE=2 to global cflags (as per Jakub & Arjan's request)

* Fri Oct 1 2004 Bill Nottingham <notting@redhat.com> 8.0.32-1
- allow all symbol versioning in find_requires - matches RPM internal
behavior

* Mon Jun 28 2004 Elliot Lee <sopwith@redhat.com> 8.0.31-1
- Add ppc8[25]60 to rpmrc optflags

* Fri Jun 25 2004 Elliot Lee <sopwith@redhat.com> 8.0.29-1
- rpmrc patch from jakub to change optflags.

* Wed Sep 17 2003 Elliot Lee <sopwith@redhat.com> 8.0.28-1
- Change brp-compress to pass -n flag to gzip (per msw's request)

* Tue Jul 15 2003 Elliot Lee <sopwith@redhat.com> 8.0.27-1
- Fix broken configure macro find for config.guess/config.sub
- Put host/target/build back for now

* Mon Jul 7 2003 Jens Petersen <petersen@redhat.com> - 8.0.26-1
- preserve the vendor field when VENDOR not set
- put VENDOR in the final i386-libc line, not the tentative one

* Mon Jul 7 2003 Jens Petersen <petersen@redhat.com> - 8.0.25-1
- update config.{guess,sub} to 2003-06-17
- define VENDOR to be redhat only when /etc/redhat-release present
[suggested by jbj]
- put VENDOR in vendor field in our config.guess file for
ia64, ppc, ppc64, s390, s390x, x86_64 and elf32-i386 Linux
- drop the --host, --build, --target and --program-prefix configure options
from %%configure, since this causes far too many problems

* Fri May 2 2003 Jens Petersen <petersen@redhat.com> - 8.0.24-3
- make config.{guess,sub} executable

* Thu May 1 2003 Jens Petersen <petersen@redhat.com> - 8.0.22-2
- add config.guess and config.sub (2003-02-22) with s390 patch on config.sub
- make %%configure use them

* Mon Mar 03 2003 Elliot Lee <sopwith@redhat.com>
- Unset $DISPLAY in macros

* Mon Feb 24 2003 Elliot Lee <sopwith@redhat.com> 8.0.21-1
- Just turn on -g unconditionally for now

* Thu Feb 13 2003 Elliot Lee <sopwith@redhat.com> 8.0.20-1
- Reorganize rpmrc/macros to set cflags in a nicer manner.

* Wed Jan 22 2003 Elliot Lee <sopwith@redhat.com> 8.0.19-1
- Disable brp-implant-ident-static until it works everywhere

* Thu Jan 16 2003 Nalin Dahyabhai <nalin@redhat.com> 8.0.18-1
- add brp-implant-ident-static, which requires mktemp

* Thu Jan 9 2003 Bill Nottingham <notting@redhat.com> 8.0.17-1
- add brp-strip-static-archive from rpm-4.2-0.54

* Tue Dec 17 2002 Bill Nottingham <notting@redhat.com> 8.0.16-1
- make -g in rpmrc conditional on debug_package

* Mon Dec 16 2002 Elliot Lee <sopwith@redhat.com> 8.0.15-1
- Rename -debug subpackages to -debuginfo

* Sat Dec 14 2002 Tim Powers <timp@redhat.com> 8.0.14-1
- tweak debug package stuff so that we are overloading %%install
instead of %%post

* Sat Dec 14 2002 Tim Powers <timp@redhat.com> 8.0.13-1
- turn on internal rpm dep generation by default

* Fri Dec 13 2002 Elliot Lee <sopwith@redhat.com> 8.0.12-1
- New release with debug packages on

* Tue Dec 3 2002 Bill Nottingham <notting@redhat.com> 8.0.8-1
- turn debug packages off
- override optflags with no -g

* Fri Nov 22 2002 Elliot Lee <sopwith@redhat.com> 8.0.7-1
- turn on debug packages

* Thu Nov 21 2002 Elliot Lee <sopwith@redhat.com> 8.0.6-1
- Pass __strip and __objdump macros

* Thu Nov 21 2002 Elliot Lee <sopwith@redhat.com> 8.0.5-1
- Update macros to specify find-provides/find-requires

* Thu Oct 31 2002 Elliot Lee <sopwith@redhat.com> 8.0.4-1
- Remove tracking dependency

* Wed Oct 16 2002 Phil Knirsch <pknirsch@redhat.com> 8.0.3-2
- Added fix for outdated config.[sub|guess] files in %%configure section

* Wed Oct 16 2002 Elliot Lee <sopwith@redhat.com> 8.0.3-1
- New release that blows up on unpackaged files and missing doc files.

* Thu Oct 3 2002 Jeremy Katz <katzj@redhat.com> 8.0.2
- don't redefine everything in macros, just what we need to

* Mon Sep 16 2002 Alexander Larsson <alexl@redhat.com> 8.0.1
- Add debug package support to %%__spec_install_post

* Tue Sep 3 2002 Bill Nottingham <notting@redhat.com> 8.0-1
- bump version

* Wed Aug 28 2002 Elliot Lee <sopwith@redhat.com> 7.3.94-1
- Update macrofiles

* Wed Jul 31 2002 Elliot Lee <sopwith@redhat.com> 7.3.93-1
- Add _unpackaged_files_terminate_build and
_missing_doc_files_terminate_build to macros

* Thu Jul 11 2002 Elliot Lee <sopwith@redhat.com> 7.3.92-6
- find-lang.sh fix from 67368
- find-requires fix from 67325

* Thu Jul 11 2002 Elliot Lee <sopwith@redhat.com> 7.3.92-5
- Add /etc/rpm/macros back to make #67951 go away

* Wed Jun 26 2002 Jens Petersen <petersen@redhat.com> 7.3.92-4
- fix %%configure targeting for autoconf-2.5x (#58468)
- include ~/.rpmmacros in macrofiles file path again

* Fri Jun 21 2002 Tim Powers <timp@redhat.com> 7.3.92-3
- automated rebuild

* Fri Jun 21 2002 Elliot Lee <sopwith@redhat.com> 7.3.92-2
- Don't define _arch

* Thu Jun 20 2002 Elliot Lee <sopwith@redhat.com> 7.3.92-1
- find-lang error detection from Havoc

* Wed Jun 12 2002 Elliot Lee <sopwith@redhat.com> 7.3.91-1
- Update

* Sun Jun 9 2002 Jeff Johnson <jbj@redhat.com>
- create.
Loading…
Cancel
Save