mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-08-05 13:26:55 +00:00
Strip dead code when linking by default with BFD ld (linux, ...) and ld64 (os x).
This reduces the size of clang-format from 22 MB to 1.8 MB, diagtool goes from 21 MB to 2.8 MB, libclang.so goes from 29 MB to 20 MB, etc. The size of the bin/ folder shrinks from 270 MB to 200 MB. Targets that support plugins and don't already use EXPORTED_SYMBOL_FILE (which libclang and libLTO already do) can set NO_DEAD_STRIP to opt out. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@198087 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -49,9 +49,6 @@ ifeq ($(HOST_OS),Darwin)
|
||||
endif
|
||||
# Include everything from the .a's into the shared library.
|
||||
LLVMLibsOptions := $(LLVMLibsOptions) -all_load
|
||||
# extra options to override libtool defaults
|
||||
LLVMLibsOptions := $(LLVMLibsOptions) \
|
||||
-Wl,-dead_strip
|
||||
|
||||
# Mac OS X 10.4 and earlier tools do not allow a second -install_name on command line
|
||||
DARWIN_VERS := $(shell echo $(TARGET_TRIPLE) | sed 's/.*darwin\([0-9]*\).*/\1/')
|
||||
|
Reference in New Issue
Block a user