1
0

- Add patch multiple_flavors.patch which makes compile_macros.sh

generate alternative flavours as well.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:Factory/python-rpm-macros?expand=0&rev=107
This commit is contained in:
Matej Cepl 2020-09-02 11:46:53 +00:00 committed by Git OBS Bridge
parent b2689d01a4
commit e29527b47b
3 changed files with 29 additions and 5 deletions

15
multiple_flavors.patch Normal file
View File

@ -0,0 +1,15 @@
--- a/compile-macros.sh
+++ b/compile-macros.sh
@@ -1,10 +1,10 @@
#!/bin/bash
-FLAVORS="python2 python3 pypy3"
+FLAVORS="python2 python3 python36 python38 pypy3"
# order of BUILDSET is important, it is copied to order of %pythons,
# and that determines the last installed binary
-BUILDSET="python2 python3"
+BUILDSET="python2 python36 python38"
### flavor-specific: generate from flavor.in

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Wed Sep 2 11:44:33 UTC 2020 - Matej Cepl <mcepl@suse.com>
- Add patch multiple_flavors.patch which makes compile_macros.sh
generate alternative flavours as well.
------------------------------------------------------------------- -------------------------------------------------------------------
Mon Aug 24 08:09:01 UTC 2020 - mcepl@cepl.eu Mon Aug 24 08:09:01 UTC 2020 - mcepl@cepl.eu

View File

@ -23,11 +23,14 @@ Summary: RPM macros for building of Python modules
License: WTFPL License: WTFPL
URL: https://github.com/opensuse/python-rpm-macros URL: https://github.com/opensuse/python-rpm-macros
Source: python-rpm-macros-%{version}.tar.xz Source: python-rpm-macros-%{version}.tar.xz
# PATCH-FEATURE-OPENSUSE multiple_flavors.patch mcepl@suse.com
# make work with multiple python3 flavours.
Patch0: multiple_flavors.patch
# To keep user expectations reasonably sane
Recommends: python-rpm-generators
# Fedora compatibility # Fedora compatibility
Provides: python2-rpm-macros Provides: python2-rpm-macros
Provides: python3-rpm-macros Provides: python3-rpm-macros
# To keep user expectations reasonably sane
Recommends: python-rpm-generators
BuildArch: noarch BuildArch: noarch
%description %description
@ -38,10 +41,10 @@ are only building for distros newer than Leap 42.2
%package -n python-rpm-generators %package -n python-rpm-generators
Summary: Dependency generator dependencies for Python RPMs Summary: Dependency generator dependencies for Python RPMs
Requires: %{name} = %{version}-%{release} Requires: %{name} = %{version}-%{release}
# Fedora compatibility
Provides: python3-rpm-generators
# For the dep generator macros # For the dep generator macros
Requires: python3-setuptools Requires: python3-setuptools
# Fedora compatibility
Provides: python3-rpm-generators
%description -n python-rpm-generators %description -n python-rpm-generators
This package contains the dependencies for Python RPMs to generate This package contains the dependencies for Python RPMs to generate
@ -55,7 +58,7 @@ dependencies automatically.
mv macros-default-pythons macros/035-default-pythons mv macros-default-pythons macros/035-default-pythons
%endif %endif
%if 0%{?suse_version} >= 1550 %if 0%{?suse_version} >= 1550
sed -i -e '/^%system_python/s/python2/python3/' macros/010-common-defs sed -i -e '/^%{system_python}/s/python2/python3/' macros/010-common-defs
%endif %endif
%build %build