Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Add "native" to config.available_features, to make it easier to disab…

…le non-x-compile-safe tests

Patch by Artyom Skrobov!

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@190681 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information...
commit 09098596c92e4d1c1d172988e48144d49a9705a0 1 parent ac885cd
Amaury de la Vieuville authored
2  test/Index/cindex-from-source.m
... ... @@ -1,4 +1,4 @@
1   -
  1 +// REQUIRES: native
2 2 // RUN: %clang -x objective-c-header %S/Inputs/cindex-from-source.h -o %t.pfx.h.gch
3 3 // RUN: c-index-test -test-load-source local %s -include %t.pfx.h > %t
4 4 // RUN: FileCheck %s < %t
2  test/Index/complete-pch.m
@@ -11,6 +11,8 @@ void msg_id(id x) {
11 11 [x instanceMethod1:5];
12 12 }
13 13
  14 +// REQUIRES: native
  15 +
14 16 // Build the precompiled header
15 17 // RUN: %clang -x objective-c-header -o %t.h.pch %S/Inputs/complete-pch.h
16 18
4 test/lit.cfg
@@ -256,6 +256,10 @@ if not platform.system() in ['Windows'] or not execute_external:
256 256 if platform.system() not in ['Windows']:
257 257 config.available_features.add('ansi-escape-sequences')
258 258
  259 +# Native compilation: host arch == target arch
  260 +if config.host_arch in config.target_triple:
  261 + config.available_features.add("native")
  262 +
259 263 # Case-insensitive file system
260 264 def is_filesystem_case_insensitive():
261 265 handle, path = tempfile.mkstemp(prefix='case-test', dir=config.test_exec_root)
1  test/lit.site.cfg.in
@@ -13,6 +13,7 @@ config.llvm_use_sanitizer = "@LLVM_USE_SANITIZER@"
13 13 config.clang_arcmt = @ENABLE_CLANG_ARCMT@
14 14 config.clang_staticanalyzer = @ENABLE_CLANG_STATIC_ANALYZER@
15 15 config.clang_rewriter = @ENABLE_CLANG_REWRITER@
  16 +config.host_arch = "@HOST_ARCH@"
16 17
17 18 # Support substitution of the tools and libs dirs with user parameters. This is
18 19 # used when we can't determine the tool dir at configuration time.

0 comments on commit 0909859

Please sign in to comment.
Something went wrong with that request. Please try again.