1 --- llvm-3.8.1.src/Makefile.rules.orig 2016-08-10 23:42:36.970414278 +0200
2 +++ llvm-3.8.1.src/Makefile.rules 2016-08-10 23:45:12.899913722 +0200
4 LD.Flags += -Wl,-dead_strip
6 ifeq ($(HOST_OS),SunOS)
7 - LD.Flags += -Wl,-z -Wl,discard-unused=sections
8 + LD.Flags += -Wl,-z -Wl,ignore
10 ifneq ($(HOST_OS), $(filter $(HOST_OS), Cygwin MingW))
11 LD.Flags += -Wl,--gc-sections
12 --- llvm-3.8.1.src/cmake/modules/AddLLVM.cmake.orig 2016-08-10 23:42:42.590840775 +0200
13 +++ llvm-3.8.1.src/cmake/modules/AddLLVM.cmake 2016-08-10 23:45:33.068719692 +0200
15 LINK_FLAGS " -Wl,-dead_strip")
16 elseif(${CMAKE_SYSTEM_NAME} MATCHES "SunOS")
17 set_property(TARGET ${target_name} APPEND_STRING PROPERTY
18 - LINK_FLAGS " -Wl,-z -Wl,discard-unused=sections")
19 + LINK_FLAGS " -Wl,-z -Wl,ignore")
20 elseif(NOT WIN32 AND NOT LLVM_LINKER_IS_GOLD)
21 # Object files are compiled with -ffunction-data-sections.
22 # Versions of bfd ld < 2.23.1 have a bug in --gc-sections that breaks