diff --git a/debian/changelog b/debian/changelog index 19e3ca30..3f377274 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +llvm-toolchain-4.0 (1:5.0-1~exp2) UNRELEASED; urgency=medium + + [ Matthias Klose ] + * Link with --no-keep-files-mapped --no-map-whole-files when using gold. + + -- Sylvestre Ledru Fri, 08 Sep 2017 11:59:03 +0200 + llvm-toolchain-4.0 (1:4.0.1-4) unstable; urgency=medium * Fail the build if the arch + gcc has a broken gsplit-dwarf support diff --git a/debian/rules b/debian/rules index 7a85ef18..a737dc98 100755 --- a/debian/rules +++ b/debian/rules @@ -86,8 +86,8 @@ BINUTILS_GOLD_ARCHS := amd64 armhf i386 powerpcspe ppc64 ppc64el sparc sparc64 x ifeq ($(shell dpkg --compare-versions $(shell dpkg-query -W -f '$${Version}' binutils) ge 2.23.1-1~exp3 ; echo $$?),0) ifneq (,$(filter $(DEB_HOST_ARCH),$(BINUTILS_GOLD_ARCHS))) # -fused-ld=gold enables the gold linker (but is not supported by all archs / distro) - LDFLAGS_EXTRA += -fuse-ld=gold - CXXFLAGS_EXTRA += -Wl,-fuse-ld=gold + LDFLAGS_EXTRA += -fuse-ld=gold --no-keep-files-mapped --no-map-whole-files + CXXFLAGS_EXTRA += -Wl,-fuse-ld=gold -Wl,--no-keep-files-mapped -Wl,--no-map-whole-files CMAKE_EXTRA += -DLLVM_BINUTILS_INCDIR=/usr/include/ endif endif