# Licence: MIT, per Fedora policy %global packname pbdDEMO %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 1 Name: R-%{packname} Version: 0.3.2 Release: 3%{?dist} Summary: Programming with Big Data -- Demonstrations of pbd Packages License: GPLv2+ URL: http://r-pbd.org/ %if 0%{?github} Source0: https://github.com/RBigData/%packname/archive/v%cranver/%{packname}-%version.tar.gz %else Source0: http://cran.r-project.org/src/contrib/%{packname}_%(echo %version | awk -F'\.' '{print $1"."$2"-"$3}').tar.gz %endif Source1: http://tug.ctan.org/macros/latex/contrib/algorithmicx/algpseudocode.sty Source2: http://tug.ctan.org/macros/latex/contrib/algorithmicx/algorithmicx.sty Source3: http://mirrors.ctan.org/macros/latex/contrib/tocbibind.zip Requires: R-methods, R-rlecuyer%{_isa} R-pbdDMAT%{_isa} >= 0.4.0 BuildRequires: R-devel R-methods R-rlecuyer R-pbdDMAT >= 0.4.0 BuildRequires: tex(latex) openmpi-devel tex(lastpage.sty) tex(multirow.sty) BuildRequires: tex(fncychap.sty) tex(framed.sty) tex(titletoc.sty) BuildRequires: tex(textpos.sty) tex(everypage.sty) # Was noarch Obsoletes: %name < 0.3.2 %description pbdDEMO is a set of demos of pbdR packages, with a useful, unifying vignette. %prep %setup -q -c -n %{packname} # # CRAN comes out as %packname, github as %packname-%cranver #cp %SOURCE1 %SOURCE2 %{packname}*/vignettes/pbdDEMO-include unzip %SOURCE3 cd tocbibind latex tocbibind.ins %build %if 0%{?github} # 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 TEXINPUTS=.:$(dirname %SOURCE1):$(pwd)/tocbibind: \ R CMD build %{packname}* tar fx %{packname}*.tar.gz %endif %install mkdir -p %{buildroot}%{rlibdir} %_openmpi_load 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 \ %{_bindir}/R CMD check %{packname} %files %dir %{rlibdir}/%{packname} %doc %{rlibdir}/%{packname}/doc %doc %{rlibdir}/%{packname}/html %{rlibdir}/%{packname}/DESCRIPTION %{rlibdir}/%{packname}/CITATION %{rlibdir}/%{packname}/INDEX %{rlibdir}/%{packname}/NAMESPACE %{rlibdir}/%{packname}/Meta %{rlibdir}/%{packname}/R %{rlibdir}/%{packname}/help %{rlibdir}/%{packname}/demo %{rlibdir}/%{packname}/data %{rlibdir}/%{packname}/extra %{rlibdir}/%{packname}/Benchmarks %{rlibdir}/%{packname}/libs %changelog * Tue Apr 23 2019 Dave Love - 0.3.2-3 - Rebuild for current R - BR several things to fix doc build * Tue Apr 23 2019 Dave Love - 0.3.2-2 - Rebuild for current R * Tue May 8 2018 Dave Love - 0.3.2-1 - New version (corresponding to pbdR 1.0-1 release) - Fix up to get check passing with github source - Fix some erroneous %%doc * Mon Nov 14 2016 Dave Love - 0.3.1-2 - Small spec fixes; BR latex again (for fedora-review) * Sun Nov 13 2016 Dave Love - 0.3.1-1 - New version - Adjust for new binary content - Supply LaTeX style * Wed Aug 17 2016 Dave Love - 0.3.0-2 - Clean spec for el6+ * Wed Feb 24 2016 Dave Love - 0.3.0-1 - New version - Don't BR latex * Sun Nov 23 2014 Dave Love - 0.2.0-1 - Initial packaging