-
Notifications
You must be signed in to change notification settings - Fork 0
/
BUILD
33 lines (28 loc) · 762 Bytes
/
BUILD
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
load("@rules_cc//cc:defs.bzl", "cc_test")
constraint_setting(name = "test_constraint")
constraint_value(
name = "test_constraint_value",
constraint_setting = ":test_constraint",
)
platform(
name = "test_platform_no_constraint",
exec_properties = {
"exec_property": "no_constraint",
},
parents = ["@local_config_platform//:host"],
)
platform(
name = "test_platform_with_constraint",
constraint_values = [
":test_constraint_value",
],
exec_properties = {
"exec_property": "requires_test_constraint",
},
parents = ["@local_config_platform//:host"],
)
cc_test(
name = "test_requiring_test_constraint_value",
srcs = ["main.cc"],
exec_compatible_with = [":test_constraint_value"]
)