dev-lang/perl: fix linking on Solaris, bug #677676
authorFabian Groffen <grobian@gentoo.org>
Tue, 19 Feb 2019 14:48:52 +0000 (15:48 +0100)
committerFabian Groffen <grobian@gentoo.org>
Tue, 19 Feb 2019 14:49:09 +0000 (15:49 +0100)
Closes: https://bugs.gentoo.org/677676
Signed-off-by: Fabian Groffen <grobian@gentoo.org>
Package-Manager: Portage-2.3.51, Repoman-2.3.11

dev-lang/perl/perl-5.28.0.ebuild
dev-lang/perl/perl-5.28.9999.ebuild

index bacc75e30d881ea2401d140bdd423224fcfded96..71fc2b82b39bd00aabc89329293cf2b8a8d11213 100644 (file)
@@ -307,8 +307,6 @@ src_prepare() {
                # do NOT mess with nsl, on Solaris this is always necessary,
                # when -lsocket is used e.g. to get h_errno
                sed -i '/gentoo\/no-nsl\.patch/d' "${WORKDIR}/patches/series" || die
-               # and set a soname
-               sed -i 's/sunos\*/sunos*|solaris*/' Makefile.SH || die
        fi
 
        einfo "Applying patches from ${PATCH_BASE} ..."
@@ -333,6 +331,11 @@ src_prepare() {
                sed -i "/my..sysroot/s:'':'${EPREFIX}':" ext/Errno/Errno_pm.PL || die
        fi
 
+       if [[ ${CHOST} == *-solaris* ]] ; then
+               # set a soname, fix linking against just built libperl
+               sed -i -e 's/netbsd\*/netbsd*|solaris*/' Makefile.SH || die
+       fi
+
        default
 }
 
index bacc75e30d881ea2401d140bdd423224fcfded96..71fc2b82b39bd00aabc89329293cf2b8a8d11213 100644 (file)
@@ -307,8 +307,6 @@ src_prepare() {
                # do NOT mess with nsl, on Solaris this is always necessary,
                # when -lsocket is used e.g. to get h_errno
                sed -i '/gentoo\/no-nsl\.patch/d' "${WORKDIR}/patches/series" || die
-               # and set a soname
-               sed -i 's/sunos\*/sunos*|solaris*/' Makefile.SH || die
        fi
 
        einfo "Applying patches from ${PATCH_BASE} ..."
@@ -333,6 +331,11 @@ src_prepare() {
                sed -i "/my..sysroot/s:'':'${EPREFIX}':" ext/Errno/Errno_pm.PL || die
        fi
 
+       if [[ ${CHOST} == *-solaris* ]] ; then
+               # set a soname, fix linking against just built libperl
+               sed -i -e 's/netbsd\*/netbsd*|solaris*/' Makefile.SH || die
+       fi
+
        default
 }