From 34048d2cf1c6a917ab45e068fca2352e3b42c55e Mon Sep 17 00:00:00 2001 From: Johan Engelen Date: Sat, 22 Dec 2018 22:03:21 +0100 Subject: [PATCH] Add internal_lld Lit-test feature. (#2952) This prevents test failures when LDC is built without internal LLD. --- tests/linking/link_internally.d | 1 + tests/lit.site.cfg.in | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/tests/linking/link_internally.d b/tests/linking/link_internally.d index fdcddec4d40..cd12f02b93a 100644 --- a/tests/linking/link_internally.d +++ b/tests/linking/link_internally.d @@ -1,4 +1,5 @@ // REQUIRES: Windows +// REQUIRES: internal_lld // RUN: %ldc -link-internally -run %s diff --git a/tests/lit.site.cfg.in b/tests/lit.site.cfg.in index f6e0a4bd722..9752b9ff5af 100644 --- a/tests/lit.site.cfg.in +++ b/tests/lit.site.cfg.in @@ -25,6 +25,7 @@ config.dynamic_compile = @LDC_DYNAMIC_COMPILE@ config.plugins_supported = "@LDC_ENABLE_PLUGINS@" == "ON" config.gnu_make_bin = "@GNU_MAKE_BIN@" config.ldc_host_arch = "@LDC_HOST_ARCH@" +config.ldc_with_lld = "@LDC_WITH_LLD@" config.name = 'LDC' @@ -124,6 +125,9 @@ elif (platform.system() == 'Windows'): if canDoLTO: config.available_features.add('LTO') +if config.ldc_with_lld: + config.available_features.add('internal_lld') + config.target_triple = '(unused)' # test_exec_root: The root path where tests should be run.