-
Notifications
You must be signed in to change notification settings - Fork 38.2k
Fix linker error when configured with --enable-lcov #9420
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
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. |
|
@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 |
|
ACK |
|
utACK |
|
utACK |
|
utACK e2b5c98 |
e2b5c98 Fix linker error when configured with --enable-lcov (Douglas Roark)
e2b5c98 Fix linker error when configured with --enable-lcov (Douglas Roark)
e2b5c98 Fix linker error when configured with --enable-lcov (Douglas Roark)
e2b5c98 Fix linker error when configured with --enable-lcov (Douglas Roark)
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.