LANG=C\
export LANG\
unset DISPLAY ||:\
+unset LINGUAS ||:\
%{nil}
%build %%build\
LANG=C\
export LANG\
unset DISPLAY ||:\
+unset LINGUAS ||:\
%{nil}
%install %{?_enable_debug_packages:%{?buildsubdir:%{debug_package}}}\
LANG=C\
export LANG\
unset DISPLAY ||:\
+unset LINGUAS ||:\
%{nil}
# ------------------------------------------------------------------------
%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
-%pyrequires_eq() Requires: python(bytecode) = %py_ver %1
+%pyrequires_eq() Requires: python(abi) = %py_ver %1
# Hardlink binary identical .pyc and .pyo files
# (idea by glen <at> pld-linux <dot> org)
%__spec_install_post_py_hardlink {\
-%{!?no_install_post_py_hardlink:
+%{!?no_install_post_py_hardlink: \
[ ! -d "$RPM_BUILD_ROOT" ] || find "$RPM_BUILD_ROOT" -name '*.pyc' | while read a; do \
b="$(echo $a|sed -e 's/.pyc$/.pyo/')"; \
if cmp -s "$a" "$b"; then \