[analyzer] Refactoring: lib/Checker -> lib/GR and libclangChecker -> libclangGRCore
[clang.git] / tools / driver / Makefile
blob834e238b71b28da9e3bb51d62be76210448ed4ed
1 ##===- tools/driver/Makefile -------------------------------*- Makefile -*-===##
3 # The LLVM Compiler Infrastructure
5 # This file is distributed under the University of Illinois Open Source
6 # License. See LICENSE.TXT for details.
8 ##===----------------------------------------------------------------------===##
9 CLANG_LEVEL := ../..
11 TOOLNAME = clang
12 ifndef CLANG_IS_PRODUCTION
13 TOOLALIAS = clang++
14 else
15 ifdef CLANGXX_IS_PRODUCTION
16 TOOLALIAS = clang++
17 endif
18 endif
20 # We don't currently expect production Clang builds to be interested in
21 # plugins. This is important for startup performance.
22 ifdef CLANG_IS_PRODUCTION
23 TOOL_NO_EXPORTS := 1
24 endif
26 ifdef CLANG_ORDER_FILE
27 TOOL_ORDER_FILE := $(CLANG_ORDER_FILE)
28 endif
30 # Include tool version information on OS X.
31 TOOL_INFO_PLIST := Info.plist
33 # Include this here so we can get the configuration of the targets that have
34 # been configured for construction. We have to do this early so we can set up
35 # LINK_COMPONENTS before including Makefile.rules
36 include $(CLANG_LEVEL)/../../Makefile.config
38 LINK_COMPONENTS := $(TARGETS_TO_BUILD) asmparser bitreader bitwriter codegen \
39 ipo selectiondag
40 USEDLIBS = clangFrontendTool.a clangFrontend.a clangDriver.a \
41 clangSerialization.a clangCodeGen.a clangParse.a clangSema.a \
42 clangGRCore.a clangAnalysis.a clangIndex.a clangRewrite.a \
43 clangAST.a clangLex.a clangBasic.a
45 include $(CLANG_LEVEL)/Makefile
47 # Set the tool version information values.
48 ifeq ($(HOST_OS),Darwin)
49 ifdef CLANG_VENDOR
50 TOOL_INFO_NAME := $(CLANG_VENDOR) clang
51 else
52 TOOL_INFO_NAME := clang
53 endif
55 ifdef CLANG_VENDOR_UTI
56 TOOL_INFO_UTI := $(CLANG_VENDOR_UTI)
57 else
58 TOOL_INFO_UTI := org.llvm.clang
59 endif
61 TOOL_INFO_VERSION := $(word 3,$(shell grep "CLANG_VERSION " \
62 $(PROJ_OBJ_DIR)/$(CLANG_LEVEL)/include/clang/Basic/Version.inc))
63 ifdef LLVM_SUBMIT_VERSION
64 TOOL_INFO_BUILD_VERSION := $(LLVM_SUBMIT_VERSION).$(LLVM_SUBMIT_SUBVERSION)
65 else
66 TOOL_INFO_BUILD_VERSION :=
67 endif
68 endif
70 # Translate make variable to define when building a "production" clang.
71 ifdef CLANG_IS_PRODUCTION
72 CPP.Defines += -DCLANG_IS_PRODUCTION
73 endif
74 ifdef CLANGXX_IS_PRODUCTION
75 CPP.Defines += -DCLANGXX_IS_PRODUCTION
76 endif