| |
@@ -155,6 +155,17 @@
|
| |
)
|
| |
}
|
| |
|
| |
+ # This is intended for Python 3.6 only, hence no Python version in the name
|
| |
+ %__pytest /usr/bin/pytest-3
|
| |
+ %pytest %{expand:\\\
|
| |
+ CFLAGS="${CFLAGS:-${RPM_OPT_FLAGS}}" LDFLAGS="${LDFLAGS:-${RPM_LD_FLAGS}}"\\\
|
| |
+ PATH="%{buildroot}%{_bindir}:$PATH"\\\
|
| |
+ PYTHONPATH="${PYTHONPATH:-%{buildroot}%{python3_sitearch}:%{buildroot}%{python3_sitelib}}"\\\
|
| |
+ PYTHONDONTWRITEBYTECODE=1\\\
|
| |
+ %{?__pytest_addopts:PYTEST_ADDOPTS="${PYTEST_ADDOPTS:-} %{__pytest_addopts}"}\\\
|
| |
+ %__pytest}
|
| |
+
|
| |
+
|
| |
# Backport from 4.15
|
| |
%_smp_build_ncpus %([ -z "$RPM_BUILD_NCPUS" ] \\\
|
| |
&& RPM_BUILD_NCPUS="`/usr/bin/getconf _NPROCESSORS_ONLN`"; \\\
|
| |
As requested by @rebus.
I have tested this with a simple specfile and seems to work.