commit:     90061e9a748419f7a3e2e23ca9e10623c294a938
Author:     Ionen Wolkens <sudinave <AT> gmail <DOT> com>
AuthorDate: Wed Apr 14 13:07:09 2021 +0000
Commit:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Thu Apr 15 06:38:57 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=90061e9a

x11-misc/xsnap: fix build with -native-symlinks

Removed no longer necessary sed for toolchain vars and swapped
DEPEND with BDEPEND to put imake in the right block

Closes: https://bugs.gentoo.org/726242
Signed-off-by: Ionen Wolkens <sudinave <AT> gmail.com>
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>

 x11-misc/xsnap/xsnap-1.5.15-r2.ebuild | 25 +++++++++++--------------
 1 file changed, 11 insertions(+), 14 deletions(-)

diff --git a/x11-misc/xsnap/xsnap-1.5.15-r2.ebuild 
b/x11-misc/xsnap/xsnap-1.5.15-r2.ebuild
index e28502a5b0c..dd43dcab643 100644
--- a/x11-misc/xsnap/xsnap-1.5.15-r2.ebuild
+++ b/x11-misc/xsnap/xsnap-1.5.15-r2.ebuild
@@ -24,12 +24,12 @@ RDEPEND="
        ${COMMON_DEPEND}
        media-fonts/font-misc-misc
 "
-DEPEND="
-       ${COMMON_DEPEND}
+DEPEND="${COMMON_DEPEND}"
+BDEPEND="
        app-text/rman
        dev-lang/perl
        x11-base/xorg-proto
-       x11-misc/imake
+       >=x11-misc/imake-1.0.8-r1
 "
 DOCS=( AUTHORS Changelog README )
 PATCHES=( "${FILESDIR}"/${P}-root_name.patch )
@@ -46,21 +46,18 @@ src_prepare() {
        sed -i \
                -e '/^LOCALEDIR=/d' \
                po/Makefile || die
+}
 
-       xmkmf || die
-
-       sed -i \
-               -e '/ CC = /d' \
-               -e '/ LD = /d' \
-               -e '/ CDEBUGFLAGS = /d' \
-               -e '/ CCOPTIONS = /d' \
-               -e 's|CPP = cpp|CPP = $(CC)|g' \
-               Makefile || die
+src_configure() {
+       CC="$(tc-getBUILD_CC)" LD="$(tc-getLD)" \
+               IMAKECPP="${IMAKECPP:-$(tc-getCPP)}" xmkmf || die
 }
 
 src_compile() {
-       tc-export CC
-       emake CCOPTIONS="${CFLAGS}" EXTRA_LDOPTIONS="${LDFLAGS}"
+       emake \
+               CC="$(tc-getCC)" \
+               CDEBUGFLAGS="${CFLAGS}" \
+               EXTRA_LDOPTIONS="${LDFLAGS}"
 }
 
 src_install() {

Reply via email to