]> code.ossystems Code Review - openembedded-core.git/commitdiff
glibc: don't ignore global LDFLAGS settings
authorRasmus Villemoes <rasmus.villemoes@prevas.dk>
Mon, 20 Jan 2020 09:23:06 +0000 (09:23 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 4 Feb 2020 15:56:24 +0000 (15:56 +0000)
Two things: The -Wl,-rpath-link comment is stale (due to per-recipe
staging), so we no longer need to set our own LDFLAGS to avoid
-Wl,-rpath-link being in there. Second, overriding LDFLAGS should be
done at the recipe level so "bitbake -e" can show what is going on.
Otherwise debugging why one's global LDFLAGS tweaks are being ignored
is needlessly painful.

So pull out the LDFLAGS setting from do_compile, and change it to an
append instead of assignment.

For the benefit of future git blame: the -fuse-ld=bfd setting was
added by ac64c3b96b (glibc: always use bfd linker).

Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-core/glibc/glibc_2.31.bb

index 9f299a7bc35696aafbe8f585a960ccbb263b572a..2032311b27c771a882e945203067c9ba340695db 100644 (file)
@@ -91,9 +91,8 @@ do_configure () {
         CPPFLAGS="" oe_runconf
 }
 
+LDFLAGS += "-fuse-ld=bfd"
 do_compile () {
-       # -Wl,-rpath-link <staging>/lib in LDFLAGS can cause breakage if another glibc is in staging
-       LDFLAGS="-fuse-ld=bfd"
        base_do_compile
        echo "Adjust ldd script"
        if [ -n "${RTLDLIST}" ]