summaryrefslogtreecommitdiff
path: root/sys-libs/glibc/glibc-9999.ebuild
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2019-04-28 09:54:45 +0100
committerV3n3RiX <venerix@redcorelinux.org>2019-04-28 09:54:45 +0100
commitb7ebc951da8800f711142f69d9d958bde67a112d (patch)
treee318514216845acb8f2e49fff7a5cba4027e9d91 /sys-libs/glibc/glibc-9999.ebuild
parentdc7cbdfa65fd814b3b9aa3c56257da201109e807 (diff)
gentoo resync : 28.04.2019
Diffstat (limited to 'sys-libs/glibc/glibc-9999.ebuild')
-rw-r--r--sys-libs/glibc/glibc-9999.ebuild40
1 files changed, 38 insertions, 2 deletions
diff --git a/sys-libs/glibc/glibc-9999.ebuild b/sys-libs/glibc/glibc-9999.ebuild
index 478b5e5c9dc6..3655b03320f1 100644
--- a/sys-libs/glibc/glibc-9999.ebuild
+++ b/sys-libs/glibc/glibc-9999.ebuild
@@ -3,7 +3,7 @@
EAPI=6
-PYTHON_COMPAT=( python3_{4,5,6,7} )
+PYTHON_COMPAT=( python3_{5,6,7} )
inherit python-any-r1 prefix eutils eapi7-ver toolchain-funcs flag-o-matic gnuconfig \
multilib systemd multiprocessing
@@ -35,7 +35,7 @@ PATCH_VER=11
SRC_URI+=" https://dev.gentoo.org/~slyfox/distfiles/${P}-patches-${PATCH_VER}.tar.xz"
SRC_URI+=" multilib? ( https://dev.gentoo.org/~dilfridge/distfiles/gcc-multilib-bootstrap-${GCC_BOOTSTRAP_VER}.tar.xz )"
-IUSE="audit caps cet compile-locales doc gd headers-only +multiarch multilib nscd profile selinux +ssp suid systemtap test vanilla"
+IUSE="audit caps cet compile-locales doc gd headers-only +multiarch multilib nscd profile selinux +ssp +static-libs suid systemtap test vanilla"
# Minimum kernel version that glibc requires
MIN_KERN_VER="3.2.0"
@@ -720,6 +720,11 @@ pkg_pretend() {
sanity_prechecks
}
+pkg_setup() {
+ # see bug 682570
+ [[ -z ${BOOTSTRAP_RAP} ]] && python-any-r1_pkg_setup
+}
+
# src_unpack
src_unpack() {
@@ -795,6 +800,17 @@ glibc_do_configure() {
# Some of the tests are written in C++, so we need to force our multlib abis in, bug 623548
export CXX="$(tc-getCXX ${CTARGET}) $(get_abi_CFLAGS) ${CFLAGS}"
+
+ if is_crosscompile; then
+ # Assume worst-case bootstrap: glibc is buil first time
+ # when ${CTARGET}-g++ is not available yet. We avoid
+ # building auxiliary programs that require C++: bug #683074
+ # It should not affect final result.
+ export libc_cv_cxx_link_ok=no
+ # The line above has the same effect. We set CXX explicitly
+ # to make build logs less confusing.
+ export CXX=
+ fi
einfo " $(printf '%15s' 'Manual CXX:') ${CXX}"
echo
@@ -1165,6 +1181,9 @@ glibc_do_src_install() {
# powerpc
ppc /lib/ld.so.1
ppc64 /lib64/ld64.so.1
+ # riscv
+ lp64d /lib/ld-linux-riscv64-lp64d.so.1
+ lp64 /lib/ld-linux-riscv64-lp64.so.1
# s390
s390 /lib/ld.so.1
s390x /lib/ld64.so.1
@@ -1247,6 +1266,17 @@ glibc_do_src_install() {
fi
done
+ # HACK: If we're building for riscv, we need to additionally make sure that
+ # we can find the locale archive afterwards
+ case ${CTARGET} in
+ riscv*)
+ if [[ ! -e ${ED}/usr/lib/locale ]] ; then
+ dosym ../$(get_libdir)/locale /usr/lib/locale
+ fi
+ ;;
+ *) ;;
+ esac
+
cd "${S}"
# Install misc network config files
@@ -1327,6 +1357,12 @@ src_install() {
fi
foreach_abi glibc_do_src_install
+
+ if ! use static-libs ; then
+ elog "Not installing static glibc libraries"
+ find "${ED}" -name "*.a" -and -not -name "*_nonshared.a" -delete
+ fi
+
src_strip
}