-
Notifications
You must be signed in to change notification settings - Fork 615
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[wpiutil] Change C++ protobuf to nanopb #7309
Conversation
65d5b5a
to
5024562
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By convention, the generated
folder hierarchy mirrors the folder hierarchy in main
, so the generated files should go under src/generated/main/native/cpp
instead of src/generated/main/cpp
.
wpiutil/src/main/native/include/wpi/protobuf/ProtobufCallbacks.h
Outdated
Show resolved
Hide resolved
Here's a patch that should fix Bazel: diff --git a/wpiutil/BUILD.bazel b/wpiutil/BUILD.bazel
index 0a97abe53..33760ee47 100644
--- a/wpiutil/BUILD.bazel
+++ b/wpiutil/BUILD.bazel
@@ -225,6 +225,14 @@ cc_library(
visibility = ["//visibility:public"],
)
+cc_library(
+ name = "nanopb-test-headers",
+ hdrs = glob(["src/generated/test/native/cpp/*.h"]),
+ includes = ["src/generated/test/native/cpp"],
+ strip_include_prefix = "src/generated/test/native/cpp",
+ visibility = ["//wpiutil:__subpackages__"],
+)
+
cc_test(
name = "wpiutil-cpp-test",
size = "small",
@@ -237,6 +245,7 @@ cc_test(
deps = [
":wpiutil.static",
":wpiutil-testlib",
+ ":nanopb-test-headers",
"//thirdparty/googletest:googletest.static",
],
)
|
I tested @Gold856 patch locally and he is correct |
/format |
/format |
remove java | ||
} | ||
return | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How is this used?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was needed because wpiutil only had protobufs in the test, and the google protobufs were erroring for some reason.
I’ll be removing all of this Infra in a future pr. This pr was just already so big it wasn’t worth it.
No description provided.