diff options
author | Bill Wendling <isanbard@gmail.com> | 2012-10-03 23:52:10 +0000 |
---|---|---|
committer | Bill Wendling <isanbard@gmail.com> | 2012-10-03 23:52:10 +0000 |
commit | 10181ae49c25e22267ea3d539dd53e07d5e45528 (patch) | |
tree | 5f76fc30a19949beaf5602227716a3ed43007e50 /tools/lto/Makefile | |
parent | 471b917b265c7c657233d9b8632af344a7d6a43a (diff) |
Add an explicit -object_path_lto flag during linking with a uniquified temporary
file name if building Apple-style.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165185 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/lto/Makefile')
-rw-r--r-- | tools/lto/Makefile | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tools/lto/Makefile b/tools/lto/Makefile index 153fa03137..3e7621f6db 100644 --- a/tools/lto/Makefile +++ b/tools/lto/Makefile @@ -49,4 +49,11 @@ ifeq ($(HOST_OS),Darwin) -Wl,-install_name \ -Wl,"@executable_path/../lib/lib$(LIBRARYNAME)$(SHLIBEXT)" endif + + # If we're doing an Apple-style build, add the LTO object path. + ifeq ($(RC_BUILDIT),YES) + TempFile = $(shell mktemp ${OBJROOT}/llvm-lto.XXXXXX) + LLVMLibsOptions := $(LLVMLibsOptions) \ + -Wl,-object_path_lto -Wl,$(TempFile) + endif endif |