From ba5b61083ce34c2eef5e08d15f1e58ba7e42ebde Mon Sep 17 00:00:00 2001 From: Gwyn Ciesla Date: Thu, 15 Aug 2019 15:17:08 -0500 Subject: [PATCH 01/12] "Adding package.cfg file" --- package.cfg | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 package.cfg diff --git a/package.cfg b/package.cfg new file mode 100644 index 0000000..66ea79d --- /dev/null +++ b/package.cfg @@ -0,0 +1,2 @@ +[koji] +targets = epel8 epel8-playground \ No newline at end of file From 56020a5336f3c0239f760d5917639401ccb623ed Mon Sep 17 00:00:00 2001 From: Tom Callaway Date: Fri, 30 Aug 2019 07:47:29 -0400 Subject: [PATCH 02/12] conditionalize macro usage so that it only happens on Fedora 31+ and EPEL-8 --- R.spec | 48 +++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 47 insertions(+), 1 deletion(-) diff --git a/R.spec b/R.spec index 198b649..64a7cd6 100644 --- a/R.spec +++ b/R.spec @@ -3,6 +3,16 @@ %global runjavareconf 1 +%if %{?fedora} >= 31 +%global usemacros 1 +%else +%if 0%{?rhel} && 0%{?rhel} >= 8 +%global usemacros 1 +%else +%global usemacros 0 +%endif +%endif + %if 0%{?rhel} && 0%{?rhel} <= 6 %ifarch ppc64 ppc64le %global runjavareconf 0 @@ -120,7 +130,7 @@ Name: R Version: 3.6.1 -Release: 1%{?dist} +Release: 2%{?dist} Summary: A language for data analysis and graphics URL: http://www.r-project.org Source0: https://cran.r-project.org/src/base/R-3/R-%{version}.tar.gz @@ -295,6 +305,7 @@ Requires: openblas-Rblas Requires: devtoolset-%{dts_version}-toolchain %endif +%if %{usemacros} # These are the submodules that R-core provides. Sometimes R modules say they # depend on one of these submodules rather than just R. These are provided for # packager convenience. @@ -336,6 +347,36 @@ Obsoletes: R-Matrix < 0.999375-7 %add_submodule tools %{version} %add_submodule translations %{version} %add_submodule utils %{version} +%else +Provides: R-base = %{version} +Provides: R-boot = 1.3.22 +Provides: R-class = 7.3.15 +Provides: R-cluster = 2.1.0 +Provides: R-codetools = 0.2.16 +Provides: R-datasets = %{version} +Provides: R-foreign = 0.8.71 +Provides: R-graphics = %{version} +Provides: R-grDevices = %{version} +Provides: R-grid = %{version} +Provides: R-KernSmooth = 2.23.15 +Provides: R-lattice = 0.20.38 +Provides: R-MASS = 7.3.51.4 +Provides: R-Matrix = 1.2.17 +Provides: R-methods = %{version} +Provides: R-mgcv = 1.8.28 +Provides: R-nlme = 3.1.140 +Provides: R-nnet = 7.3.12 +Provides: R-parallel = %{version} +Provides: R-rpart = 4.1.15 +Provides: R-spatial = 7.3.11 +Provides: R-splines = %{version} +Provides: R-stats = %{version} +Provides: R-stats4 = %{version} +Provides: R-survival = 2.44.1.1 +Provides: R-tcltk = %{version} +Provides: R-tools = %{version} +Provides: R-utils = %{version} +%endif %description core A language and environment for statistical computing and graphics. @@ -405,7 +446,9 @@ Install R-core-devel if you are going to develop or compile R packages. %package devel Summary: Full R development environment metapackage +%if %{usemacros} Requires: R-rpm-macros +%endif Requires: R-core-devel = %{version}-%{release} %if %{modern} Requires: R-java-devel = %{version}-%{release} @@ -1202,6 +1245,9 @@ R CMD javareconf \ %{_libdir}/libRmath.a %changelog +* Fri Aug 30 2019 Tom Callaway - 3.6.1-2 +- conditionalize macro usage so that it only happens on Fedora 31+ and EPEL-8 + * Fri Aug 16 2019 Tom Callaway - 3.6.1-1 - update to 3.6.1 From 97642563e22bb0453d1daf9747fe30990ab16afa Mon Sep 17 00:00:00 2001 From: Tom Callaway Date: Fri, 30 Aug 2019 07:49:38 -0400 Subject: [PATCH 03/12] minor fix --- R.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/R.spec b/R.spec index 64a7cd6..d986d5a 100644 --- a/R.spec +++ b/R.spec @@ -3,7 +3,7 @@ %global runjavareconf 1 -%if %{?fedora} >= 31 +%if 0%{?fedora} >= 31 %global usemacros 1 %else %if 0%{?rhel} && 0%{?rhel} >= 8 From d5f66af54f22518ec347a5b3c7f8f437dfb89c3a Mon Sep 17 00:00:00 2001 From: Tom Callaway Date: Fri, 30 Aug 2019 07:52:21 -0400 Subject: [PATCH 04/12] do not need to conditionalize lua magic provides generation --- R.spec | 31 ------------------------------- 1 file changed, 31 deletions(-) diff --git a/R.spec b/R.spec index d986d5a..775b0d8 100644 --- a/R.spec +++ b/R.spec @@ -305,7 +305,6 @@ Requires: openblas-Rblas Requires: devtoolset-%{dts_version}-toolchain %endif -%if %{usemacros} # These are the submodules that R-core provides. Sometimes R modules say they # depend on one of these submodules rather than just R. These are provided for # packager convenience. @@ -347,36 +346,6 @@ Obsoletes: R-Matrix < 0.999375-7 %add_submodule tools %{version} %add_submodule translations %{version} %add_submodule utils %{version} -%else -Provides: R-base = %{version} -Provides: R-boot = 1.3.22 -Provides: R-class = 7.3.15 -Provides: R-cluster = 2.1.0 -Provides: R-codetools = 0.2.16 -Provides: R-datasets = %{version} -Provides: R-foreign = 0.8.71 -Provides: R-graphics = %{version} -Provides: R-grDevices = %{version} -Provides: R-grid = %{version} -Provides: R-KernSmooth = 2.23.15 -Provides: R-lattice = 0.20.38 -Provides: R-MASS = 7.3.51.4 -Provides: R-Matrix = 1.2.17 -Provides: R-methods = %{version} -Provides: R-mgcv = 1.8.28 -Provides: R-nlme = 3.1.140 -Provides: R-nnet = 7.3.12 -Provides: R-parallel = %{version} -Provides: R-rpart = 4.1.15 -Provides: R-spatial = 7.3.11 -Provides: R-splines = %{version} -Provides: R-stats = %{version} -Provides: R-stats4 = %{version} -Provides: R-survival = 2.44.1.1 -Provides: R-tcltk = %{version} -Provides: R-tools = %{version} -Provides: R-utils = %{version} -%endif %description core A language and environment for statistical computing and graphics. From 0a1dce5e754a98340feb419398908898c1554954 Mon Sep 17 00:00:00 2001 From: Pete Walter Date: Fri, 1 Nov 2019 16:01:43 +0000 Subject: [PATCH 05/12] Rebuild for ICU 65 --- R.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/R.spec b/R.spec index 775b0d8..2476268 100644 --- a/R.spec +++ b/R.spec @@ -130,7 +130,7 @@ Name: R Version: 3.6.1 -Release: 2%{?dist} +Release: 3%{?dist} Summary: A language for data analysis and graphics URL: http://www.r-project.org Source0: https://cran.r-project.org/src/base/R-3/R-%{version}.tar.gz @@ -1214,6 +1214,9 @@ R CMD javareconf \ %{_libdir}/libRmath.a %changelog +* Fri Nov 01 2019 Pete Walter - 3.6.1-3 +- Rebuild for ICU 65 + * Fri Aug 30 2019 Tom Callaway - 3.6.1-2 - conditionalize macro usage so that it only happens on Fedora 31+ and EPEL-8 From 063aebf8619fb1043cdeee4178d3724aa7c7cc8e Mon Sep 17 00:00:00 2001 From: Tom Callaway Date: Thu, 12 Dec 2019 12:03:39 -0500 Subject: [PATCH 06/12] update to 3.6.2 --- .gitignore | 4 ++++ R.spec | 35 +++++++++++++++++++---------------- sources | 8 ++++---- 3 files changed, 27 insertions(+), 20 deletions(-) diff --git a/.gitignore b/.gitignore index e622e2d..4f2a9ae 100644 --- a/.gitignore +++ b/.gitignore @@ -29,3 +29,7 @@ /R-3.5.3.tar.gz /R-3.6.0.tar.gz /R-3.6.1.tar.gz +/R-3.6.2.tar.gz +/bzip2-1.0.8.tar.gz +/pcre-8.43.tar.bz2 +/curl-7.67.0.tar.bz2 diff --git a/R.spec b/R.spec index 2476268..76b4fae 100644 --- a/R.spec +++ b/R.spec @@ -129,8 +129,8 @@ %endif Name: R -Version: 3.6.1 -Release: 3%{?dist} +Version: 3.6.2 +Release: 1%{?dist} Summary: A language for data analysis and graphics URL: http://www.r-project.org Source0: https://cran.r-project.org/src/base/R-3/R-%{version}.tar.gz @@ -150,14 +150,14 @@ Source106: https://cran.r-project.org/doc/FAQ/R-FAQ.html %endif %if %{zlibhack} %global zlibv 1.2.11 -%global bzipv 1.0.6 +%global bzipv 1.0.8 %global xzv 5.2.4 -%global pcrev 8.42 -%global curlv 7.63.0 +%global pcrev 8.43 +%global curlv 7.67.0 Source1000: http://zlib.net/zlib-%{zlibv}.tar.gz -Source1001: http://www.bzip.org/1.0.6/bzip2-%{bzipv}.tar.gz +Source1001: https://www.sourceware.org/pub/bzip2/bzip2-%{bzipv}.tar.gz Source1002: http://tukaani.org/xz/xz-%{xzv}.tar.bz2 -Source1003: ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-%{pcrev}.tar.bz2 +Source1003: https://ftp.pcre.org/pub/pcre/pcre-%{pcrev}.tar.bz2 Source1004: https://curl.haxx.se/download/curl-%{curlv}.tar.bz2 BuildRequires: glibc-devel BuildRequires: groff @@ -316,24 +316,24 @@ Requires: devtoolset-%{dts_version}-toolchain print("Provides: R(" .. name .. ") = " .. version) } %add_submodule base %{version} -%add_submodule boot 1.3-22 +%add_submodule boot 1.3-23 %add_submodule class 7.3-15 -%add_submodule cluster 2.0.8 +%add_submodule cluster 2.1.0 %add_submodule codetools 0.2-16 %add_submodule compiler %{version} %add_submodule datasets %{version} -%add_submodule foreign 0.8-71 +%add_submodule foreign 0.8-72 %add_submodule graphics %{version} %add_submodule grDevices %{version} %add_submodule grid %{version} -%add_submodule KernSmooth 2.23-15 +%add_submodule KernSmooth 2.23-16 %add_submodule lattice 0.20-38 %add_submodule MASS 7.3-51.4 -%add_submodule Matrix 1.2-17 +%add_submodule Matrix 1.2-18 Obsoletes: R-Matrix < 0.999375-7 %add_submodule methods %{version} -%add_submodule mgcv 1.8-28 -%add_submodule nlme 3.1-139 +%add_submodule mgcv 1.8-31 +%add_submodule nlme 3.1-142 %add_submodule nnet 7.3-12 %add_submodule parallel %{version} %add_submodule rpart 4.1-15 @@ -341,7 +341,7 @@ Obsoletes: R-Matrix < 0.999375-7 %add_submodule splines %{version} %add_submodule stats %{version} %add_submodule stats4 %{version} -%add_submodule survival 2.44-1.1 +%add_submodule survival 3.1-8 %add_submodule tcltk %{version} %add_submodule tools %{version} %add_submodule translations %{version} @@ -400,7 +400,7 @@ Requires: tex(cm-super-ts1.enc) Requires: qpdf %endif -Provides: R-Matrix-devel = 1.2.17 +Provides: R-Matrix-devel = 1.2.18 Obsoletes: R-Matrix-devel < 0.999375-7 %if %{modern} @@ -1214,6 +1214,9 @@ R CMD javareconf \ %{_libdir}/libRmath.a %changelog +* Thu Dec 12 2019 Tom Callaway - 3.6.2-1 +- update to 3.6.2 + * Fri Nov 01 2019 Pete Walter - 3.6.1-3 - Rebuild for ICU 65 diff --git a/sources b/sources index 4ab6d77..189a1c3 100644 --- a/sources +++ b/sources @@ -1,6 +1,6 @@ SHA512 (zlib-1.2.11.tar.gz) = 73fd3fff4adeccd4894084c15ddac89890cd10ef105dd5e1835e1e9bbb6a49ff229713bd197d203edfa17c2727700fce65a2a235f07568212d820dca88b528ae -SHA512 (bzip2-1.0.6.tar.gz) = 00ace5438cfa0c577e5f578d8a808613187eff5217c35164ffe044fbafdfec9e98f4192c02a7d67e01e5a5ccced630583ad1003c37697219b0f147343a3fdd12 -SHA512 (pcre-8.42.tar.bz2) = b47b923108f6ee0c31409b79d0888314271b482a22590e164d02f21d2112fba22dd0342c24f9ba0f5fcc5b8c65550bad08c476e30a2fc79b34ecf4601ed82f3d SHA512 (xz-5.2.4.tar.bz2) = 25a548c34a304ba51cdaa63813df0fa4ac2f3cf0ec6dc2d181ec5b62fe586090cd0f1c866ee7ba19e9b264ecabf9ca9f2f1dda7f95313546da4152f3cfaa7e6e -SHA512 (curl-7.63.0.tar.bz2) = 2873ef57b15cf12e508626f4546f6e06450cb87b239be1d26d9b3a22f7533d76eebabb5fa00e7b8c5d7fc9854356997ce164afb069411d079b2b9f0bdb00db25 -SHA512 (R-3.6.1.tar.gz) = fae7d114437c4b5d10fcb2a4265acd707ad2a4810eeb7c11e25caca1d85093a1495c2e13457b4894c1508830ec1b2be95379b7d54007cf3e574c2a9eea28ef80 +SHA512 (R-3.6.2.tar.gz) = 17513e9f4dd27c61c11f7aa45227aeeeefb375bf5d4e193b471724f379a1b2da33e127cbe91aa175cbbbb048b892047e2f610280585c8159242a6c94790b07f9 +SHA512 (bzip2-1.0.8.tar.gz) = 083f5e675d73f3233c7930ebe20425a533feedeaaa9d8cc86831312a6581cefbe6ed0d08d2fa89be81082f2a5abdabca8b3c080bf97218a1bd59dc118a30b9f3 +SHA512 (pcre-8.43.tar.bz2) = 3b4ac2c7ccd77c9575d07a33c3456f40b50731029e62d01fb8f2f5871d7118e12bc9e6bc7a8079769c765e38da5ecf98c4b261b10ff0a2f14f0881b434f67af7 +SHA512 (curl-7.67.0.tar.bz2) = 096e12be86bca1c19ba9e1d98b8342ec0d76b2e00cab322a7109d1e3559343ff7702b993c772f221fa073d2b8b6ffe6535d15411819fb245d3fa2c18e110b0a5 From 86fb95abbe5ee8c6cbfd719b1bf3c9b5198dfcba Mon Sep 17 00:00:00 2001 From: Tom Callaway Date: Thu, 12 Dec 2019 14:24:05 -0500 Subject: [PATCH 07/12] disable tests on all non-intel arches, fix powerpc64 --- R-3.6.2-ppc64-no-const-long-double.patch | 15 +++++++++++++++ R.spec | 11 ++++++++++- 2 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 R-3.6.2-ppc64-no-const-long-double.patch diff --git a/R-3.6.2-ppc64-no-const-long-double.patch b/R-3.6.2-ppc64-no-const-long-double.patch new file mode 100644 index 0000000..d1427a3 --- /dev/null +++ b/R-3.6.2-ppc64-no-const-long-double.patch @@ -0,0 +1,15 @@ +diff -up ./src/main/arithmetic.c.orig ./src/main/arithmetic.c +--- ./src/main/arithmetic.c.orig 2019-12-12 18:30:12.416334062 +0000 ++++ ./src/main/arithmetic.c 2019-12-12 18:30:44.966334062 +0000 +@@ -179,7 +179,10 @@ void attribute_hidden InitArithmetic() + #endif + } + +-#if HAVE_LONG_DOUBLE && (SIZEOF_LONG_DOUBLE > SIZEOF_DOUBLE) ++/* PowerPC 64 (when gcc has -mlong-double-128) breaks here because ++ * of issues constant folding 128bit IBM long doubles. ++ */ ++#if HAVE_LONG_DOUBLE && (SIZEOF_LONG_DOUBLE > SIZEOF_DOUBLE) && !__PPC64__ + static LDOUBLE q_1_eps = 1 / LDBL_EPSILON; + #else + static double q_1_eps = 1 / DBL_EPSILON; diff --git a/R.spec b/R.spec index 76b4fae..058d56f 100644 --- a/R.spec +++ b/R.spec @@ -178,6 +178,11 @@ BuildRequires: stunnel %endif # see https://bugzilla.redhat.com/show_bug.cgi?id=1324145 Patch1: R-3.3.0-fix-java_path-in-javareconf.patch +# PowerPC64 when gcc is compiled with -mlong-double-128 +# cannot assign values to const long double vars +# because "the middle-end does not constant fold 128bit IBM long double" +# http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26374 +Patch2: R-3.6.2-ppc64-no-const-long-double.patch License: GPLv2+ BuildRequires: gcc-gfortran BuildRequires: gcc-c++, tex(latex), texinfo-tex @@ -495,6 +500,7 @@ from the R project. This package provides the static libRmath library. %setup -q -n %{name}-%{version} %endif %patch1 -p1 -b .fixpath +%patch2 -p1 -b .ppc64 # Filter false positive provides. cat < %{name}-prov @@ -787,11 +793,12 @@ sed -i 's|/builddir/build/BUILD/R-%{version}/curl-%{curlv}/target%{_libdir}/:/bu mv %{buildroot}%{_libdir}/R/lib/libRblas.so %{buildroot}%{_libdir}/R/lib/libRrefblas.so %endif +# okay, look. its very clear that upstream does not run the test suite on any non-intel architectures. %check %if 0%{?zlibhack} # Most of these tests pass. Some don't. All pieces belong to you. %else -%ifnarch ppc64 ppc64le armv7hl +%ifnarch ppc64 ppc64le armv7hl s390x aarch64 # Needed by tests/ok-error.R, which will smash the stack on PPC64. This is the purpose of the test. ulimit -s 16384 TZ="Europe/Paris" make check @@ -1216,6 +1223,8 @@ R CMD javareconf \ %changelog * Thu Dec 12 2019 Tom Callaway - 3.6.2-1 - update to 3.6.2 +- disable tests on all non-intel arches +- fix powerpc64 * Fri Nov 01 2019 Pete Walter - 3.6.1-3 - Rebuild for ICU 65 From 0468c23822821d4944ff03360ae3f3367463cb8b Mon Sep 17 00:00:00 2001 From: Tom Callaway Date: Wed, 18 Dec 2019 09:08:17 -0500 Subject: [PATCH 08/12] adjust ppc64 patch to reflect upstream fix --- R-3.6.2-ppc64-no-const-long-double.patch | 21 +++++++++++---------- R.spec | 5 ++++- 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/R-3.6.2-ppc64-no-const-long-double.patch b/R-3.6.2-ppc64-no-const-long-double.patch index d1427a3..34948fd 100644 --- a/R-3.6.2-ppc64-no-const-long-double.patch +++ b/R-3.6.2-ppc64-no-const-long-double.patch @@ -1,15 +1,16 @@ -diff -up ./src/main/arithmetic.c.orig ./src/main/arithmetic.c ---- ./src/main/arithmetic.c.orig 2019-12-12 18:30:12.416334062 +0000 -+++ ./src/main/arithmetic.c 2019-12-12 18:30:44.966334062 +0000 -@@ -179,7 +179,10 @@ void attribute_hidden InitArithmetic() - #endif +diff -up R-3.6.2/src/main/arithmetic.c.ppc64 R-3.6.2/src/main/arithmetic.c +--- R-3.6.2/src/main/arithmetic.c.ppc64 2019-10-18 18:15:02.000000000 -0400 ++++ R-3.6.2/src/main/arithmetic.c 2019-12-18 09:05:50.363220122 -0500 +@@ -177,7 +177,12 @@ void attribute_hidden InitArithmetic() } --#if HAVE_LONG_DOUBLE && (SIZEOF_LONG_DOUBLE > SIZEOF_DOUBLE) -+/* PowerPC 64 (when gcc has -mlong-double-128) breaks here because -+ * of issues constant folding 128bit IBM long doubles. -+ */ -+#if HAVE_LONG_DOUBLE && (SIZEOF_LONG_DOUBLE > SIZEOF_DOUBLE) && !__PPC64__ + #if HAVE_LONG_DOUBLE && (SIZEOF_LONG_DOUBLE > SIZEOF_DOUBLE) ++# ifdef __PPC64__ ++ // PowerPC 64 (when gcc has -mlong-double-128) fails constant folding with LDOUBLE ++# define q_1_eps (1 / LDBL_EPSILON) ++# else static LDOUBLE q_1_eps = 1 / LDBL_EPSILON; ++# endif #else static double q_1_eps = 1 / DBL_EPSILON; + #endif diff --git a/R.spec b/R.spec index 058d56f..013e467 100644 --- a/R.spec +++ b/R.spec @@ -130,7 +130,7 @@ Name: R Version: 3.6.2 -Release: 1%{?dist} +Release: 2%{?dist} Summary: A language for data analysis and graphics URL: http://www.r-project.org Source0: https://cran.r-project.org/src/base/R-3/R-%{version}.tar.gz @@ -1221,6 +1221,9 @@ R CMD javareconf \ %{_libdir}/libRmath.a %changelog +* Wed Dec 18 2019 Tom Callaway - 3.6.2-2 +- adjust ppc64 patch to reflect upstream fix + * Thu Dec 12 2019 Tom Callaway - 3.6.2-1 - update to 3.6.2 - disable tests on all non-intel arches From a1d6c05f34eaf3912f058662ec444c36ef9a3c52 Mon Sep 17 00:00:00 2001 From: Fedora Release Engineering Date: Tue, 28 Jan 2020 09:43:55 +0000 Subject: [PATCH 09/12] - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild Signed-off-by: Fedora Release Engineering --- R.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/R.spec b/R.spec index 013e467..697ec8c 100644 --- a/R.spec +++ b/R.spec @@ -130,7 +130,7 @@ Name: R Version: 3.6.2 -Release: 2%{?dist} +Release: 3%{?dist} Summary: A language for data analysis and graphics URL: http://www.r-project.org Source0: https://cran.r-project.org/src/base/R-3/R-%{version}.tar.gz @@ -1221,6 +1221,9 @@ R CMD javareconf \ %{_libdir}/libRmath.a %changelog +* Tue Jan 28 2020 Fedora Release Engineering - 3.6.2-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild + * Wed Dec 18 2019 Tom Callaway - 3.6.2-2 - adjust ppc64 patch to reflect upstream fix From 901e9504654846b713e48d674db865d27d51d837 Mon Sep 17 00:00:00 2001 From: Tom Callaway Date: Tue, 18 Feb 2020 13:24:21 -0500 Subject: [PATCH 10/12] use openblas for lapack/blas, whereever possible (all fedora, el8) --- R.spec | 79 +++++++++++++++++++++++++++++++++++----------------------- 1 file changed, 48 insertions(+), 31 deletions(-) diff --git a/R.spec b/R.spec index 697ec8c..92de22e 100644 --- a/R.spec +++ b/R.spec @@ -3,6 +3,31 @@ %global runjavareconf 1 +# lapack comes from openblas, whenever possible. +%if 0%{?fedora} +%global syslapack 1 +%else +%if 0%{?rhel} && 0%{?rhel} >= 8 +%global syslapack 1 +%else +%global syslapack 0 +%endif +%endif + +%ifarch x86_64 %{ix86} armv7hl %{power64} aarch64 +%if 0%{?rhel} >= 7 +%global openblas 1 +%else +%if 0%{?fedora} >= 23 +%global openblas 1 +%else +%global openblas 0 +%endif +%endif +%else +%global openblas 0 +%endif + %if 0%{?fedora} >= 31 %global usemacros 1 %else @@ -114,23 +139,9 @@ %global texi2any 1 %endif -%ifarch x86_64 %{ix86} armv7hl %{power64} aarch64 -%if 0%{?rhel} >= 7 -%global openblas 1 -%else -%if 0%{?fedora} >= 23 -%global openblas 1 -%else -%global openblas 0 -%endif -%endif -%else -%global openblas 0 -%endif - Name: R Version: 3.6.2 -Release: 3%{?dist} +Release: 4%{?dist} Summary: A language for data analysis and graphics URL: http://www.r-project.org Source0: https://cran.r-project.org/src/base/R-3/R-%{version}.tar.gz @@ -223,19 +234,10 @@ BuildRequires: autoconf, automake, libtool BuildRequires: openblas-devel %endif -# We use the bundled lapack and shim for BLAS now. -%if 0 -%if 0%{?fedora} >= 21 +%if %{syslapack} +%if !%{openblas} BuildRequires: lapack-devel >= 3.5.0-7 BuildRequires: blas-devel >= 3.5.0-7 -%else -%if 0%{?fedora} >= 19 -BuildRequires: lapack-devel >= 3.4.2-7 -BuildRequires: blas-devel >= 3.4.2-7 -%else -BuildRequires: lapack-devel -BuildRequires: blas-devel >= 3.0 -%endif %endif %endif @@ -301,9 +303,11 @@ Requires: sed, gawk, tex(latex), less, make, unzip # Make sure we bring the new libRmath with us Requires: libRmath%{?_isa} = %{version}-%{release} +%if !%{syslapack} %if %{openblas} Requires: openblas-Rblas %endif +%endif %if %{use_devtoolset} # We need it for CXX11 and higher support. @@ -379,8 +383,11 @@ Requires: pcre-devel # Configure picks this up, but despite linking to it, it does not seem to be used as of R 3.5.2. Requires: pcre2-devel %endif -# No longer true. -# Requires: blas-devel >= 3.0, lapack-devel +%if %{syslapack} +%if %{openblas} +Requires: openblas-devel +%endif +%endif %if %{modern} Requires: libicu-devel %endif @@ -632,7 +639,7 @@ export FFLAGS="%{optflags} --no-optimize-sibling-calls" # https://bugzilla.redhat.com/show_bug.cgi?id=1117496 # https://bugzilla.redhat.com/show_bug.cgi?id=1117497 # -# We use --enable-BLAS-shlib here. It generates a shared library +# On old RHEL, we use --enable-BLAS-shlib here. It generates a shared library # of the R bundled blas, that can be replaced by an optimized version. # It also results in R using the bundled lapack copy. @@ -644,14 +651,17 @@ export FFLAGS="%{optflags} --no-optimize-sibling-calls" --with-system-tre \ %endif --with-system-valgrind-headers \ -%if 0%{?fedora} +%if %{syslapack} --with-lapack \ + --with-blas \ +%else + --enable-BLAS-shlib \ %endif --with-tcl-config=%{_libdir}/tclConfig.sh \ --with-tk-config=%{_libdir}/tkConfig.sh \ - --enable-BLAS-shlib \ --enable-R-shlib \ --enable-prebuilt-html \ + --enable-R-profiling \ --enable-memory-profiling \ %if %{with_lto} %ifnarch %{arm} @@ -788,10 +798,12 @@ sed -i 's|:/builddir/build/BUILD/R-%{version}/curl-%{curlv}/target%{_libdir}/:/b sed -i 's|/builddir/build/BUILD/R-%{version}/curl-%{curlv}/target%{_libdir}/:/builddir/build/BUILD/R-%{version}/curl-%{curlv}/target%{_libdir}||g' %{buildroot}%{_libdir}/R/etc/ldpaths %endif +%if !%{syslapack} %if %{openblas} # Rename the R blas so. mv %{buildroot}%{_libdir}/R/lib/libRblas.so %{buildroot}%{_libdir}/R/lib/libRrefblas.so %endif +%endif # okay, look. its very clear that upstream does not run the test suite on any non-intel architectures. %check @@ -1221,6 +1233,11 @@ R CMD javareconf \ %{_libdir}/libRmath.a %changelog +* Tue Feb 18 2020 Tom Callaway - 3.6.2-4 +- fix conditionals so that Fedora builds against system openblas for lapack/blas + and we only generate the R lapack/blas libs on RHEL 5-6-7 (where system lapack/openblas + is not reliable). Thanks to Dirk Eddelbuettel for pointing out the error. + * Tue Jan 28 2020 Fedora Release Engineering - 3.6.2-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild From 2d600e0a99a6db2e8c2ec1cbd0431c117d2c8581 Mon Sep 17 00:00:00 2001 From: Tom Callaway Date: Tue, 18 Feb 2020 17:10:52 -0500 Subject: [PATCH 11/12] fix openblas conditionals, openblas has wider arch support everywhere except el7 --- R.spec | 31 +++++++++++++++++++------------ 1 file changed, 19 insertions(+), 12 deletions(-) diff --git a/R.spec b/R.spec index 92de22e..d35655e 100644 --- a/R.spec +++ b/R.spec @@ -14,18 +14,22 @@ %endif %endif -%ifarch x86_64 %{ix86} armv7hl %{power64} aarch64 -%if 0%{?rhel} >= 7 -%global openblas 1 +%if 0%{?rhel} >= 8 + %global openblas 1 %else -%if 0%{?fedora} >= 23 -%global openblas 1 -%else -%global openblas 0 -%endif -%endif -%else -%global openblas 0 + %if 0%{?rhel} == 7 + %ifarch x86_64 %{ix86} armv7hl %{power64} aarch64 + %global openblas 1 + %else + %global openblas 0 + %endif + %else + %if 0%{?fedora} + %global openblas 1 + %else + %global openblas 0 + %endif + %endif %endif %if 0%{?fedora} >= 31 @@ -141,7 +145,7 @@ Name: R Version: 3.6.2 -Release: 4%{?dist} +Release: 5%{?dist} Summary: A language for data analysis and graphics URL: http://www.r-project.org Source0: https://cran.r-project.org/src/base/R-3/R-%{version}.tar.gz @@ -1233,6 +1237,9 @@ R CMD javareconf \ %{_libdir}/libRmath.a %changelog +* Tue Feb 18 2020 Tom Callaway - 3.6.2-5 +- fix openblas conditionals, openblas has wider arch support everywhere except el7 + * Tue Feb 18 2020 Tom Callaway - 3.6.2-4 - fix conditionals so that Fedora builds against system openblas for lapack/blas and we only generate the R lapack/blas libs on RHEL 5-6-7 (where system lapack/openblas From 0a70cd5f996a5ccfc77558f0e6ed6937a3aacdac Mon Sep 17 00:00:00 2001 From: Tom Callaway Date: Mon, 2 Mar 2020 09:39:30 -0500 Subject: [PATCH 12/12] 3.6.3, conditionalize lapack changes from previous commits to Fedora 32+ and EPEL-8 --- .gitignore | 1 + R.spec | 27 ++++++++++++++------------- sources | 2 +- 3 files changed, 16 insertions(+), 14 deletions(-) diff --git a/.gitignore b/.gitignore index 4f2a9ae..ac2ad8b 100644 --- a/.gitignore +++ b/.gitignore @@ -33,3 +33,4 @@ /bzip2-1.0.8.tar.gz /pcre-8.43.tar.bz2 /curl-7.67.0.tar.bz2 +/R-3.6.3.tar.gz diff --git a/R.spec b/R.spec index d35655e..46c1e65 100644 --- a/R.spec +++ b/R.spec @@ -4,7 +4,10 @@ %global runjavareconf 1 # lapack comes from openblas, whenever possible. -%if 0%{?fedora} +# We decided to implement this change in Fedora 32+ and EPEL-8 only. +# This was to minimize the impact on end-users who might have R modules +# installed locally with the old dependency on libRlapack.so +%if 0%{?fedora} >= 32 %global syslapack 1 %else %if 0%{?rhel} && 0%{?rhel} >= 8 @@ -144,8 +147,8 @@ %endif Name: R -Version: 3.6.2 -Release: 5%{?dist} +Version: 3.6.3 +Release: 1%{?dist} Summary: A language for data analysis and graphics URL: http://www.r-project.org Source0: https://cran.r-project.org/src/base/R-3/R-%{version}.tar.gz @@ -193,11 +196,6 @@ BuildRequires: stunnel %endif # see https://bugzilla.redhat.com/show_bug.cgi?id=1324145 Patch1: R-3.3.0-fix-java_path-in-javareconf.patch -# PowerPC64 when gcc is compiled with -mlong-double-128 -# cannot assign values to const long double vars -# because "the middle-end does not constant fold 128bit IBM long double" -# http://gcc.gnu.org/bugzilla/show_bug.cgi?id=26374 -Patch2: R-3.6.2-ppc64-no-const-long-double.patch License: GPLv2+ BuildRequires: gcc-gfortran BuildRequires: gcc-c++, tex(latex), texinfo-tex @@ -329,24 +327,24 @@ Requires: devtoolset-%{dts_version}-toolchain print("Provides: R(" .. name .. ") = " .. version) } %add_submodule base %{version} -%add_submodule boot 1.3-23 +%add_submodule boot 1.3-24 %add_submodule class 7.3-15 %add_submodule cluster 2.1.0 %add_submodule codetools 0.2-16 %add_submodule compiler %{version} %add_submodule datasets %{version} -%add_submodule foreign 0.8-72 +%add_submodule foreign 0.8-75 %add_submodule graphics %{version} %add_submodule grDevices %{version} %add_submodule grid %{version} %add_submodule KernSmooth 2.23-16 %add_submodule lattice 0.20-38 -%add_submodule MASS 7.3-51.4 +%add_submodule MASS 7.3-51.5 %add_submodule Matrix 1.2-18 Obsoletes: R-Matrix < 0.999375-7 %add_submodule methods %{version} %add_submodule mgcv 1.8-31 -%add_submodule nlme 3.1-142 +%add_submodule nlme 3.1-144 %add_submodule nnet 7.3-12 %add_submodule parallel %{version} %add_submodule rpart 4.1-15 @@ -511,7 +509,6 @@ from the R project. This package provides the static libRmath library. %setup -q -n %{name}-%{version} %endif %patch1 -p1 -b .fixpath -%patch2 -p1 -b .ppc64 # Filter false positive provides. cat < %{name}-prov @@ -1237,6 +1234,10 @@ R CMD javareconf \ %{_libdir}/libRmath.a %changelog +* Mon Mar 2 2020 Tom Callaway - 3.6.3-1 +- update to 3.6.3 +- conditionalize lapack changes from previous commits to Fedora 32+ and EPEL-8 + * Tue Feb 18 2020 Tom Callaway - 3.6.2-5 - fix openblas conditionals, openblas has wider arch support everywhere except el7 diff --git a/sources b/sources index 189a1c3..5509318 100644 --- a/sources +++ b/sources @@ -1,6 +1,6 @@ SHA512 (zlib-1.2.11.tar.gz) = 73fd3fff4adeccd4894084c15ddac89890cd10ef105dd5e1835e1e9bbb6a49ff229713bd197d203edfa17c2727700fce65a2a235f07568212d820dca88b528ae SHA512 (xz-5.2.4.tar.bz2) = 25a548c34a304ba51cdaa63813df0fa4ac2f3cf0ec6dc2d181ec5b62fe586090cd0f1c866ee7ba19e9b264ecabf9ca9f2f1dda7f95313546da4152f3cfaa7e6e -SHA512 (R-3.6.2.tar.gz) = 17513e9f4dd27c61c11f7aa45227aeeeefb375bf5d4e193b471724f379a1b2da33e127cbe91aa175cbbbb048b892047e2f610280585c8159242a6c94790b07f9 SHA512 (bzip2-1.0.8.tar.gz) = 083f5e675d73f3233c7930ebe20425a533feedeaaa9d8cc86831312a6581cefbe6ed0d08d2fa89be81082f2a5abdabca8b3c080bf97218a1bd59dc118a30b9f3 SHA512 (pcre-8.43.tar.bz2) = 3b4ac2c7ccd77c9575d07a33c3456f40b50731029e62d01fb8f2f5871d7118e12bc9e6bc7a8079769c765e38da5ecf98c4b261b10ff0a2f14f0881b434f67af7 SHA512 (curl-7.67.0.tar.bz2) = 096e12be86bca1c19ba9e1d98b8342ec0d76b2e00cab322a7109d1e3559343ff7702b993c772f221fa073d2b8b6ffe6535d15411819fb245d3fa2c18e110b0a5 +SHA512 (R-3.6.3.tar.gz) = 9b1dc78922e431bd1af81e6e560b10ad04d121718f680fed32db735d561fd40ea6028759976722db11559f1a78fe684119b766f0567128cb2ee5003aa87a0931