Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 335741

Summary: sys-block/btrace does not respect LDFLAGS
Product: Gentoo Linux Reporter: Diego Elio Pettenò (RETIRED) <flameeyes>
Component: New packagesAssignee: Robin Johnson <robbat2>
Severity: QA    
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 331933    
Attachments: Build log
Patch to btrace-1.0.0.ebuild to respect LDFLAGS
Replacement for existing btrace-1.0.0-parallel-make.patch

Description Diego Elio Pettenò (RETIRED) gentoo-dev 2010-09-03 01:05:04 UTC
See attached build log.

(Please do not complain about the need for looking at the build log until you can provide an easy way to open bugs with the correct data picked out of a tinderbox log. Thanks.)
Comment 1 Diego Elio Pettenò (RETIRED) gentoo-dev 2010-09-03 01:05:16 UTC
Created attachment 245811 [details]
Build log
Comment 2 Kevin Pyle 2010-09-03 03:52:54 UTC
Created attachment 245822 [details, diff]
Patch to btrace-1.0.0.ebuild to respect LDFLAGS

This patch adds a sed expression to insert $(LDFLAGS) in the lines that link binaries.

Also, while testing, I noticed that a high level of parallelism still causes build failures, even with btrace-1.0.0-parallel-make.patch applied.  I see why this is, and will attach a replacement patch that is not affected.
Comment 3 Kevin Pyle 2010-09-03 03:56:13 UTC
Created attachment 245823 [details, diff]
Replacement for existing btrace-1.0.0-parallel-make.patch

The existing patch, although better than nothing, still allows an unsafe parallelism in the case that Make decides to build btreplay/btreplay and btreplay/btrecord in parallel.  When it does so, it spawns two copies of "$(MAKE) -C btreplay", which proceed to step on each other in the subdirectory.  The fix I chose here is to make both those targets have no rule of their own, but to have them both depend on a single phony target which does descend into btreplay.  This way, make performs one descent and compiles everything in that directory, then goes to process the two targets and finds no further work to do.
Comment 4 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2011-02-03 03:07:41 UTC
Fixed in a different manner as your parallel fixes caused it to try and rebuild the btreplay binaries from the .make phony file.