Skip to content

Commit 31d11db

Browse files
committed
Starting this from scratch
-) Basic workspace -) Basic BUILD file with macros
1 parent 70ee74c commit 31d11db

File tree

7 files changed

+250
-2083
lines changed

7 files changed

+250
-2083
lines changed

.gitignore

+7
Original file line numberDiff line numberDiff line change
@@ -103,3 +103,10 @@ artifacts/
103103

104104
# IDE specific folder for JetBrains IDEs
105105
.idea/
106+
107+
# Blaze files
108+
bazel-bin
109+
bazel-genfiles
110+
bazel-grpc
111+
bazel-out
112+
bazel-testlogs

BUILD

+132-1,826
Large diffs are not rendered by default.

WORKSPACE

+42
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
bind(
2+
name = "nanopb",
3+
actual = "//third_party/nanopb",
4+
)
5+
6+
bind(
7+
name = "libssl",
8+
actual = "@submodule_boringssl//:ssl",
9+
)
10+
11+
bind(
12+
name = "zlib",
13+
actual = "@submodule_zlib//:z",
14+
)
15+
16+
bind(
17+
name = "protobuf_clib",
18+
actual = "@submodule_protobuf//:protoc_lib",
19+
)
20+
21+
bind(
22+
name = "protobuf_compiler",
23+
actual = "@submodule_protobuf//:protoc_lib",
24+
)
25+
26+
new_local_repository(
27+
name = "submodule_boringssl",
28+
path = "third_party/boringssl",
29+
build_file = "third_party/boringssl/BUILD",
30+
)
31+
32+
new_local_repository(
33+
name = "submodule_zlib",
34+
path = "third_party/zlib",
35+
build_file = "third_party/zlib.BUILD",
36+
)
37+
38+
new_local_repository(
39+
name = "submodule_protobuf",
40+
path = "third_party/protobuf",
41+
build_file = "third_party/protobuf/BUILD",
42+
)

grpc-build-system.bzl

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
def grpc_cc_library(name, srcs = [], hdrs = [], deps = [], standalone = False, language = "C++"):
2+
copts = []
3+
if language == "C":
4+
copts = ["-std=c99"]
5+
native.cc_library(
6+
name = name,
7+
srcs = srcs,
8+
hdrs = hdrs,
9+
deps = deps,
10+
copts = copts,
11+
includes = [
12+
"include"
13+
]
14+
)
15+
16+
17+
def nanopb():
18+
native.cc_library(
19+
name = "nanopb",
20+
srcs = [
21+
'//third_party/nanopb/pb_common.c',
22+
'//third_party/nanopb/pb_decode.c',
23+
'//third_party/nanopb/pb_encode.c',
24+
],
25+
hdrs = [
26+
'//third_party/nanopb/pb.h',
27+
'//third_party/nanopb/pb_common.h',
28+
'//third_party/nanopb/pb_decode.h',
29+
'//third_party/nanopb/pb_encode.h',
30+
]
31+
)

templates/BUILD.template

-256
This file was deleted.

third_party/boringssl

Submodule boringssl updated 3715 files

third_party/zlib.BUILD

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
cc_library(
2+
name = "z",
3+
linkstatic = 1,
4+
srcs = [
5+
'adler32.c',
6+
'compress.c',
7+
'crc32.c',
8+
'deflate.c',
9+
'infback.c',
10+
'inffast.c',
11+
'inflate.c',
12+
'inftrees.c',
13+
'trees.c',
14+
'uncompr.c',
15+
'zutil.c',
16+
],
17+
hdrs = [
18+
'crc32.h',
19+
'deflate.h',
20+
'gzguts.h',
21+
'inffast.h',
22+
'inffixed.h',
23+
'inflate.h',
24+
'inftrees.h',
25+
'trees.h',
26+
'zconf.h',
27+
'zlib.h',
28+
'zutil.h',
29+
],
30+
includes = [
31+
'include',
32+
],
33+
visibility = [
34+
"//visibility:public",
35+
],
36+
)
37+

0 commit comments

Comments
 (0)