-
Notifications
You must be signed in to change notification settings - Fork 82
/
BUILD
57 lines (50 loc) · 1.16 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
load("@hedron_compile_commands//:refresh_compile_commands.bzl", "refresh_compile_commands")
package(default_visibility = ["//visibility:public"])
filegroup(
name = "srcs",
srcs = [
"iso14229.c",
"iso14229.h",
],
)
cc_library(
name="iso14229",
srcs = [
"iso14229.c",
"iso14229.h",
],
)
cc_library(
name="iso14229_2",
srcs=glob(["src/**/*.c", "src/**/*.h"]),
copts=['-Isrc'],
)
refresh_compile_commands(
name = "s32k_refresh_compile_commands",
targets = {
"//examples/s32k144/...": "--config=s32k",
}
)
py_binary(
name="amalgamate",
srcs=["amalgamate.py"],
)
genrule(
name="amalgamated",
srcs=glob(["src/**/*.c", "src/**/*.h"]),
outs=["iso14229.c", "iso14229.h"],
cmd="$(location //:amalgamate) --out_c $(location //:iso14229.c) --out_h $(location //:iso14229.h) $(SRCS)",
tools=["//:amalgamate"],
)
genrule(
name="release",
srcs=[
"iso14229.c",
"iso14229.h",
"README.md",
"LICENSE",
"AUTHORS.txt",
],
outs = ["iso14229.zip"],
cmd = "mkdir iso14229 && cp -L $(SRCS) iso14229/ && zip -r $(OUTS) iso14229",
)