From b7d5d123f75de06cb3ea110788469f7c7a3a20b4 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Sun, 3 Jan 2021 18:34:51 +0000 Subject: dev-lang/gforth: fix clang build (use -rdynamic) Reported-by: Agostino Sarubbo Closes: https://bugs.gentoo.org/729874 Package-Manager: Portage-3.0.12, Repoman-3.0.2 Signed-off-by: Sergei Trofimovich --- dev-lang/gforth/files/gforth-0.7.3-rdynamic-auto.patch | 16 ++++++++++++++++ dev-lang/gforth/files/gforth-0.7.3-rdynamic.patch | 14 ++++++++++++++ dev-lang/gforth/gforth-0.7.3-r1.ebuild | 16 +++++++++++++--- 3 files changed, 43 insertions(+), 3 deletions(-) create mode 100644 dev-lang/gforth/files/gforth-0.7.3-rdynamic-auto.patch create mode 100644 dev-lang/gforth/files/gforth-0.7.3-rdynamic.patch (limited to 'dev-lang') diff --git a/dev-lang/gforth/files/gforth-0.7.3-rdynamic-auto.patch b/dev-lang/gforth/files/gforth-0.7.3-rdynamic-auto.patch new file mode 100644 index 000000000000..8a5b65282907 --- /dev/null +++ b/dev-lang/gforth/files/gforth-0.7.3-rdynamic-auto.patch @@ -0,0 +1,16 @@ +--- a/configure ++++ b/configure +@@ -4721,10 +4733,10 @@ test "$make_type" = "GNU Make" && GNUMAKE='' + $as_echo "$make_type" >&6; } + + +-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -export-dynamic" >&5 +-$as_echo_n "checking whether the linker accepts -export-dynamic... " >&6; } ++{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the linker accepts -rdynamic" >&5 ++$as_echo_n "checking whether the linker accepts -rdynamic... " >&6; } + OLDLDFLAGS=$LDFLAGS +-LDFLAGS="$LDFLAGS -export-dynamic" ++LDFLAGS="$LDFLAGS -rdynamic" + if test "$cross_compiling" = yes; then : + ac_export_dynamic=no + else diff --git a/dev-lang/gforth/files/gforth-0.7.3-rdynamic.patch b/dev-lang/gforth/files/gforth-0.7.3-rdynamic.patch new file mode 100644 index 000000000000..e776f4d40d04 --- /dev/null +++ b/dev-lang/gforth/files/gforth-0.7.3-rdynamic.patch @@ -0,0 +1,14 @@ +--- a/configure.in ++++ b/configure.in +@@ -191,9 +191,9 @@ test "$make_type" = "GNU Make" && GNUMAKE='' + AC_MSG_RESULT($make_type) + AC_SUBST(GNUMAKE) + +-AC_MSG_CHECKING([whether the linker accepts -export-dynamic]) ++AC_MSG_CHECKING([whether the linker accepts -rdynamic]) + OLDLDFLAGS=$LDFLAGS +-LDFLAGS="$LDFLAGS -export-dynamic" ++LDFLAGS="$LDFLAGS -rdynamic" + dnl AC_TRY_LINK gives false positive on rs6000-ibm-aix4.2.1.0 + dnl AC_TRY_LINK(,,ac_export_dynamic=yes,ac_export_dynamic=no) + AC_TRY_RUN(main(){exit(0);},ac_export_dynamic=yes,ac_export_dynamic=no,ac_export_dynamic=no) diff --git a/dev-lang/gforth/gforth-0.7.3-r1.ebuild b/dev-lang/gforth/gforth-0.7.3-r1.ebuild index 01598f0f239e..ddf2c89a40a8 100644 --- a/dev-lang/gforth/gforth-0.7.3-r1.ebuild +++ b/dev-lang/gforth/gforth-0.7.3-r1.ebuild @@ -1,9 +1,9 @@ -# Copyright 1999-2020 Gentoo Authors +# Copyright 1999-2021 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=6 +EAPI=7 -inherit elisp-common eutils +inherit elisp-common DESCRIPTION="GNU Forth is a fast and portable implementation of the ANSI Forth language" HOMEPAGE="https://www.gnu.org/software/gforth" @@ -22,8 +22,18 @@ SITEFILE="50${PN}-gentoo.el" PATCHES=( "${FILESDIR}"/${PN}-0.7.0-make-elc.patch + "${FILESDIR}"/${PN}-0.7.3-rdynamic.patch + "${FILESDIR}"/${PN}-0.7.3-rdynamic-auto.patch ) +src_prepare() { + default + + # We patches both configure and configure.ac. + # Avoid reruining aclocal. + touch aclocal.m4 configure || die +} + src_configure() { econf \ $(use emacs || echo "--without-lispdir") \ -- cgit v1.2.3