Skip to content

Commit b190614

Browse files
committed
bazel: local more stuff
Signed-off-by: Øyvind Harboe <[email protected]>
1 parent 2317e4a commit b190614

File tree

4 files changed

+63
-3
lines changed

4 files changed

+63
-3
lines changed

flow/BUILD.bazel

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,60 @@
1+
load("@bazel-orfs//:openroad.bzl", "orfs_pdk")
2+
13
MAKEFILE_SHARED = [
24
"scripts/*.py",
35
"scripts/*.sh",
46
"scripts/*.yaml",
57
"scripts/*.mk",
68
]
79

10+
filegroup(
11+
name = "makefile_yosys",
12+
srcs = ["Makefile"],
13+
data = glob(MAKEFILE_SHARED + [
14+
"scripts/*.script",
15+
"scripts/util.tcl",
16+
"scripts/synth*.tcl",
17+
"platforms/common/**/*.v",
18+
]) +
19+
["//util:makefile_yosys"],
20+
visibility = ["//visibility:public"],
21+
)
22+
23+
824
# The files used in the flow steps(floorplan, place, route, etc.)
925
filegroup(
1026
name = "makefile",
1127
srcs = ["Makefile"],
1228
data = glob(MAKEFILE_SHARED + [
1329
"scripts/*.tcl",
30+
"platforms/common/**/*.v",
1431
]) + [
1532
"//util:makefile",
1633
],
1734
visibility = ["//visibility:public"],
1835
)
36+
37+
[orfs_pdk(
38+
name = pdk,
39+
config = ":platforms/{pdk}/config.mk".format(pdk = pdk),
40+
srcs = glob([
41+
"platforms/{pdk}/**/*.{ext}".format(pdk = pdk, ext = ext)
42+
for ext in [
43+
"gds",
44+
"lib.gz",
45+
"lef",
46+
"lib",
47+
"lyt",
48+
"mk",
49+
"rules",
50+
"sdc",
51+
"tcl",
52+
"v",
53+
"tlef",
54+
]
55+
]),
56+
visibility = ["//visibility:public"],
57+
) for pdk in [
58+
"asap7",
59+
"sky130hd",
60+
]]

flow/MODULE.bazel

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,8 @@ orfs.default(
5454
image = "docker.io/openroad/orfs:v3.0-2734-gcf6f0417",
5555
# Use local files instead of docker image
5656
makefile = "//:makefile",
57+
pdk = "//:asap7",
58+
makefile_yosys = "//:makefile_yosys",
5759
# image = "gcr.io/ascenium/orfs-megaboom/flow-ubuntu22.04-builder:3d2c3d-2",
5860
sha256 = "ef685898a5e3a2db7166c55238275adcf2dbec7ee0a7eb895a78657bcc27220a",
5961
)

flow/MODULE.bazel.lock

Lines changed: 10 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flow/util/BUILD.bazel

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,3 +31,12 @@ filegroup(
3131
]),
3232
visibility = ["//visibility:public"],
3333
)
34+
35+
filegroup(
36+
name = "makefile_yosys",
37+
srcs = glob(MAKEFILE_SHARED) + [
38+
"preprocessLib.py",
39+
"mergeLib.pl",
40+
],
41+
visibility = ["//visibility:public"],
42+
)

0 commit comments

Comments
 (0)