X-Git-Url: http://git.pld-linux.org/?a=blobdiff_plain;f=rpm-macros.python;h=f41c4dde2d9e9d9f5ed4a0ea70a0110b607a422a;hb=31d04fdd282bb07e7c43b44c5ad8a9524c05364d;hp=d437e0fef40d230a51e14f66f9bc3a8a222db817;hpb=bef185f2daec3bb09c468262aecfa8fd88cbafab;p=packages%2Frpm.git diff --git a/rpm-macros.python b/rpm-macros.python index d437e0f..f41c4dd 100644 --- a/rpm-macros.python +++ b/rpm-macros.python @@ -8,7 +8,7 @@ # directories %define py_prefix %(echo `python -c "import sys; print sys.prefix"`) %define py_libdir %{py_prefix}/lib/python%{py_ver} -%define py_incdir %{_includedir}/python%{py_ver} +%define py_incdir /usr/include/python%{py_ver} %define py_sitedir %{py_libdir}/site-packages %define py_dyndir %{py_libdir}/lib-dynload @@ -16,3 +16,8 @@ %define py_comp python -c "import compileall; import sys; compileall.compile_dir(sys.argv[1], ddir=sys.argv[1][len('$RPM_BUILD_ROOT'):])" %define py_ocomp python -O -c "import compileall; import sys; compileall.compile_dir(sys.argv[1], ddir=sys.argv[1][len('$RPM_BUILD_ROOT'):])" + +# Software written in Python language require Python with main version +# unchanged +%define pyrequires_eq() Requires: %1 >= %py_ver %1 < %(echo `python -c "import sys; import string; ver=sys.version[:3].split('.'); ver[1]=str(int(ver[1])+1); print string.join(ver, '.')"`) +