[PATCH] Don't set $LIB if we're not targetting windows.
filcab+llvm.phabricator at gmail.com
Thu Feb 19 09:27:42 PST 2015
On Thursday, February 19, 2015, Timur Iskhodzhanov <timurrrr at google.com>
> The comment came with my private code. But I don't feel strongly about it.
> I see.
>> The thing is: we might be running on Windows, but targeting a different
>> OS. In which case we don't want to pass LIB along. Your toolchain runs on
>> Windows, but you're compiling for arch-vendor-anotheros.
> I'm not sure how cross-compilation of tests works in LLVM.
> Do we ever invoke LIT for anything that we can't run on the current system?
You can just set COMPILER_RT_EMULATOR and all tests will be run with it.
With that + a clang built with -DLLVM_DEFAULT_TARGET_TRIPLE=... you can
easily cross-compile and run the compiler-rt tests.
I have another patch I might submit to phabricator to see if there's an
interest in having it, which allows you to easily set additional compiler
flags for the tests (useful if your toolchain doesn't fully support the
-fsanitize= linking args, but not that useful elsewhere).
>> Wouldn't lld on Windows also look at LIB if it was emulating link.exe (I
>> don't know if there's a mode for that, like for emulating ld)?
> Good point, I'm pretty sure LLD would need LIB to be set too.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the llvm-commits