From 581973a7c1aff3201ff85b07b7004f53156ce7d0 Mon Sep 17 00:00:00 2001 From: Jakov Smolic Date: Tue, 2 Mar 2021 21:08:06 +0100 Subject: sci-geosciences/gmt: Apply gcc-10 workaround * Fix undeclared sys_siglist issue. Thanks to hangglider@gmx.de for providing the patch. Thanks-to: hangglider@gmx.de Closes: https://bugs.gentoo.org/738224 Closes: https://bugs.gentoo.org/710088 Signed-off-by: Jakov Smolic Signed-off-by: Sam James --- sci-geosciences/gmt/files/gmt-5.4.4-sighandler.patch | 14 ++++++++++++++ sci-geosciences/gmt/gmt-5.4.4.ebuild | 7 ++++++- 2 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 sci-geosciences/gmt/files/gmt-5.4.4-sighandler.patch (limited to 'sci-geosciences/gmt') diff --git a/sci-geosciences/gmt/files/gmt-5.4.4-sighandler.patch b/sci-geosciences/gmt/files/gmt-5.4.4-sighandler.patch new file mode 100644 index 000000000000..54aecb3c0d55 --- /dev/null +++ b/sci-geosciences/gmt/files/gmt-5.4.4-sighandler.patch @@ -0,0 +1,14 @@ +https://bugs.gentoo.org/738224 +Author: hangglider@gmx.de +--- a/src/common_sighandler.c ++++ b/src/common_sighandler.c +@@ -187,7 +187,7 @@ + return; + } + else { +- fprintf (stderr, "ERROR: Caught signal number %d (%s) at\n", sig_num, sys_siglist[sig_num]); ++ fprintf (stderr, "ERROR: Caught signal number %d (%s) at\n", sig_num, strsignal(sig_num)); + backtrace_symbols_fd (array, 2, STDERR_FILENO); /* print function with faulting instruction */ + size = backtrace (array, 50); /* get void*'s for all entries on the stack */ + fprintf (stderr, "Stack backtrace:\n"); + diff --git a/sci-geosciences/gmt/gmt-5.4.4.ebuild b/sci-geosciences/gmt/gmt-5.4.4.ebuild index 31d9c0f51243..2b891c81bc2f 100644 --- a/sci-geosciences/gmt/gmt-5.4.4.ebuild +++ b/sci-geosciences/gmt/gmt-5.4.4.ebuild @@ -3,7 +3,7 @@ EAPI=7 -inherit bash-completion-r1 cmake +inherit bash-completion-r1 cmake flag-o-matic DESCRIPTION="Powerful map generator" HOMEPAGE="https://gmt.soest.hawaii.edu/" @@ -33,6 +33,8 @@ RDEPEND="${DEPEND} sci-geosciences/gshhg-gmt " +PATCHES=( "${FILESDIR}"/${P}-sighandler.patch ) + src_prepare() { cmake_src_prepare # Rename man pages to avoid a name conflict with gmt4 @@ -57,6 +59,9 @@ src_prepare() { } src_configure() { + # https://bugs.gentoo.org/710088 + # drop on version bump + append-cflags -fcommon local mycmakeargs=( -DGMT_DATADIR="share/${P}" -DGMT_DOCDIR="share/doc/${PF}" -- cgit v1.2.3-65-gdbad