Closed Bug 1307179 Opened 8 years ago Closed 8 years ago

Windows ASan build fail due to multiply defined _recalloc

Categories

(Firefox Build System :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: away, Unassigned)

References

Details

With the pre-built 3.9.0 Win32 LLVM binaries, configure aborts: 0:24.08 DEBUG: configure:5208: d:/tools/llvm-active/bin/clang-cl.EXE -Xclang -std=gnu99 -fms-compatibility-version=19.00.23918 -fallback -o conftest -fsanitize=address -TC -nologo -wd4091 -D_HAS_EXCEPTIONS=0 -Qunused-arguments -fsanitize=address conftest.c 1>&5 0:24.08 DEBUG: libucrt.lib(recalloc.obj) : error LNK2005: __recalloc already defined in clang_rt.asan-i386.lib(asan_malloc_win.cc.obj) $ cat $MOZCONFIG mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/obj/asan ac_add_options --enable-address-sanitizer export CC=clang-cl export CXX=clang-cl
Yeah, I get the same failure if I try to build compiler-rt trunk with Visual Studio 2015. Doesn't happen with VS2013. I suspect this is related to the CRT refactoring that occurred in VS2015 (I don't recall "libucrt" existing in previous Visual Studios).
It may be a good idea to check with the Google ASan team to see if they have started the work to support MSVC 2015. As you suspected, I'm fairly certain that some work would be needed to hook into the new runtime libraries in 2015.
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.