BullseyeCoverage Up Contents Search

Unresolved Symbol cov_linkBypassDetect

Symptoms

The linker reports the unresolved symbol cov_linkBypassDetect. For example:

error LNK2019: unresolved external symbol cov_linkBypassDetect referenced in function F
Or:
libcov.a(libcov.o): undefined reference to `cov_linkBypassDetect'.

Cause

Your build procedure bypassed BullseyeCoverage during linking. BullseyeCoverage must process linker commands to add the proper libraries, objects and options appropriate to the kind of executable.

Resolution

Invoke the linker using the same invocation format as you use to invoke the compiler. Do not invoke the linker using an absolute path. For example, do not invocation the linker as shown below.

"c:/Program Files (x86)/Microsoft Visual Studio/2019/Community/VC/Tools/MSVC/14.28.29910/bin/Hostx64/x64/link.exe" ...  ← wrong
Or:
/usr/bin/g++ ...  ← wrong

See Integrating With Your Build Process.

Updated: 30 Nov 2021