diff --git a/R.spec b/R.spec index 20668d3..f58c31f 100644 --- a/R.spec +++ b/R.spec @@ -8,11 +8,12 @@ Name: R Version: %{major_version}.%{minor_version}.%{patch_version} -Release: 1 +Release: 2 Summary: A language for data analysis and graphics License: AGPL-3.0 and Artistic-2.0 and BSD-2-Clause and BSD-3-Clause and GPL-2.0 and GPL-3.0 and LGPL-2.1 and LGPL-3.0 and MIT and CC-BY-SA-4.0 URL: http://www.r-project.org Source0: https://cran.r-project.org/src/base/R-4/R-%{version}.tar.gz +Patch0: allow-libcurl-v8.patch BuildRequires: gcc-gfortran gcc-c++ texinfo-tex libpng-devel libjpeg-devel readline-devel libicu-devel less tcl-devel BuildRequires: ncurses-devel pcre-devel zlib-devel pcre2-devel libcurl-devel valgrind-devel java-openjdk tk-devel @@ -182,7 +183,7 @@ R project. This package provides the static libRmath library. %prep -%setup -q -n %{name}-%{version} +%autosetup -n %{name}-%{version} -p1 # Filter false positive provides. cat < %{name}-prov #!/bin/sh @@ -734,5 +735,8 @@ R CMD javareconf \ %changelog +* Thu Jul 20 2023 wangkai <13474090681@163.com> - 4.0.5-2 +- allow libcurl v8 for fix build error + * Thu Jun 03 2021 He Rengui - 4.0.5-1 - package init diff --git a/allow-libcurl-v8.patch b/allow-libcurl-v8.patch new file mode 100644 index 0000000..3bcb71a --- /dev/null +++ b/allow-libcurl-v8.patch @@ -0,0 +1,60 @@ +From da6638896413bcbb5970b2335b92582853f94e3c Mon Sep 17 00:00:00 2001 +From: ripley +Date: Sat, 25 Mar 2023 09:01:30 +0000 +Subject: [PATCH] allow libcurl 8 as its API/ABI is said to be unchanged + +git-svn-id: https://svn.r-project.org/R/trunk@84049 00db46b3-68df-0310-9c12-caf00c1e9a41 +--- + configure | 6 +++--- + m4/R.m4 | 4 ++-- + 2 files changed, 5 insertions(+), 5 deletions(-) + +diff --git a/configure b/configure +index 68c9df1..f6f4db6 100755 +--- a/configure ++++ b/configure +@@ -46163,8 +46163,8 @@ done + + + if test "x${have_libcurl}" = "xyes"; then +-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if libcurl is version 7 and >= 7.28.0" >&5 +-$as_echo_n "checking if libcurl is version 7 and >= 7.28.0... " >&6; } ++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if libcurl is and >= 7.28.0" >&5 ++$as_echo_n "checking if libcurl is and >= 7.28.0... " >&6; } + if ${r_cv_have_curl728+:} false; then : + $as_echo_n "(cached) " >&6 + else +@@ -46180,7 +46180,7 @@ int main() + { + #ifdef LIBCURL_VERSION_MAJOR + #if LIBCURL_VERSION_MAJOR > 7 +- exit(1); ++ exit(0); + #elif LIBCURL_VERSION_MAJOR == 7 && LIBCURL_VERSION_MINOR >= 28 + exit(0); + #else +diff --git a/m4/R.m4 b/m4/R.m4 +index 03dea8d..7d97a88 100644 +--- a/m4/R.m4 ++++ b/m4/R.m4 +@@ -4267,7 +4267,7 @@ LIBS="${CURL_LIBS} ${LIBS}" + AC_CHECK_HEADERS(curl/curl.h, [have_libcurl=yes], [have_libcurl=no]) + + if test "x${have_libcurl}" = "xyes"; then +-AC_CACHE_CHECK([if libcurl is version 7 and >= 7.28.0], [r_cv_have_curl728], ++AC_CACHE_CHECK([if libcurl is >= 7.28.0], [r_cv_have_curl728], + [AC_RUN_IFELSE([AC_LANG_SOURCE([[ + #include + #include +@@ -4275,7 +4275,7 @@ int main() + { + #ifdef LIBCURL_VERSION_MAJOR + #if LIBCURL_VERSION_MAJOR > 7 +- exit(1); ++ exit(0); + #elif LIBCURL_VERSION_MAJOR == 7 && LIBCURL_VERSION_MINOR >= 28 + exit(0); + #else +-- +2.33.0 +