Skip to content

Commit 337f761

Browse files
fix docker build failure: add allow_empty to true (#3526)
1 parent 4da1528 commit 337f761

File tree

3 files changed

+43
-15
lines changed

3 files changed

+43
-15
lines changed

docker/MODULE.bazel.docker

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ module(
44
version = "${BUILD_VERSION}"
55
)
66

7-
bazel_dep(name = "googletest", version = "1.14.0")
8-
bazel_dep(name = "platforms", version = "0.0.10")
9-
bazel_dep(name = "rules_cc", version = "0.0.9")
10-
bazel_dep(name = "rules_python", version = "0.34.0")
7+
bazel_dep(name = "googletest", version = "1.16.0")
8+
bazel_dep(name = "platforms", version = "0.0.11")
9+
bazel_dep(name = "rules_cc", version = "0.1.1")
10+
bazel_dep(name = "rules_python", version = "1.3.0")
1111

1212
python = use_extension("@rules_python//python/extensions:python.bzl", "python")
1313
python.toolchain(

third_party/tensorrt/archive/BUILD

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ config_setting(
88
"@platforms//cpu:aarch64",
99
],
1010
flag_values = {
11-
"@//toolchains/dep_collection:compute_libs": "jetpack"
11+
"@//toolchains/dep_collection:compute_libs": "jetpack",
1212
},
1313
)
1414

@@ -25,6 +25,7 @@ cc_library(
2525
[
2626
"include/NvInfer*.h",
2727
],
28+
allow_empty = True,
2829
exclude = [
2930
"include/NvInferPlugin.h",
3031
"include/NvInferPluginUtils.h",
@@ -59,8 +60,14 @@ cc_library(
5960
"nvinfer_headers",
6061
"nvinfer_lib",
6162
] + select({
62-
":windows": ["@cuda_win//:cudart", "nvinfer_static_lib"],
63-
":jetpack": ["@cuda_l4t//:cudart", "nvinfer_static_lib"],
63+
":jetpack": [
64+
"nvinfer_static_lib",
65+
"@cuda_l4t//:cudart",
66+
],
67+
":windows": [
68+
"nvinfer_static_lib",
69+
"@cuda_win//:cudart",
70+
],
6471
"//conditions:default": ["@cuda//:cudart"],
6572
}),
6673
)
@@ -195,15 +202,18 @@ cc_library(
195202
":windows": ["lib/nvinfer_plugin_10.lib"],
196203
"//conditions:default": ["lib/libnvinfer_plugin.so"],
197204
}),
198-
hdrs = glob(["include/NvInferPlugin*.h"]),
199-
copts = ["-pthread",],
205+
hdrs = glob(
206+
["include/NvInferPlugin*.h"],
207+
allow_empty = True,
208+
),
209+
copts = ["-pthread"],
200210
includes = ["include/"],
201211
linkopts = ["-lpthread"],
202212
deps = [
203213
"nvinfer",
204214
] + select({
205-
":windows": ["@cuda_win//:cudart"],
206215
":jetpack": ["@cuda_l4t//:cudart"],
216+
":windows": ["@cuda_win//:cudart"],
207217
"//conditions:default": ["@cuda//:cudart"],
208218
}),
209219
alwayslink = True,

third_party/tensorrt/local/BUILD

Lines changed: 23 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ cc_library(
3333
[
3434
"include/aarch64-linux-gnu/NvInfer*.h",
3535
],
36+
allow_empty = True,
3637
exclude = [
3738
"include/aarch64-linux-gnu/NvInferPlugin.h",
3839
"include/aarch64-linux-gnu/NvInferPluginUtils.h",
@@ -42,6 +43,7 @@ cc_library(
4243
[
4344
"include/NvInfer*.h",
4445
],
46+
allow_empty = True,
4547
exclude = [
4648
"include/NvInferPlugin.h",
4749
"include/NvInferPluginUtils.h",
@@ -51,6 +53,7 @@ cc_library(
5153
[
5254
"include/NvInfer*.h",
5355
],
56+
allow_empty = True,
5457
exclude = [
5558
"include/NvInferPlugin.h",
5659
"include/NvInferPluginUtils.h",
@@ -104,7 +107,10 @@ cc_library(
104107
"nvinfer_headers",
105108
"nvinfer_lib",
106109
] + select({
107-
":windows": ["@cuda_win//:cudart", "nvinfer_static_lib"],
110+
":windows": [
111+
"nvinfer_static_lib",
112+
"@cuda_win//:cudart",
113+
],
108114
"//conditions:default": ["@cuda//:cudart"],
109115
}),
110116
)
@@ -336,10 +342,22 @@ cc_library(
336342
"//conditions:default": ["lib/x86_64-linux-gnu/libnvinfer_plugin.so"],
337343
}),
338344
hdrs = select({
339-
":aarch64_linux": glob(["include/aarch64-linux-gnu/NvInferPlugin*.h"]),
340-
":ci_rhel_x86_64_linux": glob(["include/NvInferPlugin*.h"]),
341-
":windows": glob(["include/NvInferPlugin*.h"]),
342-
"//conditions:default": glob(["include/x86_64-linux-gnu/NvInferPlugin*.h"]),
345+
":aarch64_linux": glob(
346+
["include/aarch64-linux-gnu/NvInferPlugin*.h"],
347+
allow_empty = True,
348+
),
349+
":ci_rhel_x86_64_linux": glob(
350+
["include/NvInferPlugin*.h"],
351+
allow_empty = True,
352+
),
353+
":windows": glob(
354+
["include/NvInferPlugin*.h"],
355+
allow_empty = True,
356+
),
357+
"//conditions:default": glob(
358+
["include/x86_64-linux-gnu/NvInferPlugin*.h"],
359+
allow_empty = True,
360+
),
343361
}),
344362
copts = [
345363
"-pthread",

0 commit comments

Comments
 (0)