llvm.org GIT mirror llvm / 974b190
Use an export list when building JIT unittests. <rdar://problem/12473675> When building with LTO, the internalize pass is hiding some global symbols that are necessary for the JIT unittests. It seems like that may be a bug in LTO to do that by default, but until that gets fixed, this change makes sure that we export the necessary symbols for the tests to pass. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166220 91177308-0d34-0410-b5e6-96231b3b80d8 Bob Wilson 8 years ago
1 changed file(s) with 7 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
3434 LINK_COMPONENTS += oprofilejit
3535 endif
3636
37 EXPORTED_SYMBOL_FILE = $(PROJ_OBJ_DIR)/JITTests.exports
3738
3839 include $(LLVM_SRC_ROOT)/unittests/Makefile.unittest
3940
4041 # Permit these tests to use the JIT's symbolic lookup.
4142 LD.Flags += $(RDYNAMIC)
43
44 # Symbol exports are necessary (at least for now) when building with LTO.
45 $(LLVMUnitTestExe): $(NativeExportsFile)
46 $(PROJ_OBJ_DIR)/JITTests.exports: $(PROJ_SRC_DIR)/JITTests.def $(PROJ_OBJ_DIR)/.dir
47 tail -n +2 $< > $@
48