aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJakub Jirutka <jakub@jirutka.cz>2017-12-25 20:06:19 +0100
committerJakub Jirutka <jakub@jirutka.cz>2017-12-26 18:41:51 +0100
commit4e0bfb790b32f30ed766378e6f538376b8be16f1 (patch)
tree10ce03a68ba4a26dbad8475d041d939acfdd07a7
parentda51282df4136ec8d019d46a05f09edd97633483 (diff)
downloadaports-4e0bfb790b32f30ed766378e6f538376b8be16f1.tar.bz2
aports-4e0bfb790b32f30ed766378e6f538376b8be16f1.tar.xz
main/ruby: upgrade to 2.5.0
-rw-r--r--main/ruby/APKBUILD15
-rw-r--r--main/ruby/test_insns-lower-recursion-depth.patch47
2 files changed, 54 insertions, 8 deletions
diff --git a/main/ruby/APKBUILD b/main/ruby/APKBUILD
index 383548b958..3bd4a668fc 100644
--- a/main/ruby/APKBUILD
+++ b/main/ruby/APKBUILD
@@ -16,7 +16,7 @@
# - CVE-2017-17405
#
pkgname=ruby
-pkgver=2.4.3
+pkgver=2.5.0
_abiver="${pkgver%.*}.0"
pkgrel=0
pkgdesc="An object-oriented language for quick and easy programming"
@@ -43,8 +43,8 @@ subpackages="$pkgname-doc $pkgname-dev
$pkgname-libs
"
source="ftp://ftp.ruby-lang.org/pub/ruby/${pkgver%.*}/$pkgname-$pkgver.tar.bz2
- rubygems-avoid-platform-specific-gems.patch"
-options="!fhs"
+ rubygems-avoid-platform-specific-gems.patch
+ test_insns-lower-recursion-depth.patch"
replaces="ruby-gems"
builddir="$srcdir/$pkgname-$pkgver"
@@ -111,9 +111,6 @@ package() {
rm -R "$pkgdir"$_gemdir/cache/*
- # Remove bundled CA certificates.
- rm -R "$pkgdir"$_rubydir/rubygems/ssl_certs/*.pem || true
-
if [ -d "$pkgdir"/usr/local ]; then
local f=$(cd "$pkgdir" ; find usr/local -type f)
if [ -n "$f" ]; then
@@ -121,6 +118,7 @@ package() {
echo "$f"
return 1
fi
+ rm -r "$pkgdir"/usr/local
fi
}
@@ -243,5 +241,6 @@ _mvgem() {
done
}
-sha512sums="fb4339e30c04d03b1422b6c32ede45902e072cd26325b36f3fc05c341d42eea6431d88718242dcc9ce24d9cad26f3d26772f2e806bd7d93f40be50268c318409 ruby-2.4.3.tar.bz2
-cfdc5ea3b2e2ea69c51f38e8e2180cb1dc27008ca55cc6301f142ebafdbab31c3379b3b6bba9ff543153876dd98ed2ad194df3255b7ea77a62e931c935f80538 rubygems-avoid-platform-specific-gems.patch"
+sha512sums="8f6fdf6708e7470f55bc009db2567cd8d4e633ad0678d83a015441ecf5b5d88bd7da8fb8533a42157ff83b74d00b6dc617d39bbb17fc2c6c12287a1d8eaa0f2c ruby-2.5.0.tar.bz2
+cfdc5ea3b2e2ea69c51f38e8e2180cb1dc27008ca55cc6301f142ebafdbab31c3379b3b6bba9ff543153876dd98ed2ad194df3255b7ea77a62e931c935f80538 rubygems-avoid-platform-specific-gems.patch
+321b45b8af18c7654250cfc96e503ca2d1e7df87430e4509df82f4c6fe3d41e2d5a06e7fb6e04243161212dccb66a85857acf24e86a0fdb0f8c57f778b8ee8ee test_insns-lower-recursion-depth.patch"
diff --git a/main/ruby/test_insns-lower-recursion-depth.patch b/main/ruby/test_insns-lower-recursion-depth.patch
new file mode 100644
index 0000000000..77d827997b
--- /dev/null
+++ b/main/ruby/test_insns-lower-recursion-depth.patch
@@ -0,0 +1,47 @@
+The patched test is a recursion function. We have lower stack size,
+so we hit SystemStackError sooner than on other platforms.
+
+ #361 test_insns.rb:389:in `block in <top (required)>':
+ # recursive once
+ def once n
+ return %r/#{
+ if n == 0
+ true
+ else
+ once(n-1) # here
+ end
+ }/ox
+ end
+ x = once(128); x = once(7); x = once(16);
+ x =~ "true" && $~
+ #=> "" (expected "true") once
+ Stderr output is not empty
+ bootstraptest.tmp.rb:3:in `once': stack level too deep (SystemStackError)
+ from bootstraptest.tmp.rb:7:in `block in once'
+ from bootstraptest.tmp.rb:3:in `once'
+ from bootstraptest.tmp.rb:7:in `block in once'
+ from bootstraptest.tmp.rb:3:in `once'
+ from bootstraptest.tmp.rb:7:in `block in once'
+ from bootstraptest.tmp.rb:3:in `once'
+ from bootstraptest.tmp.rb:7:in `block in once'
+ from bootstraptest.tmp.rb:3:in `once'
+ ... 125 levels...
+ from bootstraptest.tmp.rb:3:in `once'
+ from bootstraptest.tmp.rb:7:in `block in once'
+ from bootstraptest.tmp.rb:3:in `once'
+ from bootstraptest.tmp.rb:11:in `<main>'
+ Test_insns.rb FAIL 1/187
+ FAIL 1/1197 tests failed
+ Make: *** [uncommon.mk:666: yes-btest-ruby] Error 1
+
+--- a/bootstraptest/test_insns.rb
++++ b/bootstraptest/test_insns.rb
+@@ -248,7 +248,7 @@
+ end
+ }/ox
+ end
+- x = once(128); x = once(7); x = once(16);
++ x = once(64); x = once(7); x = once(16);
+ x =~ "true" && $~
+ },
+ [ 'once', <<~'},', ], # {