diff options
author | Hans de Graaff <graaff@gentoo.org> | 2021-01-15 10:09:02 +0100 |
---|---|---|
committer | Hans de Graaff <graaff@gentoo.org> | 2021-01-15 10:10:04 +0100 |
commit | af0c1600e964e55054e7e5f42fb20316a5b0f8be (patch) | |
tree | 66412b31547b66ee1519f9fc3086c0e3492cfbda /dev-lang | |
parent | www-client/vivaldi-snapshot: Drop old 3.5.2131.8-r1 (diff) | |
download | gentoo-af0c1600e964e55054e7e5f42fb20316a5b0f8be.tar.gz gentoo-af0c1600e964e55054e7e5f42fb20316a5b0f8be.tar.bz2 gentoo-af0c1600e964e55054e7e5f42fb20316a5b0f8be.zip |
dev-lang/ruby: make compatible with autoconf 2.70
Closes: https://bugs.gentoo.org/765010
Package-Manager: Portage-3.0.12, Repoman-3.0.2
Signed-off-by: Hans de Graaff <graaff@gentoo.org>
Diffstat (limited to 'dev-lang')
-rw-r--r-- | dev-lang/ruby/files/2.5/002-autoconf-2.70.patch | 65 | ||||
-rw-r--r-- | dev-lang/ruby/files/2.6/002-autoconf-2.70.patch | 65 | ||||
-rw-r--r-- | dev-lang/ruby/files/2.7/002-autoconf-2.70.patch | 26 | ||||
-rw-r--r-- | dev-lang/ruby/ruby-2.5.8-r1.ebuild | 2 | ||||
-rw-r--r-- | dev-lang/ruby/ruby-2.6.6-r2.ebuild | 2 | ||||
-rw-r--r-- | dev-lang/ruby/ruby-2.7.2.ebuild | 2 |
6 files changed, 159 insertions, 3 deletions
diff --git a/dev-lang/ruby/files/2.5/002-autoconf-2.70.patch b/dev-lang/ruby/files/2.5/002-autoconf-2.70.patch new file mode 100644 index 000000000000..576ed6c759bd --- /dev/null +++ b/dev-lang/ruby/files/2.5/002-autoconf-2.70.patch @@ -0,0 +1,65 @@ +From 6160ea5e22ee7353a0814159c94bd3cf890a52ce Mon Sep 17 00:00:00 2001 +From: Sergei Trofimovich <slyfox@gentoo.org> +Date: Mon, 16 Nov 2020 08:42:15 +0000 +Subject: [PATCH] configure.ac: fix for upcoming autoconf-2.70 + +The failure initially noticed on `autoconf-2.69d` (soon to become 2.70): + +``` +$ ./configure +./configure: line 8720: syntax error near unexpected token `fi' +./configure: line 8720: `fi' +``` + +Before the change generated `./configure ` snippet looked like: + +``` + if ! $CC -E -xc - <<SRC >/dev/null +then : + + #if defined __APPLE_CC__ && defined __clang_major__ && __clang_major__ < 3 + #error premature clang + #endif +SRC + as_fn_error $? "clang version 3.0 or later is required" "$LINENO" 5 +fi +``` + +Note the newline that breaks here-document syntax. + +After the change the snippet does not use here-document. + +Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org> +--- + configure.ac | 15 ++++++++------- + 1 file changed, 8 insertions(+), 7 deletions(-) + +diff --git a/configure.ac b/configure.ac +index a5e3dc76f6..4e4a52f066 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -271,13 +271,14 @@ AS_CASE(["$host_os:$build_os"], + # clang version 1.0 (http://llvm.org/svn/llvm-project/cfe/tags/Apple/clang-23 exported) + # Apple clang version 2.0 (tags/Apple/clang-137) (based on LLVM 2.9svn) + # Apple clang version 2.1 (tags/Apple/clang-163.7.1) (based on LLVM 3.0svn) +- AS_IF([! $CC -E -xc - <<SRC >/dev/null], [ +- @%:@if defined __APPLE_CC__ && defined __clang_major__ && __clang_major__ < 3 +- @%:@error premature clang +- @%:@endif +-SRC +- AC_MSG_ERROR([clang version 3.0 or later is required]) +- ]) ++ AC_PREPROC_IFELSE( ++ [AC_LANG_PROGRAM([ ++ @%:@if defined __APPLE_CC__ && defined __clang_major__ && __clang_major__ < 3 ++ @%:@error premature clang ++ @%:@endif ++ ])], ++ [], ++ [AC_MSG_ERROR([clang version 3.0 or later is required])]) + ]) + + AS_CASE(["$target_os"], +-- +2.29.2 + diff --git a/dev-lang/ruby/files/2.6/002-autoconf-2.70.patch b/dev-lang/ruby/files/2.6/002-autoconf-2.70.patch new file mode 100644 index 000000000000..576ed6c759bd --- /dev/null +++ b/dev-lang/ruby/files/2.6/002-autoconf-2.70.patch @@ -0,0 +1,65 @@ +From 6160ea5e22ee7353a0814159c94bd3cf890a52ce Mon Sep 17 00:00:00 2001 +From: Sergei Trofimovich <slyfox@gentoo.org> +Date: Mon, 16 Nov 2020 08:42:15 +0000 +Subject: [PATCH] configure.ac: fix for upcoming autoconf-2.70 + +The failure initially noticed on `autoconf-2.69d` (soon to become 2.70): + +``` +$ ./configure +./configure: line 8720: syntax error near unexpected token `fi' +./configure: line 8720: `fi' +``` + +Before the change generated `./configure ` snippet looked like: + +``` + if ! $CC -E -xc - <<SRC >/dev/null +then : + + #if defined __APPLE_CC__ && defined __clang_major__ && __clang_major__ < 3 + #error premature clang + #endif +SRC + as_fn_error $? "clang version 3.0 or later is required" "$LINENO" 5 +fi +``` + +Note the newline that breaks here-document syntax. + +After the change the snippet does not use here-document. + +Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org> +--- + configure.ac | 15 ++++++++------- + 1 file changed, 8 insertions(+), 7 deletions(-) + +diff --git a/configure.ac b/configure.ac +index a5e3dc76f6..4e4a52f066 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -271,13 +271,14 @@ AS_CASE(["$host_os:$build_os"], + # clang version 1.0 (http://llvm.org/svn/llvm-project/cfe/tags/Apple/clang-23 exported) + # Apple clang version 2.0 (tags/Apple/clang-137) (based on LLVM 2.9svn) + # Apple clang version 2.1 (tags/Apple/clang-163.7.1) (based on LLVM 3.0svn) +- AS_IF([! $CC -E -xc - <<SRC >/dev/null], [ +- @%:@if defined __APPLE_CC__ && defined __clang_major__ && __clang_major__ < 3 +- @%:@error premature clang +- @%:@endif +-SRC +- AC_MSG_ERROR([clang version 3.0 or later is required]) +- ]) ++ AC_PREPROC_IFELSE( ++ [AC_LANG_PROGRAM([ ++ @%:@if defined __APPLE_CC__ && defined __clang_major__ && __clang_major__ < 3 ++ @%:@error premature clang ++ @%:@endif ++ ])], ++ [], ++ [AC_MSG_ERROR([clang version 3.0 or later is required])]) + ]) + + AS_CASE(["$target_os"], +-- +2.29.2 + diff --git a/dev-lang/ruby/files/2.7/002-autoconf-2.70.patch b/dev-lang/ruby/files/2.7/002-autoconf-2.70.patch new file mode 100644 index 000000000000..bea2bc178dc4 --- /dev/null +++ b/dev-lang/ruby/files/2.7/002-autoconf-2.70.patch @@ -0,0 +1,26 @@ +diff --git a/configure.ac b/configure.ac +index 6766df2..bc503d6 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -177,13 +177,14 @@ AS_CASE(["$host_os:$build_os"], + # clang version 1.0 (http://llvm.org/svn/llvm-project/cfe/tags/Apple/clang-23 exported) + # Apple clang version 2.0 (tags/Apple/clang-137) (based on LLVM 2.9svn) + # Apple clang version 2.1 (tags/Apple/clang-163.7.1) (based on LLVM 3.0svn) +- AS_IF([! $CC -E -xc - <<SRC >/dev/null], [ +- @%:@if defined __APPLE_CC__ && defined __clang_major__ && __clang_major__ < 3 +- @%:@error premature clang +- @%:@endif +-SRC +- AC_MSG_ERROR([clang version 3.0 or later is required]) +- ])], ++ AC_PREPROC_IFELSE( ++ [AC_LANG_PROGRAM([ ++ @%:@if defined __APPLE_CC__ && defined __clang_major__ && __clang_major__ < 3 ++ @%:@error premature clang ++ @%:@endif ++ ])], ++ [], ++ [AC_MSG_ERROR([clang version 3.0 or later is required])])], + [openbsd*:openbsd*], [ + AC_CHECK_TOOLS(CC, [cc]) + ]) diff --git a/dev-lang/ruby/ruby-2.5.8-r1.ebuild b/dev-lang/ruby/ruby-2.5.8-r1.ebuild index 21d81b7477bc..1a4584807865 100644 --- a/dev-lang/ruby/ruby-2.5.8-r1.ebuild +++ b/dev-lang/ruby/ruby-2.5.8-r1.ebuild @@ -61,7 +61,7 @@ PDEPEND=" xemacs? ( app-xemacs/ruby-modes )" src_prepare() { - eapply "${FILESDIR}"/${SLOT}/{001,005,011}*.patch + eapply "${FILESDIR}"/${SLOT}/{001,002,005,011}*.patch einfo "Unbundling gems..." cd "$S" diff --git a/dev-lang/ruby/ruby-2.6.6-r2.ebuild b/dev-lang/ruby/ruby-2.6.6-r2.ebuild index ee064ea4a67b..795321234d25 100644 --- a/dev-lang/ruby/ruby-2.6.6-r2.ebuild +++ b/dev-lang/ruby/ruby-2.6.6-r2.ebuild @@ -65,7 +65,7 @@ PDEPEND=" src_prepare() { # 005 does not compile bigdecimal and is questionable because it # compiles ruby in a non-standard way, may be dropped - eapply "${FILESDIR}"/2.6/010*.patch + eapply "${FILESDIR}"/2.6/{002,010}*.patch einfo "Unbundling gems..." cd "$S" diff --git a/dev-lang/ruby/ruby-2.7.2.ebuild b/dev-lang/ruby/ruby-2.7.2.ebuild index 473f807c1923..138024506971 100644 --- a/dev-lang/ruby/ruby-2.7.2.ebuild +++ b/dev-lang/ruby/ruby-2.7.2.ebuild @@ -65,7 +65,7 @@ PDEPEND=" src_prepare() { # 005 does not compile bigdecimal and is questionable because it # compiles ruby in a non-standard way, may be dropped - eapply "${FILESDIR}"/2.7/010*.patch + eapply "${FILESDIR}"/2.7/{002,010}*.patch einfo "Unbundling gems..." cd "$S" |