From 7f6c7b9be96640df5b5e0fad5807990651ffb315 Mon Sep 17 00:00:00 2001 From: Ionen Wolkens Date: Mon, 18 Sep 2023 22:57:21 -0400 Subject: dev-qt/qtbase: import hppa forkfd fix from debian Some of bug #914371's issues could (ideally) still need looking into/attention, but believe reasonable to close for now and allow keywording assuming did not overlook anything. Closes: https://bugs.gentoo.org/914371 Signed-off-by: Ionen Wolkens --- .../qtbase-6.5.2-hppa-forkfd-grow-stack.patch | 28 ++++++++++++++++++++++ dev-qt/qtbase/qtbase-6.5.2-r2.ebuild | 1 + dev-qt/qtbase/qtbase-6.5.9999.ebuild | 1 + dev-qt/qtbase/qtbase-6.6.9999.ebuild | 1 + dev-qt/qtbase/qtbase-6.9999.ebuild | 1 + 5 files changed, 32 insertions(+) create mode 100644 dev-qt/qtbase/files/qtbase-6.5.2-hppa-forkfd-grow-stack.patch (limited to 'dev-qt') diff --git a/dev-qt/qtbase/files/qtbase-6.5.2-hppa-forkfd-grow-stack.patch b/dev-qt/qtbase/files/qtbase-6.5.2-hppa-forkfd-grow-stack.patch new file mode 100644 index 000000000000..ccada9f80e34 --- /dev/null +++ b/dev-qt/qtbase/files/qtbase-6.5.2-hppa-forkfd-grow-stack.patch @@ -0,0 +1,28 @@ +Patch taken from Debian[1], largely broken on HPPA without and several +tests give segmentation faults[2]. + +Needs upstreaming if someone familiar with HPPA wants to give this +attention. Note forkfd is essentially maintained in qtbase's repo[3] +rather than truly third party. + +[1] https://bugs.debian.org/1042018 +[2] https://bugs.gentoo.org/914371 +[3] https://code.qt.io/cgit/qt/qtbase.git/tree/src/3rdparty/forkfd + +Description: Change how stack grows on HPPA. + On HPPA stack grows upwards. This patch introduces this change for + this 3rd party code. +Author: John David Anglin +--- a/src/3rdparty/forkfd/forkfd_linux.c ++++ b/src/3rdparty/forkfd/forkfd_linux.c +@@ -170,5 +170,10 @@ + *system = 1; + ++#if defined(__hppa__) ++ /* Stack grows up */ ++ pid = clone(childFn, childStack, cloneflags, token, &pidfd, NULL, NULL); ++#else + pid = clone(childFn, childStack + sizeof(childStack), cloneflags, token, &pidfd, NULL, NULL); ++#endif + if (pid < 0) + return pid; diff --git a/dev-qt/qtbase/qtbase-6.5.2-r2.ebuild b/dev-qt/qtbase/qtbase-6.5.2-r2.ebuild index c47ffa70d566..add31f2972ab 100644 --- a/dev-qt/qtbase/qtbase-6.5.2-r2.ebuild +++ b/dev-qt/qtbase/qtbase-6.5.2-r2.ebuild @@ -130,6 +130,7 @@ PDEPEND=" " PATCHES=( + "${FILESDIR}"/${PN}-6.5.2-hppa-forkfd-grow-stack.patch "${FILESDIR}"/${PN}-6.5.2-no-symlink-check.patch "${FILESDIR}"/${P}-CVE-2023-38197.patch "${FILESDIR}"/${P}-tests-gcc13.patch diff --git a/dev-qt/qtbase/qtbase-6.5.9999.ebuild b/dev-qt/qtbase/qtbase-6.5.9999.ebuild index a5e477d6c8c6..9511c2c54404 100644 --- a/dev-qt/qtbase/qtbase-6.5.9999.ebuild +++ b/dev-qt/qtbase/qtbase-6.5.9999.ebuild @@ -130,6 +130,7 @@ PDEPEND=" " PATCHES=( + "${FILESDIR}"/${PN}-6.5.2-hppa-forkfd-grow-stack.patch "${FILESDIR}"/${PN}-6.5.2-no-symlink-check.patch ) diff --git a/dev-qt/qtbase/qtbase-6.6.9999.ebuild b/dev-qt/qtbase/qtbase-6.6.9999.ebuild index ba01c16ca68f..87e7e43c198a 100644 --- a/dev-qt/qtbase/qtbase-6.6.9999.ebuild +++ b/dev-qt/qtbase/qtbase-6.6.9999.ebuild @@ -130,6 +130,7 @@ PDEPEND=" " PATCHES=( + "${FILESDIR}"/${PN}-6.5.2-hppa-forkfd-grow-stack.patch "${FILESDIR}"/${PN}-6.5.2-no-symlink-check.patch ) diff --git a/dev-qt/qtbase/qtbase-6.9999.ebuild b/dev-qt/qtbase/qtbase-6.9999.ebuild index 21e519807742..0df3665e86a0 100644 --- a/dev-qt/qtbase/qtbase-6.9999.ebuild +++ b/dev-qt/qtbase/qtbase-6.9999.ebuild @@ -132,6 +132,7 @@ PDEPEND=" " PATCHES=( + "${FILESDIR}"/${PN}-6.5.2-hppa-forkfd-grow-stack.patch "${FILESDIR}"/${PN}-6.5.2-no-symlink-check.patch ) -- cgit v1.2.3-65-gdbad