Tested on OS X and Linux. Haven't tested on Windows. Can somebody check and see if this is necessary over there? I assume it is.
Fix linker error when configured with --enable-lcov #9420
pull droark wants to merge 1 commits into bitcoin:master from droark:fixlcov changing 1 files +2 −0-
droark commented at 8:30 PM on December 24, 2016: contributor
- droark force-pushed on Dec 24, 2016
-
gmaxwell commented at 4:45 PM on December 25, 2016: contributor
I think this should be passing --coverage and not -fprofile-arcs as an ldflag (the actual behavior we were missing in the linker -lgcov but --coverage is an alias for "do the right thing for coverage"). Apparently -fprofile-arcs is also doing the same thing right now for linking, but I wouldn't depend on it to be as robust or to pick up future coverage knobs.
I wasn't previously aware we had this option, whenever I previously wanted to generate coverage I'd twiddled the cflags and ldflags myself.
- droark force-pushed on Dec 25, 2016
-
droark commented at 7:37 PM on December 25, 2016: contributor
@gmaxwell - Yeah, I didn't know either. It's amazing what a code deep dive will turn up. :) I'm tempted to write a doc with all the config options and PR it.
Anyway, you're right. I somehow missed the lcov web page, which says to use
--coveragefor both the compiler and linker. Just compiled and linked on OSX (make checkpasses too), and did a fixup. - fanquake added the label Build system on Dec 26, 2016
-
gmaxwell commented at 9:54 PM on December 26, 2016: contributor
ACK
-
sipa commented at 4:47 PM on December 27, 2016: member
utACK
-
Fix linker error when configured with --enable-lcov e2b5c98cef
- droark force-pushed on Dec 29, 2016
-
btcdrak commented at 4:18 AM on December 30, 2016: contributor
utACK
-
jonasschnelli commented at 7:43 AM on December 30, 2016: contributor
utACK e2b5c98cefc45a1404d4ec3230860f2e1c5df0c9
- jonasschnelli merged this on Dec 30, 2016
- jonasschnelli closed this on Dec 30, 2016
- jonasschnelli referenced this in commit bebe3697fd on Dec 30, 2016
- codablock referenced this in commit e3fbe15208 on Jan 18, 2018
- andvgal referenced this in commit 9ce6ecaf30 on Jan 6, 2019
- CryptoCentric referenced this in commit 3d470fc6cd on Feb 26, 2019
- DrahtBot locked this on Sep 8, 2021