commit:     5b04d980d5a85f22049123fe1b4f0f0098db24f1
Author:     Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
AuthorDate: Mon Sep 21 11:03:59 2020 +0000
Commit:     Thomas Deutschmann <whissi <AT> gentoo <DOT> org>
CommitDate: Mon Sep 21 11:03:59 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=5b04d980

dev-lang/spidermonkey: restore missing patches for 52.x

Fixes: 5c80805 ("dev-lang/spidermonkey: drop old")
Closes: https://bugs.gentoo.org/743880
Package-Manager: Portage-3.0.8, Repoman-3.0.1
Signed-off-by: Thomas Deutschmann <whissi <AT> gentoo.org>

 .../files/moz38-dont-hardcode-libc-soname.patch    | 15 ++++++++++
 .../spidermonkey-52.0-fix-alpha-bitness.patch      | 32 ++++++++++++++++++++++
 .../files/spidermonkey-52.0-gcc9-overflow.patch    | 24 ++++++++++++++++
 3 files changed, 71 insertions(+)

diff --git a/dev-lang/spidermonkey/files/moz38-dont-hardcode-libc-soname.patch 
b/dev-lang/spidermonkey/files/moz38-dont-hardcode-libc-soname.patch
new file mode 100644
index 00000000000..708c7496975
--- /dev/null
+++ b/dev-lang/spidermonkey/files/moz38-dont-hardcode-libc-soname.patch
@@ -0,0 +1,15 @@
+--- a/testing/mozbase/mozinfo/mozinfo/mozinfo.py       2018-01-12 
12:21:16.764318254 -0500
++++ b/testing/mozbase/mozinfo/mozinfo/mozinfo.py       2018-01-12 
12:22:23.392069398 -0500
+@@ -93,10 +93,11 @@
+ 
+ if info['os'] == 'linux':
+     import ctypes
++    import ctypes.util
+     import errno
+     PR_SET_SECCOMP = 22
+     SECCOMP_MODE_FILTER = 2
+-    ctypes.CDLL("libc.so.6", use_errno=True).prctl(PR_SET_SECCOMP, 
SECCOMP_MODE_FILTER, 0)
++    ctypes.CDLL(ctypes.util.find_library('c'), 
use_errno=True).prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, 0)
+     info['has_sandbox'] = ctypes.get_errno() == errno.EFAULT
+ else:
+     info['has_sandbox'] = True

diff --git 
a/dev-lang/spidermonkey/files/spidermonkey-52.0-fix-alpha-bitness.patch 
b/dev-lang/spidermonkey/files/spidermonkey-52.0-fix-alpha-bitness.patch
new file mode 100644
index 00000000000..b0f87296438
--- /dev/null
+++ b/dev-lang/spidermonkey/files/spidermonkey-52.0-fix-alpha-bitness.patch
@@ -0,0 +1,32 @@
+
+# HG changeset patch
+# User John Paul Adrian Glaubitz <glaub...@physik.fu-berlin.de>
+# Date 1482966103 -3600
+# Node ID 1f4d99d8dff27bcc25eff21dc6a16dae63f48595
+# Parent  ce9e9f0dc752896ac7ba00bb0610b3f731e948b0
+Bug 1326496 - mozbuild: Fix bitness from 32 to 64 bits on alpha. r=glandium
+
+
+diff --git a/python/mozbuild/mozbuild/configure/constants.py 
b/python/mozbuild/mozbuild/configure/constants.py
+--- a/python/mozbuild/mozbuild/configure/constants.py
++++ b/python/mozbuild/mozbuild/configure/constants.py
+@@ -35,17 +35,17 @@ Kernel = EnumString.subclass(
+     'Linux',
+     'NetBSD',
+     'OpenBSD',
+     'WINNT',
+ )
+ 
+ CPU_bitness = {
+     'aarch64': 64,
+-    'Alpha': 32,
++    'Alpha': 64,
+     'arm': 32,
+     'hppa': 32,
+     'ia64': 64,
+     'mips32': 32,
+     'mips64': 64,
+     'ppc': 32,
+     'ppc64': 64,
+     's390': 32,
+

diff --git a/dev-lang/spidermonkey/files/spidermonkey-52.0-gcc9-overflow.patch 
b/dev-lang/spidermonkey/files/spidermonkey-52.0-gcc9-overflow.patch
new file mode 100644
index 00000000000..c7eb0f62b28
--- /dev/null
+++ b/dev-lang/spidermonkey/files/spidermonkey-52.0-gcc9-overflow.patch
@@ -0,0 +1,24 @@
+From 311fc467219ab6ee9eed60759b58a8066c4bf36d Mon Sep 17 00:00:00 2001
+From: 
+Date: Thu, 25 Jul 2019 10:00:33 -0500
+Subject: [PATCH] gcc-9 overflow fix
+
+---
+ js/src/jsapi-tests/testPrintf.cpp | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/js/src/jsapi-tests/testPrintf.cpp 
b/js/src/jsapi-tests/testPrintf.cpp
+index 51486856..03cc118d 100644
+--- a/js/src/jsapi-tests/testPrintf.cpp
++++ b/js/src/jsapi-tests/testPrintf.cpp
+@@ -55,7 +55,6 @@ BEGIN_TEST(testPrintf)
+     CHECK(print_one("27270", "%zu", (size_t) 27270));
+     CHECK(print_one("27270", "%" PRIuSIZE, (size_t) 27270));
+     CHECK(print_one("hello", "he%so", "ll"));
+-    CHECK(print_one("(null)", "%s", zero()));
+     CHECK(print_one("0", "%p", (char *) 0));
+     CHECK(print_one("h", "%c", 'h'));
+     CHECK(print_one("1.500000", "%f", 1.5f));
+-- 
+2.22.0
+

Reply via email to