From patchwork Thu Oct 1 00:46:02 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Waldemar Brodkorb X-Patchwork-Id: 1374779 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=busybox.net (client-ip=140.211.166.136; helo=silver.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=openadk.org Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4C1vZX6K2dz9sTs for ; Thu, 1 Oct 2020 10:46:23 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 08CBC228E7; Thu, 1 Oct 2020 00:46:18 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id bVuV1Eke1mkm; Thu, 1 Oct 2020 00:46:11 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by silver.osuosl.org (Postfix) with ESMTP id EF3CA228DF; Thu, 1 Oct 2020 00:46:10 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 0D8EB1BF9B4 for ; Thu, 1 Oct 2020 00:46:09 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 07746868E9 for ; Thu, 1 Oct 2020 00:46:09 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id QXjgPO4D0lVs for ; Thu, 1 Oct 2020 00:46:06 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from helium.openadk.org (helium.openadk.org [89.238.66.15]) by whitealder.osuosl.org (Postfix) with ESMTPS id 75585868C0 for ; Thu, 1 Oct 2020 00:46:06 +0000 (UTC) Received: by helium.openadk.org (Postfix, from userid 1000) id DBF53100F0; Thu, 1 Oct 2020 02:46:02 +0200 (CEST) Date: Thu, 1 Oct 2020 02:46:02 +0200 From: Waldemar Brodkorb To: buildroot@buildroot.net Message-ID: <20201001004602.pfh6b7jfoj7v4eji@waldemar-brodkorb.de> MIME-Version: 1.0 Content-Disposition: inline X-Operating-System: Linux 4.9.0-11-amd64 x86_64 User-Agent: NeoMutt/20170113 (1.7.2) Subject: [Buildroot] [PATCH v2] ruby: update to 2.7.1 X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" - add patch to recognize coroutines correctly - remove unneeded verconf.h remove hack Signed-off-by: Waldemar Brodkorb --- v1->v2: - fix build for SuperH/uClibc - remove unneeded verconf.h hack --- .../0001-fix-default-coroutine-selection.patch | 35 ++++++++++++++++++++++ package/ruby/ruby.hash | 4 +-- package/ruby/ruby.mk | 14 +++------ 3 files changed, 41 insertions(+), 12 deletions(-) create mode 100644 package/ruby/0001-fix-default-coroutine-selection.patch diff --git a/package/ruby/0001-fix-default-coroutine-selection.patch b/package/ruby/0001-fix-default-coroutine-selection.patch new file mode 100644 index 0000000000..79dbd692e5 --- /dev/null +++ b/package/ruby/0001-fix-default-coroutine-selection.patch @@ -0,0 +1,35 @@ +fixed default coroutine selection for musl/uclibc + +https://github.com/ruby/ruby/pull/3567/commits/b570e7de87aaad8c903176d835e8124127f627b3 + +Signed-off-by: Waldemar Brodkorb + +diff -Nur ruby-2.7.1.orig/configure.ac ruby-2.7.1/configure.ac +--- ruby-2.7.1.orig/configure.ac 2020-03-31 12:44:55.000000000 +0200 ++++ ruby-2.7.1/configure.ac 2020-10-01 00:03:53.130462286 +0200 +@@ -2344,8 +2344,12 @@ + rb_cv_coroutine=copy + ], + [*], [ +- rb_cv_coroutine=ucontext ++ AC_CHECK_FUNCS([getcontext swapcontext makecontext], ++ [rb_cv_coroutine=ucontext], ++ [rb_cv_coroutine=copy; break] ++ ) + ] ++ + ) + AC_MSG_RESULT(${rb_cv_coroutine}) + ]) +diff -Nur ruby-2.7.1.orig/coroutine/copy/Context.c ruby-2.7.1/coroutine/copy/Context.c +--- ruby-2.7.1.orig/coroutine/copy/Context.c 2020-03-31 12:44:55.000000000 +0200 ++++ ruby-2.7.1/coroutine/copy/Context.c 2020-10-01 00:04:59.414670705 +0200 +@@ -5,6 +5,8 @@ + * Copyright, 2019, by Samuel Williams. All rights reserved. + */ + ++#include ++ + #include "Context.h" + + // http://gcc.gnu.org/onlinedocs/gcc/Alternate-Keywords.html diff --git a/package/ruby/ruby.hash b/package/ruby/ruby.hash index 89cab3fcd3..e9f53879b1 100644 --- a/package/ruby/ruby.hash +++ b/package/ruby/ruby.hash @@ -1,5 +1,5 @@ -# https://www.ruby-lang.org/en/news/2020/03/31/ruby-2-4-10-released/ -sha256 d5668ed11544db034f70aec37d11e157538d639ed0d0a968e2f587191fc530df ruby-2.4.10.tar.xz +# Locally calculated +sha256 b224f9844646cc92765df8288a46838511c1cec5b550d8874bd4686a904fcee7 ruby-2.7.1.tar.xz # License files, Locally calculated sha256 609292a6d848ab223073944fc2d844449391a5ba2055a8b5baf1726bc13b39cb LEGAL sha256 f5eb1b2956d5f7a67b2e5722a3749bc2fe86f9c580f2e3f5a08519cf073b5864 COPYING diff --git a/package/ruby/ruby.mk b/package/ruby/ruby.mk index d138aaaa1a..d289fb937c 100644 --- a/package/ruby/ruby.mk +++ b/package/ruby/ruby.mk @@ -4,9 +4,9 @@ # ################################################################################ -RUBY_VERSION_MAJOR = 2.4 -RUBY_VERSION = $(RUBY_VERSION_MAJOR).10 -RUBY_VERSION_EXT = 2.4.0 +RUBY_VERSION_MAJOR = 2.7 +RUBY_VERSION = $(RUBY_VERSION_MAJOR).1 +RUBY_VERSION_EXT = 2.7.0 RUBY_SITE = http://cache.ruby-lang.org/pub/ruby/$(RUBY_VERSION_MAJOR) RUBY_SOURCE = ruby-$(RUBY_VERSION).tar.xz RUBY_DEPENDENCIES = host-pkgconf host-ruby @@ -19,6 +19,7 @@ HOST_RUBY_CONF_OPTS = \ --without-gmp RUBY_LICENSE = Ruby or BSD-2-Clause, BSD-3-Clause, others RUBY_LICENSE_FILES = LEGAL COPYING BSDL +RUBY_AUTORECONF = YES ifeq ($(BR2_TOOLCHAIN_USES_UCLIBC),y) # On uClibc, finite, isinf and isnan are not directly implemented as @@ -70,13 +71,6 @@ else RUBY_CONF_OPTS += --without-gmp endif -# workaround for amazing build failure, see -# http://lists.busybox.net/pipermail/buildroot/2014-December/114273.html -define RUBY_REMOVE_VERCONF_H - rm -f $(@D)/verconf.h -endef -RUBY_POST_CONFIGURE_HOOKS += RUBY_REMOVE_VERCONF_H - # Remove rubygems and friends, as they need extensions that aren't # built and a target compiler. RUBY_EXTENSIONS_REMOVE = rake* rdoc* rubygems*