Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 23 additions & 1 deletion src/viam/api/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ if (VIAMCPPSDK_USE_DYNAMIC_PROTOS)

string(REGEX MATCH "api[ \t\r\n]*commit: ([A-Za-z0-9_]*)" _ ${lockfile})
set(BUF_VIAM_API_SOURCE buf.build/viamrobotics/api:${CMAKE_MATCH_1})

string(REGEX MATCH "opentelemetry[ \t\r\n]*commit: ([A-Za-z0-9_]*)" _ ${lockfile})
set(BUF_OPENTEL_SOURCE buf.build/opentelemetry/opentelemetry:${CMAKE_MATCH_1})
endif()

set(BUF_PROTO_COMPONENTS
Expand Down Expand Up @@ -216,6 +219,18 @@ if (VIAMCPPSDK_USE_DYNAMIC_PROTOS)
${PROTO_GEN_DIR}/google/api/http.pb.h
${PROTO_GEN_DIR}/google/rpc/status.pb.cc
${PROTO_GEN_DIR}/google/rpc/status.pb.h
${PROTO_GEN_DIR}/opentelemetry/proto/common/v1/common.grpc.pb.cc
${PROTO_GEN_DIR}/opentelemetry/proto/common/v1/common.grpc.pb.h
${PROTO_GEN_DIR}/opentelemetry/proto/common/v1/common.pb.cc
${PROTO_GEN_DIR}/opentelemetry/proto/common/v1/common.pb.h
${PROTO_GEN_DIR}/opentelemetry/proto/resource/v1/resource.grpc.pb.cc
${PROTO_GEN_DIR}/opentelemetry/proto/resource/v1/resource.pb.cc
${PROTO_GEN_DIR}/opentelemetry/proto/resource/v1/resource.grpc.pb.h
${PROTO_GEN_DIR}/opentelemetry/proto/resource/v1/resource.pb.h
${PROTO_GEN_DIR}/opentelemetry/proto/trace/v1/trace.grpc.pb.cc
${PROTO_GEN_DIR}/opentelemetry/proto/trace/v1/trace.grpc.pb.h
${PROTO_GEN_DIR}/opentelemetry/proto/trace/v1/trace.pb.cc
${PROTO_GEN_DIR}/opentelemetry/proto/trace/v1/trace.pb.h
${PROTO_GEN_DIR}/module/v1/module.grpc.pb.cc
${PROTO_GEN_DIR}/module/v1/module.grpc.pb.h
${PROTO_GEN_DIR}/module/v1/module.pb.cc
Expand Down Expand Up @@ -252,6 +267,7 @@ if (VIAMCPPSDK_USE_DYNAMIC_PROTOS)
COMMAND ${BUF_COMMAND} generate ${BUF_GOOGLE_API_SOURCE} --template buf.gen.yaml --path google/rpc --path google/api
COMMAND ${BUF_COMMAND} generate ${BUF_VIAM_GOUTILS_SOURCE} --template buf.gen.yaml
COMMAND ${BUF_COMMAND} generate ${BUF_VIAM_API_SOURCE} --template buf.gen.yaml --path ${BUF_PROTO_COMPONENTS_JOINED}
COMMAND ${BUF_COMMAND} generate ${BUF_OPENTEL_SOURCE} --template buf.gen.yaml

# After generating the protos, include a step to invoke a search-and-replace for switch -> switch_ in the Switch component files
COMMAND ${CMAKE_COMMAND} "-DSWITCH_REPLACE_PATHS=\"${VIAMCPPSDK_SWITCH_REPLACE_PATHS}\"" -P ${CMAKE_CURRENT_SOURCE_DIR}/viamcppsdk_replace_switch.cmake
Expand Down Expand Up @@ -283,7 +299,7 @@ endif(VIAMCPPSDK_USE_DYNAMIC_PROTOS)

add_custom_target(
update-buf
COMMAND buf mod update ${CMAKE_CURRENT_SOURCE_DIR}
COMMAND buf dep update ${CMAKE_CURRENT_SOURCE_DIR}
)

# Declare the viamcpp library, and attach sources,
Expand Down Expand Up @@ -353,6 +369,12 @@ target_sources(viamapi
${PROTO_GEN_DIR}/google/api/http.pb.cc
${PROTO_GEN_DIR}/google/api/httpbody.pb.cc
${PROTO_GEN_DIR}/google/rpc/status.pb.cc
${PROTO_GEN_DIR}/opentelemetry/proto/common/v1/common.grpc.pb.cc
${PROTO_GEN_DIR}/opentelemetry/proto/common/v1/common.pb.cc
${PROTO_GEN_DIR}/opentelemetry/proto/resource/v1/resource.grpc.pb.cc
${PROTO_GEN_DIR}/opentelemetry/proto/resource/v1/resource.pb.cc
${PROTO_GEN_DIR}/opentelemetry/proto/trace/v1/trace.grpc.pb.cc
${PROTO_GEN_DIR}/opentelemetry/proto/trace/v1/trace.pb.cc
${PROTO_GEN_DIR}/module/v1/module.grpc.pb.cc
${PROTO_GEN_DIR}/module/v1/module.pb.cc
${PROTO_GEN_DIR}/robot/v1/robot.grpc.pb.cc
Expand Down
2 changes: 1 addition & 1 deletion src/viam/api/api_proto_tag.lock
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v0.1.497
v0.1.499
2,923 changes: 1,503 additions & 1,420 deletions src/viam/api/app/v1/app.pb.cc

Large diffs are not rendered by default.

94 changes: 94 additions & 0 deletions src/viam/api/app/v1/app.pb.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 5 additions & 1 deletion src/viam/api/buf.lock
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,12 @@ deps:
- remote: buf.build
owner: viamrobotics
repository: api
commit: fe9f6d30c9a744b0a426768683c94a55
commit: f0ff755cec224349b55e18e909ae8964
- remote: buf.build
owner: viamrobotics
repository: goutils
commit: 5fff320e3fab4611aea8180e09bcb5e5
- remote: buf.build
owner: opentelemetry
repository: opentelemetry
commit: 648a3e2f02e14fe187656ea4ac3befa1
1 change: 1 addition & 0 deletions src/viam/api/buf.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ deps:
- buf.build/googleapis/googleapis
- buf.build/viamrobotics/api
- buf.build/viamrobotics/goutils
- buf.build/opentelemetry/opentelemetry
42 changes: 42 additions & 0 deletions src/viam/api/robot/v1/robot.grpc.pb.cc

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading