%global __brp_check_rpaths %{nil} %global packname fractional %global packver 0.1.3 %global rlibdir /usr/local/lib/R/library Name: R-CRAN-%{packname} Version: 0.1.3 Release: 3%{?dist}%{?buildtag} Summary: Vulgar Fractions in R License: GPL (>= 2) URL: https://cran.r-project.org/package=%{packname} Source0: %{url}&version=%{packver}#/%{packname}_%{packver}.tar.gz BuildRequires: R-devel Requires: R-core BuildRequires: R-CRAN-Rcpp Requires: R-CRAN-Rcpp %description The main function of this package allows numerical vector objects to be displayed with their values in vulgar fractional form. This is convenient if patterns can then be more easily detected. In some cases replacing the components of a numeric vector by a rational approximation can also be expected to remove some component of round-off error. The main functions form a re-implementation of the functions 'fractions' and 'rational' of the MASS package, but using a radically improved programming strategy. %prep %setup -q -c -n %{packname} %build %install mkdir -p %{buildroot}%{rlibdir} %{_bindir}/R CMD INSTALL -l %{buildroot}%{rlibdir} %{packname} test -d %{packname}/src && (cd %{packname}/src; rm -f *.o *.so) rm -f %{buildroot}%{rlibdir}/R.css %files %{rlibdir}/%{packname}