1################################################################################ 2# 3# lld 4# 5################################################################################ 6 7# LLVM, Clang and lld should be version bumped together 8LLD_VERSION = 9.0.1 9LLD_SITE = https://github.com/llvm/llvm-project/releases/download/llvmorg-$(LLD_VERSION) 10LLD_SOURCE = lld-$(LLD_VERSION).src.tar.xz 11LLD_LICENSE = Apache-2.0 with exceptions 12LLD_LICENSE_FILES = LICENSE.TXT 13LLD_SUPPORTS_IN_SOURCE_BUILD = NO 14HOST_LLD_DEPENDENCIES = host-llvm 15 16# LLVM > 9.0 will soon require C++14 support, building llvm <= 9.0 using a 17# toolchain using gcc < 5.1 gives an error but actually still works. Setting 18# this option makes it still build with gcc >= 4.8. 19# https://reviews.llvm.org/D57264 20HOST_LLD_CONF_OPTS += -DLLVM_TEMPORARILY_ALLOW_OLD_TOOLCHAIN=ON 21 22# build as static libs as is done in llvm & clang 23HOST_LLD_CONF_OPTS += -DBUILD_SHARED_LIBS=OFF 24 25# GCC looks for tools in a different path from LLD's default installation path 26define HOST_LLD_CREATE_SYMLINKS 27 mkdir -p $(HOST_DIR)/$(GNU_TARGET_NAME)/bin 28 ln -sf $(HOST_DIR)/bin/lld $(HOST_DIR)/$(GNU_TARGET_NAME)/bin/lld 29 ln -sf $(HOST_DIR)/bin/lld $(HOST_DIR)/$(GNU_TARGET_NAME)/bin/ld.lld 30endef 31 32HOST_LLD_POST_INSTALL_HOOKS += HOST_LLD_CREATE_SYMLINKS 33 34$(eval $(host-cmake-package)) 35