diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-28 13:16:42 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-28 13:16:42 +0000 |
commit | 073a8e76266c6f87b605b8cb46bfca3109ade460 (patch) | |
tree | f974eea97fec3e7a9d84d674ca1771fa2e2e486e /debian/patches | |
parent | Adding upstream version 1.18.10. (diff) | |
download | golang-1.18-debian.tar.xz golang-1.18-debian.zip |
Adding debian version 1.18.10-1.debian/1.18.10-1debian
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/patches')
5 files changed, 187 insertions, 0 deletions
diff --git a/debian/patches/0001-Disable-test-for-UserHomeDir.patch b/debian/patches/0001-Disable-test-for-UserHomeDir.patch new file mode 100644 index 0000000..29a38b1 --- /dev/null +++ b/debian/patches/0001-Disable-test-for-UserHomeDir.patch @@ -0,0 +1,22 @@ +From: "Dr. Tobias Quathamer" <toddy@debian.org> +Date: Wed, 19 Dec 2018 14:25:06 +0100 +Subject: Disable test for UserHomeDir. + +On Debian buildds, the user home dir does not exist, so this test fails. +--- + src/os/os_test.go | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/src/os/os_test.go b/src/os/os_test.go +index 63427de..1695375 100644 +--- a/src/os/os_test.go ++++ b/src/os/os_test.go +@@ -2534,6 +2534,8 @@ func TestUserHomeDir(t *testing.T) { + if err != nil { + t.Skipf("UserHomeDir failed: %v", err) + } ++ // On Debian buildds, the user home dir does not exist. ++ t.Skip("UserHomeDir does not exist on Debian buildds.") + fi, err := Stat(dir) + if err != nil { + t.Fatal(err) diff --git a/debian/patches/0002-Fix-Lintian-warnings-about-wrong-interpreter-path.patch b/debian/patches/0002-Fix-Lintian-warnings-about-wrong-interpreter-path.patch new file mode 100644 index 0000000..3068cc3 --- /dev/null +++ b/debian/patches/0002-Fix-Lintian-warnings-about-wrong-interpreter-path.patch @@ -0,0 +1,98 @@ +From: "Dr. Tobias Quathamer" <toddy@debian.org> +Date: Thu, 1 Aug 2019 13:50:48 +0200 +Subject: Fix Lintian warnings about wrong interpreter path + +The command used for this change is as follows: + +grep -rH "/usr/bin/env perl" * | cut -d: -f1 | xargs -n1 sed -i -e "s,/usr/bin/env perl,/usr/bin/perl," +--- + src/syscall/mksyscall.pl | 2 +- + src/syscall/mksyscall_libc.pl | 2 +- + src/syscall/mksysctl_openbsd.pl | 2 +- + src/syscall/mksysnum_dragonfly.pl | 2 +- + src/syscall/mksysnum_freebsd.pl | 2 +- + src/syscall/mksysnum_linux.pl | 2 +- + src/syscall/mksysnum_netbsd.pl | 2 +- + src/syscall/mksysnum_openbsd.pl | 2 +- + 8 files changed, 8 insertions(+), 8 deletions(-) + +diff --git a/src/syscall/mksyscall.pl b/src/syscall/mksyscall.pl +index 25ab911..98de8e8 100755 +--- a/src/syscall/mksyscall.pl ++++ b/src/syscall/mksyscall.pl +@@ -1,4 +1,4 @@ +-#!/usr/bin/env perl ++#!/usr/bin/perl + # Copyright 2009 The Go Authors. All rights reserved. + # Use of this source code is governed by a BSD-style + # license that can be found in the LICENSE file. +diff --git a/src/syscall/mksyscall_libc.pl b/src/syscall/mksyscall_libc.pl +index 3731476..47457a1 100755 +--- a/src/syscall/mksyscall_libc.pl ++++ b/src/syscall/mksyscall_libc.pl +@@ -1,4 +1,4 @@ +-#!/usr/bin/env perl ++#!/usr/bin/perl + # Copyright 2009 The Go Authors. All rights reserved. + # Use of this source code is governed by a BSD-style + # license that can be found in the LICENSE file. +diff --git a/src/syscall/mksysctl_openbsd.pl b/src/syscall/mksysctl_openbsd.pl +index ea462a7..7e8a3e2 100755 +--- a/src/syscall/mksysctl_openbsd.pl ++++ b/src/syscall/mksysctl_openbsd.pl +@@ -1,4 +1,4 @@ +-#!/usr/bin/env perl ++#!/usr/bin/perl + + # Copyright 2011 The Go Authors. All rights reserved. + # Use of this source code is governed by a BSD-style +diff --git a/src/syscall/mksysnum_dragonfly.pl b/src/syscall/mksysnum_dragonfly.pl +index e9a634b..a8df18d 100755 +--- a/src/syscall/mksysnum_dragonfly.pl ++++ b/src/syscall/mksysnum_dragonfly.pl +@@ -1,4 +1,4 @@ +-#!/usr/bin/env perl ++#!/usr/bin/perl + # Copyright 2009 The Go Authors. All rights reserved. + # Use of this source code is governed by a BSD-style + # license that can be found in the LICENSE file. +diff --git a/src/syscall/mksysnum_freebsd.pl b/src/syscall/mksysnum_freebsd.pl +index c04ada9..f9b7b91 100755 +--- a/src/syscall/mksysnum_freebsd.pl ++++ b/src/syscall/mksysnum_freebsd.pl +@@ -1,4 +1,4 @@ +-#!/usr/bin/env perl ++#!/usr/bin/perl + # Copyright 2009 The Go Authors. All rights reserved. + # Use of this source code is governed by a BSD-style + # license that can be found in the LICENSE file. +diff --git a/src/syscall/mksysnum_linux.pl b/src/syscall/mksysnum_linux.pl +index 5fb1d0e..ebeb9a8 100755 +--- a/src/syscall/mksysnum_linux.pl ++++ b/src/syscall/mksysnum_linux.pl +@@ -1,4 +1,4 @@ +-#!/usr/bin/env perl ++#!/usr/bin/perl + # Copyright 2009 The Go Authors. All rights reserved. + # Use of this source code is governed by a BSD-style + # license that can be found in the LICENSE file. +diff --git a/src/syscall/mksysnum_netbsd.pl b/src/syscall/mksysnum_netbsd.pl +index 4f5150a..53783ff 100755 +--- a/src/syscall/mksysnum_netbsd.pl ++++ b/src/syscall/mksysnum_netbsd.pl +@@ -1,4 +1,4 @@ +-#!/usr/bin/env perl ++#!/usr/bin/perl + # Copyright 2009 The Go Authors. All rights reserved. + # Use of this source code is governed by a BSD-style + # license that can be found in the LICENSE file. +diff --git a/src/syscall/mksysnum_openbsd.pl b/src/syscall/mksysnum_openbsd.pl +index f8f484b..312486d 100755 +--- a/src/syscall/mksysnum_openbsd.pl ++++ b/src/syscall/mksysnum_openbsd.pl +@@ -1,4 +1,4 @@ +-#!/usr/bin/env perl ++#!/usr/bin/perl + # Copyright 2009 The Go Authors. All rights reserved. + # Use of this source code is governed by a BSD-style + # license that can be found in the LICENSE file. diff --git a/debian/patches/0003-cmd-dist-increase-default-timeout-scale-for-arm.patch b/debian/patches/0003-cmd-dist-increase-default-timeout-scale-for-arm.patch new file mode 100644 index 0000000..7dc8a00 --- /dev/null +++ b/debian/patches/0003-cmd-dist-increase-default-timeout-scale-for-arm.patch @@ -0,0 +1,29 @@ +From: Balint Reczey <balint.reczey@canonical.com> +Date: Mon, 31 Aug 2020 13:14:51 +0200 +Subject: [PATCH] cmd/dist: increase default timeout scale for arm + +Forwarded: https://github.com/golang/go/issues/43002 + +Most developers use (faster) amd64 machines setting the test timeouts, +but test may run on slower arm ones and also different tests may suffer +different relative slowdown on the arm CPUs. + +Due to those two varying factors it is safer to allow a higher timeout +scale on arm to avoid tests timing out. +--- + src/cmd/dist/test.go | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/cmd/dist/test.go b/src/cmd/dist/test.go +index d9eb9c3..c82d746 100644 +--- a/src/cmd/dist/test.go ++++ b/src/cmd/dist/test.go +@@ -173,7 +173,7 @@ func (t *tester) run() { + t.timeoutScale = 1 + switch goarch { + case "arm": +- t.timeoutScale = 2 ++ t.timeoutScale = 3 + case "mips", "mipsle", "mips64", "mips64le": + t.timeoutScale = 4 + } diff --git a/debian/patches/0004-skip-userns-test-in-schroot-as-well.patch b/debian/patches/0004-skip-userns-test-in-schroot-as-well.patch new file mode 100644 index 0000000..1b135d3 --- /dev/null +++ b/debian/patches/0004-skip-userns-test-in-schroot-as-well.patch @@ -0,0 +1,34 @@ +From: Shengjing Zhu <zhsj@debian.org> +Date: Fri, 5 Feb 2021 21:21:45 +0800 +Subject: skip userns test in schroot as well + +When schroot is using overlayfs, it fails to detect it as chroot. +--- + src/syscall/exec_linux_test.go | 7 +++++++ + 1 file changed, 7 insertions(+) + +diff --git a/src/syscall/exec_linux_test.go b/src/syscall/exec_linux_test.go +index 0ec9c4d..cabaaf9 100644 +--- a/src/syscall/exec_linux_test.go ++++ b/src/syscall/exec_linux_test.go +@@ -32,6 +32,10 @@ func isLXC() bool { + return os.Getenv("container") == "lxc" + } + ++func isSchroot() bool { ++ return os.Getenv("SCHROOT_SESSION_ID") != "" ++} ++ + func skipInContainer(t *testing.T) { + // TODO: the callers of this func are using this func to skip + // tests when running as some sort of "fake root" that's uid 0 +@@ -47,6 +51,9 @@ func skipInContainer(t *testing.T) { + if isLXC() { + t.Skip("skip this test in LXC container") + } ++ if isSchroot() { ++ t.Skip("skip this test in Schroot container") ++ } + } + + func skipNoUserNamespaces(t *testing.T) { diff --git a/debian/patches/series b/debian/patches/series new file mode 100644 index 0000000..63e10a0 --- /dev/null +++ b/debian/patches/series @@ -0,0 +1,4 @@ +0001-Disable-test-for-UserHomeDir.patch +0002-Fix-Lintian-warnings-about-wrong-interpreter-path.patch +0003-cmd-dist-increase-default-timeout-scale-for-arm.patch +0004-skip-userns-test-in-schroot-as-well.patch |