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
|
|
|
|
|
2009-12-03 05:47:55 +08:00
|
|
|
LINK_COMPONENTS := bitreader mc core
|
2010-08-18 04:43:28 +08:00
|
|
|
USEDLIBS = clangFrontend.a clangDriver.a clangSerialization.a clangSema.a \
|
2010-08-18 03:00:27 +08:00
|
|
|
clangAnalysis.a clangAST.a clangParse.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)
|
|
|
|
# set dylib internal version number to llvmCore submission number
|
|
|
|
ifdef LLVM_SUBMIT_VERSION
|
|
|
|
LLVMLibsOptions := $(LLVMLibsOptions) -Wl,-current_version \
|
|
|
|
-Wl,$(LLVM_SUBMIT_VERSION).$(LLVM_SUBMIT_SUBVERSION) \
|
|
|
|
-Wl,-compatibility_version -Wl,1
|
|
|
|
endif
|
|
|
|
# extra options to override libtool defaults
|
|
|
|
LLVMLibsOptions := $(LLVMLibsOptions) \
|
|
|
|
-Wl,-dead_strip \
|
|
|
|
-Wl,-seg1addr -Wl,0xE0000000
|
|
|
|
|
|
|
|
# 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)
|
|
|
|
LLVMLibsOptions := $(LLVMLibsOptions) \
|
2010-08-01 05:33:01 +08:00
|
|
|
-Wl,-install_name \
|
2010-05-15 07:50:33 +08:00
|
|
|
-Wl,"@rpath/lib$(LIBRARYNAME)$(SHLIBEXT)"
|
2009-08-27 06:36:44 +08:00
|
|
|
endif
|
|
|
|
endif
|