poky/meta/recipes-core/glibc/glibc.inc
Khem Raj 3dd005248f glibc: Disable Werror when building with debug options
Since compiler does not optimize away a lot of stuff we end up with
Werrors e.g.

./sysdeps/ieee754/flt-32/s_log1pf.c: In function '__log1pf':
../sysdeps/ieee754/flt-32/s_log1pf.c:114:22: error: 'c' may be used uninitialized in this function [-Werror=maybe-uninitialized]
  114 |        + (k * ln2_lo + c))) - f);
      |          ~~~~~~~~~~~~^~~~

which otherwise wont happen, so lets build with warnings-as-errors
disabled in debug mode

given we disable werror, now we don't have to restrict user to compile
without -O0

(From OE-Core rev: 9772eaafc1cb5957661d43e8f76c6f9b07b854dc)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2019-03-02 16:49:07 +00:00

50 lines
1.5 KiB
PHP

require glibc-common.inc
require glibc-ld.inc
require glibc-testing.inc
DEPENDS = "virtual/${TARGET_PREFIX}gcc libgcc-initial linux-libc-headers"
PROVIDES = "virtual/libc"
PROVIDES += "virtual/libintl virtual/libiconv"
inherit autotools texinfo distro_features_check systemd
LEAD_SONAME = "libc.so"
CACHED_CONFIGUREVARS += " \
ac_cv_path_BASH_SHELL=${base_bindir}/bash \
libc_cv_slibdir=${base_libdir} \
libc_cv_rootsbindir=${base_sbindir} \
libc_cv_localedir=${localedir} \
libc_cv_ssp_strong=no \
libc_cv_ssp_all=no \
libc_cv_ssp=no \
"
# ifunc doesn't appear to work on mips, casuses libbfd assertion failures
CACHED_CONFIGUREVARS_append_mipsarch = " libc_cv_ld_gnu_indirect_function=no"
GLIBC_EXTRA_OECONF ?= ""
GLIBC_EXTRA_OECONF_class-nativesdk = ""
# glibc uses PARALLELMFLAGS variable to pass parallel build info so transfer
# PARALLEL_MAKE into PARALLELMFLAGS and empty out PARALLEL_MAKE
EGLIBCPARALLELISM := "PARALLELMFLAGS="${PARALLEL_MAKE}""
EXTRA_OEMAKE[vardepsexclude] += "EGLIBCPARALLELISM"
EXTRA_OEMAKE += "${EGLIBCPARALLELISM}"
PARALLEL_MAKE = ""
# glibc make-syscalls.sh has a number of issues with /bin/dash and
# it's output which make calls via the SHELL also has issues, so
# ensure make uses /bin/bash
EXTRA_OEMAKE += "SHELL=/bin/bash"
do_configure_prepend() {
sed -e "s#@BASH@#/bin/sh#" -i ${S}/elf/ldd.bash.in
}
# Enable backtrace from abort()
do_configure_append_arm () {
echo "CFLAGS-abort.c = -fasynchronous-unwind-tables" >> ${B}/configparms
echo "CFLAGS-raise.c = -fasynchronous-unwind-tables" >> ${B}/configparms
}