Switch %%__python3 to /usr/libexec/system-python

This commit is contained in:
Michal Cyprian 2017-02-17 14:48:08 +01:00
commit d019d2fd4d
2 changed files with 9 additions and 5 deletions

View file

@ -1,4 +1,5 @@
%__python3 /usr/bin/python3
%__python3 /usr/libexec/system-python
%__python3_bin /usr/bin/python3
%python3_sitelib %(%{__python3} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")
%python3_sitearch %(%{__python3} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")
%python3_version %(%{__python3} -c "import sys; sys.stdout.write(sys.version[:3])")
@ -10,7 +11,7 @@
# Use the slashes after expand so that the command starts on the same line as
# the macro
%py3_build() %{expand:\\\
CFLAGS="%{optflags}" %{__python3} %{py_setup} %{?py_setup_args} build --executable="%{__python3} %{py3_shbang_opts}" %{?*}
CFLAGS="%{optflags}" %{__python3} %{py_setup} %{?py_setup_args} build --executable="%{__python3_bin} %{py3_shbang_opts}" %{?*}
sleep 1
}
@ -25,7 +26,7 @@
}
%py3_install() %{expand:\\\
CFLAGS="%{optflags}" %{__python3} %{py_setup} %{?py_setup_args} install -O1 --skip-build --root %{buildroot} %{?*}
CFLAGS="%{optflags}" %{__python3} %{py_setup} %{?py_setup_args} install -O1 --skip-build --root %{buildroot} --executable="%{__python3_bin} %{py3_shbang_opts}" %{?*}
}
%py3_install_egg() %{expand:\\\
@ -34,5 +35,5 @@
}
%py3_install_wheel() %{expand:\\\
pip%{python3_version} install -I dist/%{1} --root %{buildroot} --strip-file-prefix %{buildroot} --no-deps
pip%{python3_version} install -I dist/%{1} --root %{buildroot} --strip-file-prefix %{buildroot} --prefix %{_prefix} --no-deps
}