From 5cc3e1edce59d417038476d8ef3c710973496a2d19b0267dc27a144575129878 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Tue, 3 Nov 2020 20:55:53 +0000 Subject: [PATCH 1/2] Accepting request 845821 from home:bnavigator:branches:devel:languages:python - Fix lang files collection for multiple flavors * gh#openSUSE/python-rpm-macros#5 * gh#openSUSE/python-rpm-macros#66 OBS-URL: https://build.opensuse.org/request/show/845821 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-Sphinx?expand=0&rev=164 --- python-Sphinx.changes | 7 +++++++ python-Sphinx.spec | 9 +++++++-- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/python-Sphinx.changes b/python-Sphinx.changes index d38b9a2..77cfe1d 100644 --- a/python-Sphinx.changes +++ b/python-Sphinx.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Tue Nov 3 19:56:15 UTC 2020 - Benjamin Greiner + +- Fix lang files collection for multiple flavors + * gh#openSUSE/python-rpm-macros#5 + * gh#openSUSE/python-rpm-macros#66 + ------------------------------------------------------------------- Mon Sep 28 13:45:37 UTC 2020 - Dirk Mueller diff --git a/python-Sphinx.spec b/python-Sphinx.spec index d9bb227..c16d02f 100644 --- a/python-Sphinx.spec +++ b/python-Sphinx.spec @@ -251,7 +251,12 @@ mv build/sphinx/{html,man} build.doc/ %python_expand mkdir -p %{buildroot}%{$python_sitelib}/sphinxcontrib %python_expand %fdupes %{buildroot}%{$python_sitelib} -%find_lang sphinx +%{?python_find_lang sphinx}%{?!python_find_lang:%find_lang sphinx +%{python_expand langfile=sphinx.lang +grep -v 'python.*site-packages' ${langfile} > %{$python_prefix}-${langfile} +grep -F %{$python_sitelib} ${langfile} >> %{$python_prefix}-${langfile} +} +} %else mkdir -p %{buildroot}%{_docdir}/python-Sphinx/ @@ -282,7 +287,7 @@ export LC_ALL="C.utf8" %endif %if ! %{with test} -%files %{python_files} -f sphinx.lang +%files %{python_files} -f %{python_prefix}-sphinx.lang %license LICENSE %doc AUTHORS CHANGES README.rst %python_alternative %{_bindir}/sphinx-apidoc From 1fe482d81c589a5e965d79459d116e8b60a2d96c10f5c6b270fc321f0d22ed17 Mon Sep 17 00:00:00 2001 From: Matej Cepl Date: Wed, 4 Nov 2020 19:50:22 +0000 Subject: [PATCH 2/2] Accepting request 845960 from home:bnavigator:branches:devel:languages:python - Fix the lang collection macro override. * gh#openSUSE/python-rpm-macros#66 * gh#openSUSE/python-rpm-macros#74 OBS-URL: https://build.opensuse.org/request/show/845960 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-Sphinx?expand=0&rev=165 --- python-Sphinx.changes | 7 +++++++ python-Sphinx.spec | 14 +++++++++----- 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/python-Sphinx.changes b/python-Sphinx.changes index 77cfe1d..4b4b833 100644 --- a/python-Sphinx.changes +++ b/python-Sphinx.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Wed Nov 4 11:10:14 UTC 2020 - Benjamin Greiner + +- Fix the lang collection macro override. + * gh#openSUSE/python-rpm-macros#66 + * gh#openSUSE/python-rpm-macros#74 + ------------------------------------------------------------------- Tue Nov 3 19:56:15 UTC 2020 - Benjamin Greiner diff --git a/python-Sphinx.spec b/python-Sphinx.spec index c16d02f..f339546 100644 --- a/python-Sphinx.spec +++ b/python-Sphinx.spec @@ -251,12 +251,16 @@ mv build/sphinx/{html,man} build.doc/ %python_expand mkdir -p %{buildroot}%{$python_sitelib}/sphinxcontrib %python_expand %fdupes %{buildroot}%{$python_sitelib} -%{?python_find_lang sphinx}%{?!python_find_lang:%find_lang sphinx -%{python_expand langfile=sphinx.lang -grep -v 'python.*site-packages' ${langfile} > %{$python_prefix}-${langfile} -grep -F %{$python_sitelib} ${langfile} >> %{$python_prefix}-${langfile} -} +# gh#openSUSE/python-rpm-macros#74 +%{!?python_find_lang: %define python_find_lang() \ +%find_lang %{**} \ +langfile=%{?2}%{!?2:%1.lang} \ +%{python_expand # \ +grep -v 'python.*site-packages' ${langfile} > %{$python_prefix}-${langfile} \ +grep -F %{$python_sitelib} ${langfile} >> %{$python_prefix}-${langfile} \ +} \ } +%python_find_lang sphinx %else mkdir -p %{buildroot}%{_docdir}/python-Sphinx/