| |
@@ -0,0 +1,37 @@
|
| |
+ From d8c2046256644e32ae35d562e6582f187444a8af Mon Sep 17 00:00:00 2001
|
| |
+ From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
|
| |
+ Date: Tue, 17 Jul 2018 13:01:44 +0200
|
| |
+ Subject: [PATCH] macros: make unversioned python macros not expand to empty
|
| |
+ when the executable is not installed
|
| |
+
|
| |
+ In Fedora the removal of /usr/bin/python in favour of explicit
|
| |
+ /usr/bin/python2 and /usr/bin/python3 is happening now. Unless
|
| |
+ python-unversioned-command.rpm is installed, /usr/bin/python does not
|
| |
+ exists. This means that packages use
|
| |
+ %python_{sitelib,sitearch,version}, they get a warning in the build
|
| |
+ log, and the macro evaluates to an empty string.
|
| |
+ It seems better to keep the unexpanded macro instead, as if it wasn't
|
| |
+ defined at all.
|
| |
+
|
| |
+ See https://bugzilla.redhat.com/show_bug.cgi?id=1585626#c4.
|
| |
+ ---
|
| |
+ macros.in | 6 +++---
|
| |
+ 1 file changed, 3 insertions(+), 3 deletions(-)
|
| |
+
|
| |
+ diff --git a/macros.in b/macros.in
|
| |
+ index a69a8964d..32b35f2ac 100644
|
| |
+ --- a/macros.in
|
| |
+ +++ b/macros.in
|
| |
+ @@ -1102,9 +1102,9 @@ package or when debugging this package.\
|
| |
+ #------------------------------------------------------------------------------
|
| |
+ # Useful python macros for determining python version and paths
|
| |
+ #
|
| |
+ -%python_sitelib %(%{__python} -Es %{_rpmconfigdir}/python-macro-helper sitelib)
|
| |
+ -%python_sitearch %(%{__python} -Es %{_rpmconfigdir}/python-macro-helper sitearch)
|
| |
+ -%python_version %(%{__python} -Es %{_rpmconfigdir}/python-macro-helper version)
|
| |
+ +%python_sitelib %(%{__python} -Es %{_rpmconfigdir}/python-macro-helper sitelib || echo %%{python_sitelib})
|
| |
+ +%python_sitearch %(%{__python} -Es %{_rpmconfigdir}/python-macro-helper sitearch || echo %%{python_sitearch})
|
| |
+ +%python_version %(%{__python} -Es %{_rpmconfigdir}/python-macro-helper version || echo %%{python_version})
|
| |
+
|
| |
+ #------------------------------------------------------------------------------
|
| |
+ # arch macro for all Intel i?86 compatible processors
|
| |
https://bugzilla.redhat.com/show_bug.cgi?id=1585626#c9
https://fedoraproject.org/wiki/Changes/Move_usr_bin_python_into_separate_package