-
-
Notifications
You must be signed in to change notification settings - Fork 523
Expand file tree
/
Copy pathBUILD.bazel
More file actions
48 lines (43 loc) · 1.13 KB
/
BUILD.bazel
File metadata and controls
48 lines (43 loc) · 1.13 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
package(default_visibility = ["//visibility:public"])
load("@bazel_skylib//rules:common_settings.bzl", "bool_flag")
bool_flag(
name = "ssl_enabled_flag",
build_setting_default = True,
visibility = ["//visibility:public"],
)
config_setting(
name = "ssl_enabled",
flag_values = {
"//:ssl_enabled_flag": "True",
},
)
bool_flag(
name = "compression_enabled_flag",
build_setting_default = True,
visibility = ["//visibility:public"],
)
config_setting(
name = "compression_enabled",
flag_values = {
"//:compression_enabled_flag": "True",
},
)
cc_library(
name = "crow",
hdrs = glob(["include/**/*"]),
includes = ["include"],
copts = select({
":ssl_enabled": ["-DASIO_STANDALONE", "-DCROW_ENABLE_SSL"],
"//conditions:default": [],
}) + select({
":compression_enabled": ["-DCROW_ENABLE_COMPRESSION"],
"//conditions:default": [],
}),
deps = select({
":ssl_enabled": ["@asio//:asio"],
"//conditions:default": [],
}) + select({
":compression_enabled": ["@zlib//:zlib"],
"//conditions:default": [],
}),
)