Skip to content

Commit

Permalink
Don't concatenate paths in --proto_path (#109)
Browse files Browse the repository at this point in the history
`protoc`'s `--proto_path` argument is expected to be provided multiple
times if multiple directories are to be considered. Concatenating with
`:` is invalid on some systems (Windows):

```sh
> protoc --help
  -IPATH, --proto_path=PATH   Specify the directory in which to search for
                              imports.  May be specified multiple times;
                              directories will be searched in order.  If not
                              given, the current working directory is used.
                              If not found in any of the these directories,
                              the --descriptor_set_in descriptors will be
                              checked for required proto file.
```
  • Loading branch information
mortbopet committed Sep 4, 2024
1 parent 8c8350c commit 9737507
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/substrait/proto/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,8 @@ foreach(PROTO_FILE IN LISTS PROTOBUF_FILELIST)
add_custom_command(
OUTPUT ${PROTO_SRC} ${PROTO_HDR}
COMMAND
protobuf::protoc
"--proto_path=${GENERATED_PROTO_TOPLEVEL_DIR}:${protobuf_SOURCE_DIR}/src"
protobuf::protoc "--proto_path=${GENERATED_PROTO_TOPLEVEL_DIR}"
"--proto_path=${protobuf_SOURCE_DIR}/src"
"--cpp_out=${PROTO_OUTPUT_MIDLEVEL_DIR}" ${GENERATED_PROTO_FILE}
DEPENDS ${GENERATED_PROTOBUF_LIST} protobuf::protoc
COMMENT "Generated C++ protobuf module for ${PROTO_FILE}"
Expand Down

0 comments on commit 9737507

Please sign in to comment.