summaryrefslogtreecommitdiffstats
path: root/source/d/gcc
diff options
context:
space:
mode:
Diffstat (limited to 'source/d/gcc')
-rwxr-xr-xsource/d/gcc/gcc.SlackBuild6
-rw-r--r--source/d/gcc/patches/2701442d0cf6292f6624443c15813d6d1a3562fe.diff43
-rw-r--r--source/d/gcc/patches/f35d65517a59565758107c5b1a51a5fa382f8d1a.diff46
3 files changed, 94 insertions, 1 deletions
diff --git a/source/d/gcc/gcc.SlackBuild b/source/d/gcc/gcc.SlackBuild
index c892a5701..b639d0cf9 100755
--- a/source/d/gcc/gcc.SlackBuild
+++ b/source/d/gcc/gcc.SlackBuild
@@ -2,7 +2,7 @@
# GCC package build script (written by volkerdi@slackware.com)
#
# Copyright 2003, 2004 Slackware Linux, Inc., Concord, California, USA
-# Copyright 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2021 Patrick J. Volkerding, Sebeka, MN, USA
+# Copyright 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2021, 2022 Patrick J. Volkerding, Sebeka, MN, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -163,6 +163,10 @@ cd gcc-$SRCVER || exit 1
# Smite the fixincludes:
zcat $CWD/patches/gcc-no_fixincludes.diff.gz | patch -p1 --verbose --backup --suffix=.orig || exit 1
+# Fix compile with glibc-2.36:
+zcat $CWD/patches/2701442d0cf6292f6624443c15813d6d1a3562fe.diff.gz | patch -p1 --verbose --backup --suffix=.orig || exit 1
+zcat $CWD/patches/f35d65517a59565758107c5b1a51a5fa382f8d1a.diff.gz | patch -p1 --verbose --backup --suffix=.orig || exit 1
+
# Fix perms/owners:
chown -R root:root .
find . \
diff --git a/source/d/gcc/patches/2701442d0cf6292f6624443c15813d6d1a3562fe.diff b/source/d/gcc/patches/2701442d0cf6292f6624443c15813d6d1a3562fe.diff
new file mode 100644
index 000000000..a39baef4f
--- /dev/null
+++ b/source/d/gcc/patches/2701442d0cf6292f6624443c15813d6d1a3562fe.diff
@@ -0,0 +1,43 @@
+From 2701442d0cf6292f6624443c15813d6d1a3562fe Mon Sep 17 00:00:00 2001
+From: Martin Liska <mliska@suse.cz>
+Date: Mon, 11 Jul 2022 22:03:14 +0200
+Subject: [PATCH] libsanitizer: cherry-pick 9cf13067cb5088626ba7 from upstream
+
+9cf13067cb5088626ba7ee1ec4c42ec59c7995a0 [sanitizer] Remove #include <linux/fs.h> to resolve fsconfig_command/mount_attr conflict with glibc 2.36
+---
+ .../sanitizer_platform_limits_posix.cpp | 10 ++++++----
+ 1 file changed, 6 insertions(+), 4 deletions(-)
+
+diff --git a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cpp b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cpp
+index 8ed3e92d270..97fd07acf9d 100644
+--- a/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cpp
++++ b/libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.cpp
+@@ -73,7 +73,9 @@
+ #include <sys/vt.h>
+ #include <linux/cdrom.h>
+ #include <linux/fd.h>
++#if SANITIZER_ANDROID
+ #include <linux/fs.h>
++#endif
+ #include <linux/hdreg.h>
+ #include <linux/input.h>
+ #include <linux/ioctl.h>
+@@ -869,10 +871,10 @@ unsigned struct_ElfW_Phdr_sz = sizeof(Elf_Phdr);
+ unsigned IOCTL_EVIOCGPROP = IOCTL_NOT_PRESENT;
+ unsigned IOCTL_EVIOCSKEYCODE_V2 = IOCTL_NOT_PRESENT;
+ #endif
+- unsigned IOCTL_FS_IOC_GETFLAGS = FS_IOC_GETFLAGS;
+- unsigned IOCTL_FS_IOC_GETVERSION = FS_IOC_GETVERSION;
+- unsigned IOCTL_FS_IOC_SETFLAGS = FS_IOC_SETFLAGS;
+- unsigned IOCTL_FS_IOC_SETVERSION = FS_IOC_SETVERSION;
++ unsigned IOCTL_FS_IOC_GETFLAGS = _IOR('f', 1, long);
++ unsigned IOCTL_FS_IOC_GETVERSION = _IOR('v', 1, long);
++ unsigned IOCTL_FS_IOC_SETFLAGS = _IOW('f', 2, long);
++ unsigned IOCTL_FS_IOC_SETVERSION = _IOW('v', 2, long);
+ unsigned IOCTL_GIO_CMAP = GIO_CMAP;
+ unsigned IOCTL_GIO_FONT = GIO_FONT;
+ unsigned IOCTL_GIO_UNIMAP = GIO_UNIMAP;
+--
+2.31.1
+
+
diff --git a/source/d/gcc/patches/f35d65517a59565758107c5b1a51a5fa382f8d1a.diff b/source/d/gcc/patches/f35d65517a59565758107c5b1a51a5fa382f8d1a.diff
new file mode 100644
index 000000000..61c552e26
--- /dev/null
+++ b/source/d/gcc/patches/f35d65517a59565758107c5b1a51a5fa382f8d1a.diff
@@ -0,0 +1,46 @@
+From f35d65517a59565758107c5b1a51a5fa382f8d1a Mon Sep 17 00:00:00 2001
+From: Ian Lance Taylor <iant@golang.org>
+Date: Tue, 12 Jul 2022 19:42:43 -0700
+Subject: [PATCH] libgo: don't include <linux/fs.h> when building
+ gen-sysinfo.go
+
+Removing this doesn't change anything at least with glibc 2.33.
+The include was added in https://go.dev/cl/6100049 but it's not
+clear why.
+
+Fixes PR go/106266
+
+Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/417294
+---
+ gcc/go/gofrontend/MERGE | 2 +-
+ libgo/sysinfo.c | 3 ---
+ 2 files changed, 1 insertion(+), 4 deletions(-)
+
+diff --git a/gcc/go/gofrontend/MERGE b/gcc/go/gofrontend/MERGE
+index 7c5c45672d7..5ea0406cd8e 100644
+--- a/gcc/go/gofrontend/MERGE
++++ b/gcc/go/gofrontend/MERGE
+@@ -1,4 +1,4 @@
+-70ca85f08edf63f46c87d540fa99c45e2903edc2
++ff68b1a147eb60082fd60c198db0ef5477ade938
+
+ The first line of this file holds the git revision number of the last
+ merge done from the gofrontend repository.
+diff --git a/libgo/sysinfo.c b/libgo/sysinfo.c
+index a4259c02ded..fc0210992fa 100644
+--- a/libgo/sysinfo.c
++++ b/libgo/sysinfo.c
+@@ -158,9 +158,6 @@
+ #if defined(HAVE_LINUX_ETHER_H)
+ #include <linux/ether.h>
+ #endif
+-#if defined(HAVE_LINUX_FS_H)
+-#include <linux/fs.h>
+-#endif
+ #if defined(HAVE_LINUX_REBOOT_H)
+ #include <linux/reboot.h>
+ #endif
+--
+2.31.1
+
+