1LOCAL_PATH := $(call my-dir) 2 3LLVM_ROOT_PATH := $(LOCAL_PATH)/../.. 4 5 6#===---------------------------------------------------------------=== 7# llvm-ar command line tool 8#===---------------------------------------------------------------=== 9 10llvm_ar_SRC_FILES := \ 11 llvm-ar.cpp 12 13include $(CLEAR_VARS) 14 15LOCAL_MODULE := llvm-ar 16LOCAL_MODULE_TAGS := optional 17LOCAL_MODULE_CLASS := EXECUTABLES 18LOCAL_IS_HOST_MODULE := true 19 20LOCAL_SRC_FILES := $(llvm_ar_SRC_FILES) 21 22LOCAL_SHARED_LIBRARIES := libLLVM 23 24LOCAL_LDLIBS += -lpthread -lm -ldl 25 26include $(LLVM_ROOT_PATH)/llvm.mk 27include $(LLVM_HOST_BUILD_MK) 28include $(BUILD_HOST_EXECUTABLE) 29 30LLVM_RANLIB = $(HOST_OUT)/bin/llvm-ranlib 31 32# Make sure if llvm-ar (i.e. $(LOCAL_MODULE)) get installed, 33# llvm-ranlib will get installed as well. 34ALL_MODULES.$(LOCAL_MODULE).INSTALLED := \ 35 $(ALL_MODULES.$(LOCAL_MODULE).INSTALLED) $(LLVM_RANLIB) 36# the additional dependency is needed when you run mm/mmm. 37$(LOCAL_MODULE) : $(LLVM_RANLIB) 38 39# Symlink for llvm-ranlib 40$(LLVM_RANLIB) : $(LOCAL_INSTALLED_MODULE) 41 @echo "Symlink $@ -> $<" 42 $(hide) ln -sf $(notdir $<) $@ 43