diff --git a/.gitignore b/.gitignore index 5a9eb3a..991b358 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,2 @@ clog -/rpy2-3.0.0.tar.gz +/rpy2-3.0.1.tar.gz diff --git a/rpy.spec b/rpy.spec index 368d5f8..9de5115 100644 --- a/rpy.spec +++ b/rpy.spec @@ -1,11 +1,13 @@ %global srcname rpy %global sum Python interface to the R language %global rver 3.5.2 -%global python2 0 +%if 0%{?fedora} < 30 +%global python2 1 +%endif Name: rpy -Version: 3.0.0 +Version: 3.0.1 Release: 1%{?dist} Summary: %{sum} @@ -16,12 +18,14 @@ Source: https://files.pythonhosted.org/packages/source/r/%{srcname}2/%{sr BuildArch: noarch BuildRequires: R-devel = %{rver} -%if %{python2} -BuildRequires: python-setuptools, python2-devel +%if 0%{?python2} +BuildRequires: python2-setuptools, python2-devel +BuildRequires: python2-pytest %endif BuildRequires: python3-setuptools, python3-devel, python3-cffi BuildRequires: python3-numpy BuildRequires: readline-devel +BuildRequires: python3-pytest Requires: python3-%{srcname} = %{version}-%{release} @@ -31,7 +35,7 @@ programming language. It can manage all kinds of R objects and can execute arbitrary R functions. All the errors from the R language are converted to Python exceptions. -%if %{python2} +%if 0%{?python2} %package -n python2-%{srcname} Summary: %{sum} #Requires: python2-numpy @@ -69,20 +73,26 @@ converted to Python exceptions. # Temporary workaround to fix a bug in R # see https://stat.ethz.ch/pipermail/r-devel/2016-December/073548.html export CFLAGS="$RPM_OPT_FLAGS -DHAVE_UINTPTR_T=1" -%if %{python2} +%if 0%{?python2} %py2_build %endif %py3_build %install -%if %{python2} +%if 0%{?python2} %py2_install %endif %py3_install +%check +%if 0%{?python2} +pytest-2 tests/ +%endif +pytest-3 tests/ + %files -%if %{python2} +%if 0%{?python2} %files -n python2-%{srcname} %doc AUTHORS NEWS PKG-INFO %license gpl-2.0.txt @@ -98,6 +108,11 @@ export CFLAGS="$RPM_OPT_FLAGS -DHAVE_UINTPTR_T=1" %changelog +* Mon Mar 4 2019 José Matos - 3.0.1-1 +- update to 3.0.1 +- add conditional python2 subpackages for fedora < 30 +- add a %%chech section + * Wed Feb 27 2019 José Matos - 3.0.0-1 - update to 3.0.0 - fix the directory ownership diff --git a/sources b/sources index 1896d82..d57f39a 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (rpy2-3.0.0.tar.gz) = 25c8caf19b32bda12acb9f2245dc85d0fe3da7a1aa2d4cd888039b9b0208cbbc0b990c1b80215981fddd6667988970e285b531503129abdb1937c890c0868bb5 +SHA512 (rpy2-3.0.1.tar.gz) = 9d0d17daf30fae4392530393890025068b33e391207ae4177cd91c2fe310c176e605dac4db33962b56417c557a2081af2db065069b0802dfffc9b6cc8378ac7a