Debian Codegraph @

build/clang-plugin/Makefile.in

raw
1 # This Source Code Form is subject to the terms of the Mozilla Public
2 # License, v. 2.0. If a copy of the MPL was not distributed with this
3 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
4
5 include $(topsrcdir)/config/config.mk
6
7 HOST_LDFLAGS += $(LLVM_LDFLAGS)
8
9 ifeq ($(HOST_OS_ARCH),Darwin)
10 # We need to make sure that we use the symbols coming from the clang
11 # binary. In order to do this, we need to pass -flat_namespace and
12 # -undefined suppress to the linker. This makes sure that we link the
13 # symbols into the flat namespace provided by clang, and thus get
14 # access to all of the symbols which are undefined in our dylib as we
15 # are building it right now, and also that we don't fail the build
16 # due to undefined symbols (which will be provided by clang).
17 HOST_LDFLAGS += -Wl,-flat_namespace -Wl,-undefined,suppress
18 endif
19
20 ifeq ($(HOST_OS_ARCH),WINNT)
21 # clang-plugin.dll needs to be deterministic for sccache hashes
22 HOST_LDFLAGS += -brepro
23 else
24 HOST_LDFLAGS += -shared
25 endif