[Lldb-commits] [PATCH] D25922: Test infra: expose CFLAGS_NO_ARCH for use by test custom build rules
Todd Fiala via lldb-commits
lldb-commits at lists.llvm.org
Tue Oct 25 08:45:18 PDT 2016
tfiala added a comment.
> I am not that excited by this, but I don't see a much better way to achieve the result. :)
> Possibly I'd consider making the variable name positive (instead of CFLAGS_NO_DEBUG, have a INCLUDES var, and then the test can use $(INCLUDES) $(TRIPLE_CFLAGS)).
Jim and I tried a few different ways to skin this. The actual problem shows up on some CI downstream from here, where we need (but fail to get) the isysroot settings. Those are built with a few more variables that have not yet moved up into the Makefile rules in LLVM.org.
The other way to skin this, since it is a macOS only test, is to strip out the arch flags in the TestUniversal Makefile. This approach would work both here and downstream since it doesn't require accessing Makefile variables that don't exist here.
I'll come back with something slightly different here.
Comment at: Python/lldbsuite/test/make/Makefile.rules:197
-ifeq "$(OS)" "Darwin"
- CFLAGS += $(ARCHFLAG) $(ARCH) $(FRAMEWORK_INCLUDES) $(CFLAGS_EXTRAS) -I$(LLDB_BASE_DIR)include
> Are you sure this won't actually be missed on darwin for other tests? `-archi386` does not seem to be a valid argument to clang (you need the space here).
Hmm I ran it through x86_64 and that worked. I didn't try i386. I'll give that a shot. If it blows up, I'll have a look at why a space is needed in one case and not the other on the macOS clang. Thanks for highlighting. (It looked like a meaningless divergence that I thought perhaps came from code motion over time).
More information about the lldb-commits