kicad-developers team mailing list archive
Mailing list archive
Re: Linker Error (self made...)
On Tue, Aug 27, 2019 at 02:56:37AM +0200, Ian McInerney wrote:
> I was trying to do a fresh build of master with the address sanitizer
> enabled in Clang, and I am receiving a strange linker error, and was
> curious if anyone else had any thoughts on it.
I fixed a similar error on MSVC once. MSVC encodes the return type in the
mangled symbol, while gcc does not, and the build fell over on MSVC because
we had two different declarations for Pgm(), one returning a reference to
PGM_BASE, the other returning a reference to a compatible type (so this
wasn't a runtime problem).
My suspicion is that something similar is going on here. This could be
something stupid even like a mismatch in compiler flags (which are a mix of
CMAKE_CXX_FLAGS, CMAKE_SHARED_LINKER_FLAGS, CMAKE_MODULE_LINKER_FLAGS and
Compiling with -flto on gcc gives a few warnings about different types
being used in the 3D viewer, usually related to GLM vector types (so
presumably different translation units use different preprocessor macros
when including GLM), but nothing Kiface related (this wouldn't catch any
mismatch in modules that are not linked together though).