From bad7233d8743ee51f6ef3c37e1d114b38b035862e95a0917c8083c112cc9fef8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Schr=C3=B6der?= Date: Thu, 13 Jun 2019 14:22:48 +0000 Subject: [PATCH 1/4] Accepting request 702804 from home:marxin:branches:Base:System - Add adopt-language-specific-build_fooflags-macros-from-F.patch (9a50846ceeef2add2344dd463c5562bd69496a23) from master. OBS-URL: https://build.opensuse.org/request/show/702804 OBS-URL: https://build.opensuse.org/package/show/Base:System/rpm?expand=0&rev=497 --- ...pecific-build_fooflags-macros-from-F.patch | 63 +++++++++++++++++++ python-rpm.spec | 2 +- rpm.changes | 6 ++ rpm.spec | 4 +- 4 files changed, 73 insertions(+), 2 deletions(-) create mode 100644 adopt-language-specific-build_fooflags-macros-from-F.patch diff --git a/adopt-language-specific-build_fooflags-macros-from-F.patch b/adopt-language-specific-build_fooflags-macros-from-F.patch new file mode 100644 index 0000000..b2733af --- /dev/null +++ b/adopt-language-specific-build_fooflags-macros-from-F.patch @@ -0,0 +1,63 @@ +From 9a50846ceeef2add2344dd463c5562bd69496a23 Mon Sep 17 00:00:00 2001 +From: Panu Matilainen +Date: Mon, 6 May 2019 14:44:30 +0300 +Subject: [PATCH] Adopt language-specific %build_fooflags macros from Fedora + +%{optflags} has been the catchall for all compiler options but this +is quite limiting as there's no way to add for example C++ specific +options distro-wide. This adds separate %build_cflags, %build_cxxflags, +%build_fflags for the gcc-supported languages, and additionally +%build_ldflags for distro-wide LDFLAGS setting. + +Based on Florian Weimer's work in Fedoras redhat-rpm-config macros. +--- + macros.in | 26 +++++++++++++++++++++++--- + 1 file changed, 23 insertions(+), 3 deletions(-) + +diff --git a/macros.in b/macros.in +index 2ab108776..b6cb52951 100644 +--- a/macros.in ++++ b/macros.in +@@ -999,6 +999,24 @@ package or when debugging this package.\ + %_target_vendor %{_host_vendor} + %_target_os %{_host_os} + ++#============================================================================== ++# ---- compiler flags. ++ ++# C compiler flags. This is traditionally called CFLAGS in makefiles. ++# Historically also available as %%{optflags}, and %%build sets the ++# environment variable RPM_OPT_FLAGS to this value. ++%build_cflags %{optflags} ++ ++# C++ compiler flags. This is traditionally called CXXFLAGS in makefiles. ++%build_cxxflags %{optflags} ++ ++# Fortran compiler flags. Makefiles use both FFLAGS and FCFLAGS as ++# the corresponding variable names. ++%build_fflags %{optflags} %{?_fmoddir:-I%{_fmoddir}} ++ ++# Link editor flags. This is usually called LDFLAGS in makefiles. ++#%build_ldflags -Wl,-z,relro %{?_lto_cflags} ++ + #============================================================================== + # ---- specfile macros. + # Macro(s) here can be used reliably for reproducible builds. +@@ -1010,9 +1028,11 @@ package or when debugging this package.\ + # + %_configure ./configure + %configure \ +- CFLAGS="${CFLAGS:-%optflags}" ; export CFLAGS ; \ +- CXXFLAGS="${CXXFLAGS:-%optflags}" ; export CXXFLAGS ; \ +- FFLAGS="${FFLAGS:-%optflags}" ; export FFLAGS ; \ ++ CFLAGS="${CFLAGS:-%{build_cflags}}" ; export CFLAGS ; \ ++ CXXFLAGS="${CXXFLAGS:-%{build_cxxflags}}" ; export CXXFLAGS ; \ ++ FFLAGS="${FFLAGS:-%{build_fflags}}" ; export FFLAGS ; \ ++ FCFLAGS="${FCFLAGS:-%{build_fflags}}" ; export FCFLAGS ; \ ++ LDFLAGS="${LDFLAGS:-%{build_ldflags}}" ; export LDFLAGS ; \ + %{_configure} --host=%{_host} --build=%{_build} \\\ + --program-prefix=%{?_program_prefix} \\\ + --disable-dependency-tracking \\\ +-- +2.21.0 + diff --git a/python-rpm.spec b/python-rpm.spec index 937f429..d628008 100644 --- a/python-rpm.spec +++ b/python-rpm.spec @@ -13,7 +13,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # diff --git a/rpm.changes b/rpm.changes index 3982813..9e0ef9d 100644 --- a/rpm.changes +++ b/rpm.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Tue May 14 10:11:34 UTC 2019 - Martin Liška + +- Add adopt-language-specific-build_fooflags-macros-from-F.patch + (9a50846ceeef2add2344dd463c5562bd69496a23) from master. + ------------------------------------------------------------------- Tue Apr 16 08:40:11 UTC 2019 - Stasiek Michalski diff --git a/rpm.spec b/rpm.spec index 30245e2..42b501d 100644 --- a/rpm.spec +++ b/rpm.spec @@ -12,7 +12,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # @@ -129,6 +129,7 @@ Patch117: findsupplements.diff Patch118: dwz-compression.patch Patch119: getncpus.diff Patch120: rpmfc-push-name-epoch-version-release-macro-before-invoking-depgens.patch +Patch121: adopt-language-specific-build_fooflags-macros-from-F.patch Patch6464: auto-config-update-aarch64-ppc64le.diff Patch6465: auto-config-update-riscv64.diff BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -228,6 +229,7 @@ rm -f rpmdb/db.h %patch -P 100 -P 102 -P 103 -P 108 %patch -P 109 -P 114 -P 117 -P 118 %patch -P 119 -P 120 +%patch121 -p1 %ifarch aarch64 ppc64le riscv64 %patch6464 From 7f9a154e3c687f572ed91d493be59e719e14aa8f402a323e985cc279ab07e828 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Schr=C3=B6der?= Date: Thu, 13 Jun 2019 14:24:14 +0000 Subject: [PATCH 2/4] Tweak patch OBS-URL: https://build.opensuse.org/package/show/Base:System/rpm?expand=0&rev=498 --- ...anguage-specific-build_fooflags-macros-from-F.patch | 10 +++++----- python-rpm.spec | 2 +- rpm.spec | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/adopt-language-specific-build_fooflags-macros-from-F.patch b/adopt-language-specific-build_fooflags-macros-from-F.patch index b2733af..b60d686 100644 --- a/adopt-language-specific-build_fooflags-macros-from-F.patch +++ b/adopt-language-specific-build_fooflags-macros-from-F.patch @@ -50,11 +50,11 @@ index 2ab108776..b6cb52951 100644 - CFLAGS="${CFLAGS:-%optflags}" ; export CFLAGS ; \ - CXXFLAGS="${CXXFLAGS:-%optflags}" ; export CXXFLAGS ; \ - FFLAGS="${FFLAGS:-%optflags}" ; export FFLAGS ; \ -+ CFLAGS="${CFLAGS:-%{build_cflags}}" ; export CFLAGS ; \ -+ CXXFLAGS="${CXXFLAGS:-%{build_cxxflags}}" ; export CXXFLAGS ; \ -+ FFLAGS="${FFLAGS:-%{build_fflags}}" ; export FFLAGS ; \ -+ FCFLAGS="${FCFLAGS:-%{build_fflags}}" ; export FCFLAGS ; \ -+ LDFLAGS="${LDFLAGS:-%{build_ldflags}}" ; export LDFLAGS ; \ ++ CFLAGS="${CFLAGS:-%{?build_cflags}}" ; export CFLAGS ; \ ++ CXXFLAGS="${CXXFLAGS:-%{?build_cxxflags}}" ; export CXXFLAGS ; \ ++ FFLAGS="${FFLAGS:-%{?build_fflags}}" ; export FFLAGS ; \ ++ FCFLAGS="${FCFLAGS:-%{?build_fflags}}" ; export FCFLAGS ; \ ++ LDFLAGS="${LDFLAGS:-%{?build_ldflags}}" ; export LDFLAGS ; \ %{_configure} --host=%{_host} --build=%{_build} \\\ --program-prefix=%{?_program_prefix} \\\ --disable-dependency-tracking \\\ diff --git a/python-rpm.spec b/python-rpm.spec index d628008..937f429 100644 --- a/python-rpm.spec +++ b/python-rpm.spec @@ -13,7 +13,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# Please submit bugfixes or comments via http://bugs.opensuse.org/ # diff --git a/rpm.spec b/rpm.spec index 42b501d..59f6f26 100644 --- a/rpm.spec +++ b/rpm.spec @@ -12,7 +12,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# Please submit bugfixes or comments via http://bugs.opensuse.org/ # From 54dd915b8af1090ef86d375e0c75fc3eec554347a32a6cf2f98183ccbbd3852c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Schr=C3=B6der?= Date: Thu, 13 Jun 2019 14:33:20 +0000 Subject: [PATCH 3/4] Accepting request 708407 from home:jengelh:branches:Base:System - Enable decompression and creation of zstd-based payloads. - Add homepage and repo URL. OBS-URL: https://build.opensuse.org/request/show/708407 OBS-URL: https://build.opensuse.org/package/show/Base:System/rpm?expand=0&rev=499 --- python-rpm.spec | 4 +++- rpm.changes | 6 ++++++ rpm.spec | 5 ++++- 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/python-rpm.spec b/python-rpm.spec index 937f429..b688725 100644 --- a/python-rpm.spec +++ b/python-rpm.spec @@ -13,7 +13,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # @@ -26,6 +26,8 @@ Release: 0 Summary: Python Bindings for Manipulating RPM Packages License: GPL-2.0-or-later Group: Development/Libraries/Python +URL: https://rpm.org/ +#Git-Clone: https://github.com/rpm-software-management/rpm Source99: rpm.spec BuildRequires: %{python_module devel} BuildRequires: file-devel diff --git a/rpm.changes b/rpm.changes index 9e0ef9d..718fd22 100644 --- a/rpm.changes +++ b/rpm.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Jun 7 15:03:15 UTC 2019 - Jan Engelhardt + +- Enable decompression and creation of zstd-based payloads. +- Add homepage and repo URL. + ------------------------------------------------------------------- Tue May 14 10:11:34 UTC 2019 - Martin Liška diff --git a/rpm.spec b/rpm.spec index 59f6f26..0723adf 100644 --- a/rpm.spec +++ b/rpm.spec @@ -12,7 +12,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # @@ -45,6 +45,7 @@ BuildRequires: popt-devel BuildRequires: rpm-build BuildRequires: xz-devel BuildRequires: zlib-devel +BuildRequires: pkgconfig(libzstd) #!BuildIgnore: rpmlint-Factory Provides: rpminst Requires(post): %fillup_prereq @@ -56,6 +57,8 @@ License: GPL-2.0-or-later Group: System/Packages Version: 4.14.2.1 Release: 0 +URL: https://rpm.org/ +#Git-Clone: https://github.com/rpm-software-management/rpm Source: http://ftp.rpm.org/releases/rpm-4.14.x/rpm-%{version}.tar.bz2 Source1: RPM-HOWTO.tar.bz2 Source5: rpmsort From bd320d622f5b04d829d6e98efc834060fcf65bb9ff776724438f779bfbf6ec0f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Schr=C3=B6der?= Date: Thu, 13 Jun 2019 14:34:11 +0000 Subject: [PATCH 4/4] tweak OBS-URL: https://build.opensuse.org/package/show/Base:System/rpm?expand=0&rev=500 --- python-rpm.spec | 3 ++- rpm.spec | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/python-rpm.spec b/python-rpm.spec index b688725..e307442 100644 --- a/python-rpm.spec +++ b/python-rpm.spec @@ -13,7 +13,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# Please submit bugfixes or comments via http://bugs.opensuse.org/ # @@ -44,6 +44,7 @@ BuildRequires: popt-devel BuildRequires: python-rpm-macros BuildRequires: xz-devel BuildRequires: zlib-devel +BuildRequires: pkgconfig(libzstd) Requires: rpm = %{version} %{expand:%(sed -n -e '/^Source:/,/^BuildRoot:/p' <%{_sourcedir}/rpm.spec)} %if "%{python_flavor}" == "python2" diff --git a/rpm.spec b/rpm.spec index 0723adf..70025c3 100644 --- a/rpm.spec +++ b/rpm.spec @@ -12,7 +12,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# Please submit bugfixes or comments via http://bugs.opensuse.org/ #