2010-05-01 05:51:10 +08:00
|
|
|
##===- tools/libclang/Makefile -----------------------------*- Makefile -*-===##
|
2009-08-27 06:36:44 +08:00
|
|
|
#
|
|
|
|
# The LLVM Compiler Infrastructure
|
|
|
|
#
|
|
|
|
# This file is distributed under the University of Illinois Open Source
|
|
|
|
# License. See LICENSE.TXT for details.
|
|
|
|
#
|
|
|
|
##===----------------------------------------------------------------------===##
|
|
|
|
|
2010-06-09 04:34:18 +08:00
|
|
|
CLANG_LEVEL := ../..
|
2010-05-01 05:51:10 +08:00
|
|
|
LIBRARYNAME = clang
|
2009-08-27 06:36:44 +08:00
|
|
|
|
2010-05-01 05:51:10 +08:00
|
|
|
EXPORTED_SYMBOL_FILE = $(PROJ_SRC_DIR)/libclang.exports
|
2010-04-16 12:45:02 +08:00
|
|
|
|
2009-08-27 06:36:44 +08:00
|
|
|
LINK_LIBS_IN_SHARED = 1
|
|
|
|
SHARED_LIBRARY = 1
|
|
|
|
|
2011-02-20 07:03:58 +08:00
|
|
|
LINK_COMPONENTS := support mc
|
2011-07-10 05:35:58 +08:00
|
|
|
USEDLIBS = clangARCMigrate.a clangRewrite.a clangFrontend.a clangDriver.a \
|
|
|
|
clangSerialization.a \
|
2011-07-10 04:00:58 +08:00
|
|
|
clangParse.a clangSema.a clangAnalysis.a clangAST.a clangLex.a clangBasic.a
|
2009-08-27 06:36:44 +08:00
|
|
|
|
2010-06-09 04:34:18 +08:00
|
|
|
include $(CLANG_LEVEL)/Makefile
|
2009-08-27 06:36:44 +08:00
|
|
|
|
|
|
|
##===----------------------------------------------------------------------===##
|
|
|
|
# FIXME: This is copied from the 'lto' makefile. Should we share this?
|
|
|
|
##===----------------------------------------------------------------------===##
|
|
|
|
|
|
|
|
ifeq ($(HOST_OS),Darwin)
|
2010-08-20 07:44:02 +08:00
|
|
|
LLVMLibsOptions += -Wl,-compatibility_version,1
|
|
|
|
|
|
|
|
# Set dylib internal version number to submission number.
|
2009-08-27 06:36:44 +08:00
|
|
|
ifdef LLVM_SUBMIT_VERSION
|
2010-08-20 07:44:02 +08:00
|
|
|
LLVMLibsOptions += -Wl,-current_version \
|
|
|
|
-Wl,$(LLVM_SUBMIT_VERSION).$(LLVM_SUBMIT_SUBVERSION)
|
2009-08-27 06:36:44 +08:00
|
|
|
endif
|
2010-08-20 07:44:02 +08:00
|
|
|
|
|
|
|
# Extra options to override libtool defaults.
|
|
|
|
LLVMLibsOptions += -Wl,-dead_strip -Wl,-seg1addr,0xE0000000
|
2009-08-27 06:36:44 +08:00
|
|
|
|
|
|
|
# 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/')
|
|
|
|
ifneq ($(DARWIN_VERS),8)
|
2010-08-20 07:44:02 +08:00
|
|
|
LLVMLibsOptions += -Wl,-install_name \
|
|
|
|
-Wl,"@rpath/lib$(LIBRARYNAME)$(SHLIBEXT)"
|
2009-08-27 06:36:44 +08:00
|
|
|
endif
|
|
|
|
endif
|