From d2b7b365f8cbb8b4e2907ff00057054ddf56c9ee87a1090dc00b12a7153597ad Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Thu, 24 Feb 2022 22:58:02 +0000 Subject: [PATCH 1/6] - Cleanup multi-version builds. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-dmidecode?expand=0&rev=4 --- python-dmidecode.changes | 4 ++-- python-dmidecode.spec | 13 ++++++++++++- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/python-dmidecode.changes b/python-dmidecode.changes index 504b5e7..21ca986 100644 --- a/python-dmidecode.changes +++ b/python-dmidecode.changes @@ -1,7 +1,7 @@ ------------------------------------------------------------------- -Thu Feb 24 06:32:14 UTC 2022 - Matej Cepl +Thu Feb 24 22:57:21 UTC 2022 - Matej Cepl -- Fix package names. +- Cleanup multi-version builds. ------------------------------------------------------------------- Sat Dec 04 00:01:25 UTC 2021 - mcepl@cepl.eu diff --git a/python-dmidecode.spec b/python-dmidecode.spec index 6f037e1..de21d72 100644 --- a/python-dmidecode.spec +++ b/python-dmidecode.spec @@ -36,7 +36,13 @@ Patch2: detect-lib-with-py3.patch # use sys.version_info instead of sys.version Patch3: 31-version_info-v-version.patch BuildRequires: %{python_module devel} +%if 0%{?sle_version} >= 150400 BuildRequires: %{python_module libxml2} +%else +BuildRequires: %{oldpython}-libxml2-python +BuildRequires: %{oldpython}3-libxml2-python +%endif +BuildRequires: fdupes BuildRequires: libxml2-devel BuildRequires: python-rpm-macros %python_subpackages @@ -66,7 +72,9 @@ sed -i 's/python2/python3/g' Makefile unit-tests/Makefile } %install -%python_expand $python src/setup.py install --root %{buildroot} --prefix=%{_prefix} +%{python_expand $python src/setup.py install --root %{buildroot} --prefix=%{_prefix} +%fdupes %{buildroot}%{$python_sitearch} +} %check pushd unit-tests @@ -75,9 +83,12 @@ pushd unit-tests } popd +%clean + %files %license doc/LICENSE %doc README doc/README.upstream doc/AUTHORS doc/AUTHORS.upstream +%dir %{_datadir}/python-dmidecode/ %{_datadir}/python-dmidecode/ %files %{python_files python-dmidecode} From 0b0647895fa07d849157b904fb3c9f3760ec385bc25f63c4cb88092de1dc4a32 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Thu, 24 Feb 2022 23:00:32 +0000 Subject: [PATCH 2/6] Fix %if condition OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-dmidecode?expand=0&rev=5 --- python-dmidecode.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python-dmidecode.spec b/python-dmidecode.spec index de21d72..571282e 100644 --- a/python-dmidecode.spec +++ b/python-dmidecode.spec @@ -36,7 +36,7 @@ Patch2: detect-lib-with-py3.patch # use sys.version_info instead of sys.version Patch3: 31-version_info-v-version.patch BuildRequires: %{python_module devel} -%if 0%{?sle_version} >= 150400 +%if 0%{?is_opensuse} || 0%{?sle_version} >= 150400 BuildRequires: %{python_module libxml2} %else BuildRequires: %{oldpython}-libxml2-python From e79592b284be52476a57b5eb4d8f7b03e4afe29a7c7e24eb3cc47a56e3205d9c Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Thu, 24 Feb 2022 23:07:10 +0000 Subject: [PATCH 3/6] Fix %if condition OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-dmidecode?expand=0&rev=6 --- python-dmidecode.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python-dmidecode.spec b/python-dmidecode.spec index 571282e..de21d72 100644 --- a/python-dmidecode.spec +++ b/python-dmidecode.spec @@ -36,7 +36,7 @@ Patch2: detect-lib-with-py3.patch # use sys.version_info instead of sys.version Patch3: 31-version_info-v-version.patch BuildRequires: %{python_module devel} -%if 0%{?is_opensuse} || 0%{?sle_version} >= 150400 +%if 0%{?sle_version} >= 150400 BuildRequires: %{python_module libxml2} %else BuildRequires: %{oldpython}-libxml2-python From 67e5e6670ed992accb475557e76f793e57548a4bf4437b84eab26e717a90cb49 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Thu, 24 Feb 2022 23:11:00 +0000 Subject: [PATCH 4/6] Fix %if condition OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-dmidecode?expand=0&rev=7 --- python-dmidecode.spec | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/python-dmidecode.spec b/python-dmidecode.spec index de21d72..86116fd 100644 --- a/python-dmidecode.spec +++ b/python-dmidecode.spec @@ -36,12 +36,16 @@ Patch2: detect-lib-with-py3.patch # use sys.version_info instead of sys.version Patch3: 31-version_info-v-version.patch BuildRequires: %{python_module devel} +%if 0%{?is_opensuse} +BuildRequires: %{python_module libxml2} +%else %if 0%{?sle_version} >= 150400 BuildRequires: %{python_module libxml2} %else BuildRequires: %{oldpython}-libxml2-python BuildRequires: %{oldpython}3-libxml2-python %endif +%endif BuildRequires: fdupes BuildRequires: libxml2-devel BuildRequires: python-rpm-macros From 6d0921eb4d06d2f9d8120766e448790a254291af12e5874346bd9ef37a68d5a6 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Thu, 24 Feb 2022 23:30:31 +0000 Subject: [PATCH 5/6] Fix %if condition OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-dmidecode?expand=0&rev=8 --- python-dmidecode.spec | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/python-dmidecode.spec b/python-dmidecode.spec index 86116fd..25788f3 100644 --- a/python-dmidecode.spec +++ b/python-dmidecode.spec @@ -36,15 +36,11 @@ Patch2: detect-lib-with-py3.patch # use sys.version_info instead of sys.version Patch3: 31-version_info-v-version.patch BuildRequires: %{python_module devel} -%if 0%{?is_opensuse} -BuildRequires: %{python_module libxml2} -%else -%if 0%{?sle_version} >= 150400 -BuildRequires: %{python_module libxml2} -%else +%if 0%{?sle_version} && 0%{?sle_version} < 150400 BuildRequires: %{oldpython}-libxml2-python BuildRequires: %{oldpython}3-libxml2-python -%endif +%else +BuildRequires: %{python_module libxml2} %endif BuildRequires: fdupes BuildRequires: libxml2-devel From 94e1751cee16c84bf09d8d4abe2fac45ffa75e8ae5be9aed95604ba4f19f852c Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Fri, 25 Feb 2022 13:18:18 +0000 Subject: [PATCH 6/6] Fix changelogs OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-dmidecode?expand=0&rev=9 --- python-dmidecode.changes | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/python-dmidecode.changes b/python-dmidecode.changes index 21ca986..d313d43 100644 --- a/python-dmidecode.changes +++ b/python-dmidecode.changes @@ -3,6 +3,11 @@ Thu Feb 24 22:57:21 UTC 2022 - Matej Cepl - Cleanup multi-version builds. +------------------------------------------------------------------- +Thu Feb 24 06:32:14 UTC 2022 - Matej Cepl + +- Fix package names. + ------------------------------------------------------------------- Sat Dec 04 00:01:25 UTC 2021 - mcepl@cepl.eu