-
Notifications
You must be signed in to change notification settings - Fork 117
Expand file tree
/
Copy pathBUILD.bazel
More file actions
144 lines (121 loc) · 3.05 KB
/
BUILD.bazel
File metadata and controls
144 lines (121 loc) · 3.05 KB
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
config_setting(
name = "build_macos",
constraint_values = [
"@platforms//os:osx",
],
)
config_setting(
name = "debug_build_macos",
constraint_values = [
"@platforms//os:osx",
],
values = {"compilation_mode": "dbg"},
)
config_setting(
name = "build_linux",
constraint_values = [
"@platforms//os:linux",
],
)
config_setting(
name = "debug_build_linux",
constraint_values = [
"@platforms//os:linux",
],
values = {"compilation_mode": "dbg"},
)
config_setting(
name = "build_windows",
constraint_values = [
"@platforms//os:windows",
],
)
config_setting(
name = "debug_build_windows",
constraint_values = [
"@platforms//os:windows",
],
values = {"compilation_mode": "dbg"},
)
config_setting(
name = "debug_all",
define_values = {"debug_all": "true"},
)
# Enable DDS_SCHEDULER via --define=scheduler=true
config_setting(
name = "scheduler",
define_values = {"scheduler": "true"},
)
# Enable DDS_TT_CONTEXT_OWNERSHIP via --define=tt_context_ownership=true
config_setting(
name = "tt_context_ownership",
define_values = {"tt_context_ownership": "true"},
)
# Enable DDS_DEBUG_TT_RESET via --define=tt_reset_debug=true
config_setting(
name = "tt_reset_debug",
define_values = {"tt_reset_debug": "true"},
)
# Enable AddressSanitizer via --define=asan=true
config_setting(
name = "asan",
define_values = {"asan": "true"},
)
# WebAssembly (WASM) build configuration
# Usage: bazel build --config=wasm //...
config_setting(
name = "build_wasm",
values = {"cpu": "wasm"},
)
load("@rules_cc//cc:defs.bzl", "cc_library")
genrule(
name = "doxygen_docs",
srcs = ["Doxyfile"],
outs = ["doxygen_docs.zip"],
cmd = """
set -e
DOXYFILE_GEN="$(@D)/Doxyfile.generated"
OUT_DIR="$(@D)/doxygen_output"
OUT_ZIP="$$(pwd)/$@"
if ! command -v doxygen >/dev/null 2>&1; then
echo "doxygen_docs is a manual developer-only target and requires 'doxygen' on PATH" >&2
exit 1
fi
if ! command -v zip >/dev/null 2>&1; then
echo "doxygen_docs is a manual developer-only target and requires 'zip' on PATH" >&2
exit 1
fi
rm -rf "$$OUT_DIR"
cat > "$$DOXYFILE_GEN" <<'EOF'
@INCLUDE = $(location Doxyfile)
OUTPUT_DIRECTORY = $(@D)/doxygen_output
EOF
doxygen "$$DOXYFILE_GEN"
test -f "$$OUT_DIR/html/index.html"
cd "$$OUT_DIR"
zip -rq "$$OUT_ZIP" html
""",
local = 1,
output_to_bindir = True,
tags = [
"manual",
"local",
"no-remote",
"no-remote-cache",
],
)
cc_library(
name = "dds",
deps = ["//library/src:dds"],
visibility = ["//visibility:public"],
)
cc_library(
name = "testable_dds",
deps = ["//library/src:testable_dds"],
visibility = [
"//library/tests:__pkg__",
"//library/tests/regression/heuristic_sorting:__pkg__",
"//library/tests/heuristic_sorting:__pkg__",
"//library/tests/system:__pkg__",
],
)