Skip to content

Commit d5e9e13

Browse files
zanmato1984kou
andauthored
GH-40751: [C++] Fix protobuf package name setting for builds with substrait (#40753)
### Rationale for this change The problem #40751 seems to be introduced by #40399. Though I'm not entirely sure about the purpose of that, it seems to be missing an `OR ARROW_SUBSTRAIT` in the `if` branch in 5baca0f#diff-5cdc95f4e1b618f2f3ef10d370ce05a1ac05d9d401aecff3ccbb3d76bd366b6aR1815 Because other than `ARROW_ORC`, `ARROW_WITH_OPENTELEMETRY` and `ARROW_FLIGHT`, `ARROW_SUBSTRAIT` also implies `ARROW_WITH_PROTOBUF`: https://github.com/apache/arrow/blob/5baca0f16e924c42741729f041b31a02883548b9/cpp/cmake_modules/ThirdpartyToolchain.cmake#L421-L423 ### What changes are included in this PR? Add the possible missing condition of `ARROW_SUBSTRAIT` for the questioning `if` branch. ### Are these changes tested? Manually tested. ### Are there any user-facing changes? None. * GitHub Issue: #40751 Lead-authored-by: Ruoxi Sun <zanmato1984@gmail.com> Co-authored-by: Rossi Sun <zanmato1984@gmail.com> Co-authored-by: Sutou Kouhei <kou@cozmixng.org> Signed-off-by: Sutou Kouhei <kou@clear-code.com>
1 parent 6aa6f85 commit d5e9e13

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

cpp/cmake_modules/ThirdpartyToolchain.cmake

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1812,7 +1812,9 @@ if(ARROW_WITH_PROTOBUF)
18121812
else()
18131813
set(ARROW_PROTOBUF_REQUIRED_VERSION "2.6.1")
18141814
endif()
1815-
if(ARROW_ORC OR ARROW_WITH_OPENTELEMETRY)
1815+
if(ARROW_ORC
1816+
OR ARROW_SUBSTRAIT
1817+
OR ARROW_WITH_OPENTELEMETRY)
18161818
set(ARROW_PROTOBUF_ARROW_CMAKE_PACKAGE_NAME "Arrow")
18171819
set(ARROW_PROTOBUF_ARROW_PC_PACKAGE_NAME "arrow")
18181820
elseif(ARROW_FLIGHT)

0 commit comments

Comments
 (0)