From 2ac128eb0fba45d4cbd02374b5c7b3a57055ee26 Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Mon, 17 Dec 2007 16:42:17 +0000 Subject: add rpm 4.4.6 python macros for compatibility (even if it overlaps with py_* macros) --- macros.in | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/macros.in b/macros.in index d676ad9..f583d62 100644 --- a/macros.in +++ b/macros.in @@ -613,8 +613,16 @@ Internationalization and locale data for %{?1:%{1}}%{?!1:%{name}}\ %%files -n %{?1:%{1}}%{?!1:%{name}}-i18n %{?-f:%{-f}}%{?!-f:-f %{?1:%{1}}%{?!1:%{name}}.lang}\ %{nil} + #------------------------------------------------------------------------------ -# Python specific macro definitions (originally from PLD). +# Python specific macros + +# (from rpm 4.4.6) +%python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)") +%python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()") +%python_version %(%{__python} -c "import sys; print(sys.version[0:3])") + +# More Python specific macro definitions (originally from PLD). # %py_ver %(python -c "import sys; v=sys.version_info[:2]; print '%%d.%%d'%%v" 2>/dev/null || echo PYTHON-NOT-FOUND) %py_prefix %(python -c "import sys; print sys.prefix" 2>/dev/null || echo PYTHON-NOT-FOUND) -- cgit v1.2.1