-
Notifications
You must be signed in to change notification settings - Fork 68
/
BUILD
117 lines (104 loc) · 2.75 KB
/
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
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
load("@rules_cc//cc:defs.bzl", "cc_library", "cc_proto_library")
load("@rules_proto//proto:defs.bzl", "proto_library")
licenses(["notice"]) # Apache 2
package(default_visibility = ["//visibility:public"])
exports_files(["LICENSE"])
cc_library(
name = "api_lib",
hdrs = [
"proxy_wasm_api.h",
"proxy_wasm_externs.h",
],
copts = ["-std=c++17"],
deps = [
":common_lib",
"@com_google_protobuf//:protobuf_lite",
],
)
cc_library(
name = "common_lib",
hdrs = [
"proxy_wasm_common.h",
"proxy_wasm_enums.h",
],
copts = ["-std=c++17"],
)
cc_library(
name = "proxy_wasm_intrinsics",
srcs = [
"proxy_wasm_intrinsics.cc",
],
hdrs = [
"proxy_wasm_api.h",
"proxy_wasm_common.h",
"proxy_wasm_enums.h",
"proxy_wasm_externs.h",
"proxy_wasm_intrinsics.h",
],
copts = ["-std=c++17"],
visibility = ["//visibility:public"],
)
cc_proto_library(
name = "proxy_wasm_intrinsics_cc_proto",
deps = [":proxy_wasm_intrinsics_proto"],
)
proto_library(
name = "proxy_wasm_intrinsics_proto",
srcs = ["proxy_wasm_intrinsics.proto"],
deps = [
"@com_google_protobuf//:any_proto",
"@com_google_protobuf//:duration_proto",
"@com_google_protobuf//:empty_proto",
"@com_google_protobuf//:struct_proto",
],
)
# include lite protobuf support
cc_library(
name = "proxy_wasm_intrinsics_lite",
hdrs = ["proxy_wasm_intrinsics_lite.h"],
copts = ["-std=c++17"],
defines = ["PROXY_WASM_PROTOBUF_LITE"],
visibility = ["//visibility:public"],
deps = [
":proxy_wasm_intrinsics",
":proxy_wasm_intrinsics_lite_cc_proto",
"@com_google_protobuf//:protobuf_lite",
],
)
# include full protobuf support
cc_library(
name = "proxy_wasm_intrinsics_full",
hdrs = ["proxy_wasm_intrinsics_full.h"],
copts = ["-std=c++17"],
defines = ["PROXY_WASM_PROTOBUF_FULL"],
visibility = ["//visibility:public"],
deps = [
":proxy_wasm_intrinsics",
":proxy_wasm_intrinsics_cc_proto",
"@com_google_protobuf//:protobuf",
],
)
cc_proto_library(
name = "proxy_wasm_intrinsics_lite_cc_proto",
deps = [":proxy_wasm_intrinsics_lite_proto"],
)
proto_library(
name = "proxy_wasm_intrinsics_lite_proto",
srcs = [
"proxy_wasm_intrinsics_lite.proto",
"struct_lite.proto",
],
deps = [
"@com_google_protobuf//:any_proto",
"@com_google_protobuf//:duration_proto",
"@com_google_protobuf//:empty_proto",
"@com_google_protobuf//:struct_proto",
],
)
filegroup(
name = "proxy_wasm_intrinsics_js",
srcs = [
"proxy_wasm_intrinsics.js",
],
visibility = ["//visibility:public"],
)