# Copyright (c) 2014 Dave Love, Liverpool University # Copyright (c) 2018 Dave Love, University of Manchester # Licence: MIT, per Fedora policy %global packname pbdDMAT %global rlibdir %{_libdir}/R/library %global cranver %(echo %version | awk -F'[.]' '{print $1"."$2"-"$3}') # Use github source if more recent than CRAN %global github 0 %global commit b170a3c590592950a902b0febf1bad8b97dbca2e %global shortcommit %(c=%{commit}; echo ${c:0:7}) Name: R-%{packname} Version: 0.5.1 Release: 3%{?commit:.git%shortcommit}%{?dist} Summary: Programming with Big Data -- Distributed Matrix Methods License: GPLv2+ URL: http://r-pbd.org/ %if 0%{?commit:1} Source0: https://github.com/RBigData/%packname/archive/%commit/%packname-%shortcommit.tar.gz %else %if 0%{?github} Source0: https://github.com/RBigData/%packname/archive/v%cranver/%{packname}-%version.tar.gz %else Source0: https://cran.r-project.org/src/contrib/Archive/pbdDMAT/%{packname}_%(echo %version | awk -F'\\.' '{print $1"."$2"-"$3}').tar.gz %endif %endif Source1: tocbibind.sty Requires: R-methods R-rlecuyer R-pbdMPI >= 0.3.1 R-pbdBASE >= 0.5.0 BuildRequires: R-devel R-methods R-rlecuyer R-pbdMPI >= 0.3.1 BuildRequires: R-pbdBASE >= 0.5.0 openmpi-devel tex(lastpage.sty) BuildRequires: tex(multirow.sty) %description pbdDMAT contains high level S3 and S4 methods for creating, modifying, and performing computations with dense, distributed matrices. This includes a new class, 'ddmatrix', for storing all of the distributed data details. Computation is handled mostly by routines from the pbdBASE package. %prep %setup -q -c %build %if 0%{?github}%{?commit:1} # Unfortunately we need to build initially at least to get DESCRIPTION # into a suitable form to pass check and then install from that, which # unfortunately builds again, though it's quite fast. %_openmpi_load export TEXINPUTS=$(dirname %SOURCE1):$TEXINPUTS R CMD build %{packname}* tar fx %{packname}*.tar.gz %endif %install %_openmpi_load export TEXINPUTS=$(dirname %SOURCE1):$TEXINPUTS mkdir -p %{buildroot}%{rlibdir} OMPI_MCA_orte_allocation_required=0 OMPI_MCA_orte_rsh_agent=/bin/false \ R CMD INSTALL -l %{buildroot}%{rlibdir} %{packname} test -d %{packname}/src && (cd %{packname}/src; rm -f *.o *.so) rm -f %{buildroot}%{rlibdir}/R.css %check %_openmpi_load OMPI_MCA_orte_allocation_required=0 OMPI_MCA_orte_rsh_agent=/bin/false \ R CMD check %{packname} %{!?_licensedir:%global license %doc} %files %dir %{rlibdir}/%{packname} %license pbdDMAT/COPYING %doc %{rlibdir}/%{packname}/doc %doc %{rlibdir}/%{packname}/html %doc %{rlibdir}/%{packname}/DESCRIPTION %doc %{rlibdir}/%{packname}/CITATION %{rlibdir}/%{packname}/INDEX %{rlibdir}/%{packname}/NAMESPACE %{rlibdir}/%{packname}/Meta %{rlibdir}/%{packname}/R %{rlibdir}/%{packname}/help %{rlibdir}/%{packname}/demo %{rlibdir}/%{packname}/examples %{rlibdir}/%{packname}/RNACI %{rlibdir}/%{packname}/libs %exclude %{rlibdir}/%{packname}/tests_batch %exclude %{rlibdir}/%{packname}/batchtests %changelog * Fri Sep 3 2021 - 0.5.1-3b170a3c590592950a902b0febf1bad8b97dbca2e:.git%shortcommit}%{?dist} - Use development version to fix generic function error with R 4.1 - Ship tocbibind.sty * Thu Sep 2 2021 - 0.5.1-2 - Fix Source0 * Tue Apr 23 2019 Dave Love - 0.5.1-1 - New version * Tue May 8 2018 Dave Love - 0.5.0-1 - New version (corresponding to pbdR 1.0-1 release) - Fix up to get check passing with github source * Mon Nov 14 2016 Dave Love - 0.4.2-1 - New version - Install license * Wed Feb 24 2016 Dave Love - 0.4.0-1 - New version - No longer noarch - Don't BR latex * Wed Dec 17 2014 Dave Love - 0.2.3-2 - Set MCA params when building * Sat Nov 22 2014 Dave Love - 0.2.3-1 - initial package for Fedora