Skip to content
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

[C++][FlightRPC] Downstream MINGW builds are failing to build arrow flight do to undefined reference #41333

Closed
raulcd opened this issue Apr 22, 2024 · 11 comments

Comments

@raulcd
Copy link
Member

raulcd commented Apr 22, 2024

Describe the bug, including details regarding any error messages, version, and platform.

I am trying to add the 16.0.0 release to MINGW-packages but CI is failing with:

  FAILED: release/libarrow_flight.dll release/libarrow_flight.dll.a 
  C:\Windows\system32\cmd.exe /C "cd . && D:\M\msys64\ucrt64\bin\g++.exe -Wno-noexcept-type -Wno-self-move -march=nocona -msahf -mtune=generic -O2 -pipe -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector-strong -fdiagnostics-color=always  -Wa,-mbig-obj -Wall -fno-semantic-interposition -mxsave -msse4.2  -O3 -DNDEBUG -O2 -ftree-vectorize  -Wl,--version-script=C:/_/B/src/apache-arrow-16.0.0/cpp/src/arrow/symbols.map -shared -o release\libarrow_flight.dll -Wl,--out-implib,release\libarrow_flight.dll.a -Wl,--major-image-version,1600,--minor-image-version,0 @CMakeFiles\arrow_flight_shared.rsp && cd ."
  D:/M/msys64/ucrt64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: src/arrow/flight/CMakeFiles/arrow_flight_shared.dir/Flight.pb.cc.obj:Flight.pb.cc:(.text.unlikely+0x27): undefined reference to `void absl::lts_20240116::log_internal::LogMessage::CopyToEncodedBuffer<(absl::lts_20240116::log_internal::LogMessage::StringType)0>(std::basic_string_view<char, std::char_traits<char> >)'
  D:/M/msys64/ucrt64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: src/arrow/flight/CMakeFiles/arrow_flight_shared.dir/Flight.pb.cc.obj:Flight.pb.cc:(.text.unlikely+0x67): undefined reference to `absl::lts_20240116::log_internal::LogMessageFatal::LogMessageFatal(char const*, int)'
  D:/M/msys64/ucrt64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: src/arrow/flight/CMakeFiles/arrow_flight_shared.dir/Flight.pb.cc.obj:Flight.pb.cc:(.text.unlikely+0x87): undefined reference to `void absl::lts_20240116::log_internal::LogMessage::CopyToEncodedBuffer<(absl::lts_20240116::log_internal::LogMessage::StringType)0>(std::basic_string_view<char, std::char_traits<char> >)'
  D:/M/msys64/ucrt64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: src/arrow/flight/CMakeFiles/arrow_flight_shared.dir/Flight.pb.cc.obj:Flight.pb.cc:(.text.unlikely+0xa7): undefined reference to `void absl::lts_20240116::log_internal::LogMessage::CopyToEncodedBuffer<(absl::lts_20240116::log_internal::LogMessage::StringType)0>(std::basic_string_view<char, std::char_traits<char> >)'
  D:/M/msys64/ucrt64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: src/arrow/flight/CMakeFiles/arrow_flight_shared.dir/Flight.pb.cc.obj:Flight.pb.cc:(.text.unlikely+0xc7): undefined reference to `void absl::lts_20240116::log_internal::LogMessage::CopyToEncodedBuffer<(absl::lts_20240116::log_internal::LogMessage::StringType)0>(std::basic_string_view<char, std::char_traits<char> >)'
  D:/M/msys64/ucrt64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: src/arrow/flight/CMakeFiles/arrow_flight_shared.dir/Flight.pb.cc.obj:Flight.pb.cc:(.text.unlikely+0xe0): undefined reference to `absl::lts_20240116::log_internal::LogMessageFatal::~LogMessageFatal()'
  D:/M/msys64/ucrt64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: src/arrow/flight/CMakeFiles/arrow_flight_shared.dir/Flight.pb.cc.obj:Flight.pb.cc:(.text$_ZN4absl12lts_2024011612log_internal10LogMessagelsIPKcLi0EEERS2_RKT_[_ZN4absl12lts_2024011612log_internal10LogMessagelsIPKcLi0EEERS2_RKT_]+0x35): undefined reference to `absl::lts_20240116::log_internal::LogMessage::OstreamView::OstreamView(absl::lts_20240116::log_internal::LogMessage::LogMessageData&)'
  D:/M/msys64/ucrt64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: src/arrow/flight/CMakeFiles/arrow_flight_shared.dir/Flight.pb.cc.obj:Flight.pb.cc:(.text$_ZN4absl12lts_2024011612log_internal10LogMessagelsIPKcLi0EEERS2_RKT_[_ZN4absl12lts_2024011612log_internal10LogMessagelsIPKcLi0EEERS2_RKT_]+0x3d): undefined reference to `absl::lts_20240116::log_internal::LogMessage::OstreamView::stream()'
  D:/M/msys64/ucrt64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: src/arrow/flight/CMakeFiles/arrow_flight_shared.dir/Flight.pb.cc.obj:Flight.pb.cc:(.text$_ZN4absl12lts_2024011612log_internal10LogMessagelsIPKcLi0EEERS2_RKT_[_ZN4absl12lts_2024011612log_internal10LogMessagelsIPKcLi0EEERS2_RKT_]+0x6c): undefined reference to `absl::lts_20240116::log_internal::LogMessage::OstreamView::~OstreamView()'
  D:/M/msys64/ucrt64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: src/arrow/flight/CMakeFiles/arrow_flight_shared.dir/Flight.pb.cc.obj:Flight.pb.cc:(.text$_ZN4absl12lts_2024011612log_internal10LogMessagelsIPKcLi0EEERS2_RKT_[_ZN4absl12lts_2024011612log_internal10LogMessagelsIPKcLi0EEERS2_RKT_]+0x96): undefined reference to `absl::lts_20240116::log_internal::LogMessage::OstreamView::~OstreamView()'
  D:/M/msys64/ucrt64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: src/arrow/flight/CMakeFiles/arrow_flight_shared.dir/Flight.pb.cc.obj:Flight.pb.cc:(.text$_ZNK6google8protobuf6MapKey14GetStringValueB5cxx11Ev[_ZNK6google8protobuf6MapKey14GetStringValueB5cxx11Ev]+0x67): undefined reference to `absl::lts_20240116::log_internal::LogMessageFatal::LogMessageFatal(char const*, int)'
  D:/M/msys64/ucrt64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: src/arrow/flight/CMakeFiles/arrow_flight_shared.dir/Flight.pb.cc.obj:Flight.pb.cc:

See the PR here: msys2/MINGW-packages#20692

Component(s)

C++, FlightRPC

@raulcd
Copy link
Member Author

raulcd commented Apr 22, 2024

@kou @lidavidm any idea what the issue is here?

@assignUser
Copy link
Member

assignUser commented Apr 22, 2024

Protobuf added a dependency on abseil in v22+ and iirc we are using 21, could it be that mingw has a more recent version? See https://protobuf.dev/support/migration/#cpp-22

@lidavidm
Copy link
Member

Seems mingw has mingw-w64-x86_64-abseil-cpp-20240116.1-1 which should be new enough by the description on that page. Maybe we're forgetting to link to something?

@assignUser
Copy link
Member

When I cross compiled arrow r in a mingw based thing there was an issue with abseil dependencies not being properly forwarded through pkg config (I think it was re2).

@kou
Copy link
Member

kou commented Apr 23, 2024

It seems that Protobuf's CMake package isn't used:

https://github.com/msys2/MINGW-packages/actions/runs/8782545754/job/24096849170?pr=20692#step:11:614

  -- Found Protobuf: D:/M/msys64/clang64/lib/libprotobuf.dll.a (found version "4.25.3")
  -- Providing CMake module for FindProtobufAlt as part of ArrowFlight CMake package
  -- Using pkg-config package for protobuf that is used by arrow-flight for static link

(protobuf.pc is used instead.)

Could you try this?

diff --git a/mingw-w64-arrow/PKGBUILD b/mingw-w64-arrow/PKGBUILD
index ec1ef286c..843a65841 100644
--- a/mingw-w64-arrow/PKGBUILD
+++ b/mingw-w64-arrow/PKGBUILD
@@ -84,7 +84,7 @@ build() {
     export _cmake_build_type="Debug"
   fi
 
-  MSYS2_ARG_CONV_EXCL="-DCMAKE_INSTALL_PREFIX=" \
+  MSYS2_ARG_CONV_EXCL="-DCMAKE_INSTALL_PREFIX=;-DARROW_PACKAGE_PREFIX=" \
     ${MINGW_PREFIX}/bin/cmake.exe -Wno-dev \
       -G Ninja \
       -DCMAKE_INSTALL_PREFIX=${MINGW_PREFIX} \

Or we may be able to omit CMake package paths:

diff --git a/mingw-w64-arrow/PKGBUILD b/mingw-w64-arrow/PKGBUILD
index ec1ef286c..f08e53000 100644
--- a/mingw-w64-arrow/PKGBUILD
+++ b/mingw-w64-arrow/PKGBUILD
@@ -101,7 +101,6 @@ build() {
       -DARROW_HDFS=ON \
       -DARROW_JSON=ON \
       -DARROW_PACKAGE_KIND=${MINGW_PACKAGE_PREFIX} \
-      -DARROW_PACKAGE_PREFIX=${MINGW_PREFIX} \
       -DARROW_PARQUET=ON \
       -DARROW_S3=ON \
       -DARROW_USE_GLOG=OFF \
@@ -112,7 +111,6 @@ build() {
       -DARROW_WITH_SNAPPY=ON \
       -DARROW_WITH_ZLIB=ON \
       -DARROW_WITH_ZSTD=ON \
-      -DBOOST_ROOT=${MINGW_PREFIX} \
       -DPARQUET_BUILD_EXECUTABLES=ON \
       -DPARQUET_REQUIRE_ENCRYPTION=ON \
       -DPython3_EXECUTABLE=${MINGW_PREFIX}/bin/python \

@kou
Copy link
Member

kou commented Apr 23, 2024

Or could you enable debug log?
https://cmake.org/cmake/help/latest/variable/CMAKE_FIND_DEBUG_MODE.html

diff --git a/mingw-w64-arrow/PKGBUILD b/mingw-w64-arrow/PKGBUILD
index ec1ef286c..0280d6234 100644
--- a/mingw-w64-arrow/PKGBUILD
+++ b/mingw-w64-arrow/PKGBUILD
@@ -89,6 +89,7 @@ build() {
       -G Ninja \
       -DCMAKE_INSTALL_PREFIX=${MINGW_PREFIX} \
       -DCMAKE_BUILD_TYPE=${_cmake_build_type} \
+      -DCMAKE_FIND_DEBUG_MODE=ON \
       -DARROW_ACERO=ON \
       -DARROW_BUILD_UTILITIES=ON \
       -DARROW_COMPUTE=ON \

@raulcd
Copy link
Member Author

raulcd commented Apr 23, 2024

Something similar seems to be happening on protobuf / abseil for conda on Windows on the conda feedstock on the 16.0.0 PR (conda-forge/arrow-cpp-feedstock#1255), this is the error: https://dev.azure.com/conda-forge/feedstock-builds/_build/results?buildId=920516&view=logs&j=10aa580e-aee1-5b9b-3283-2dc181465fcb&t=72fcaa87-4150-5a1f-38e4-dcca063da3f2&l=2146
But in this case is substrait instead of flight

[179/180] Linking CXX shared library release\arrow_substrait.dll
FAILED: release/arrow_substrait.dll release/arrow_substrait.lib 
C:\Windows\system32\cmd.exe /C "cd . && %BUILD_PREFIX%\Library\bin\cmake.exe -E vs_link_dll --intdir=src\arrow\engine\CMakeFiles\arrow_substrait_shared.dir --rc=C:\PROGRA~2\WI3CF2~1\10\bin\100226~1.0\x64\rc.exe --mt=C:\PROGRA~2\WI3CF2~1\10\bin\100226~1.0\x64\mt.exe --manifests  -- C:\PROGRA~1\MICROS~2\2022\ENTERP~1\VC\Tools\MSVC\1429~1.301\bin\HostX64\x64\link.exe /nologo src\arrow\engine\CMakeFiles\arrow_substrait_shared.dir\Unity\unity_1_cxx.cxx.obj src\arrow\engine\CMakeFiles\arrow_substrait_shared.dir\Unity\unity_0_cxx.cxx.obj  /out:release\arrow_substrait.dll /implib:release\arrow_substrait.lib /pdb:release\arrow_substrait.pdb /dll /version:1600.0 /machine:x64  /NODEFAULTLIB:LIBCMT /INCREMENTAL:NO -Wl,--version-script=D:/bld/apache-arrow_1713885601816/work/cpp/src/arrow/symbols.map  release\arrow_dataset.lib  release\substrait.lib  release\parquet.lib  release\arrow_acero.lib  release\arrow.lib  %PREFIX%\Library\lib\libprotobuf.lib  kernel32.lib user32.lib gdi32.lib winspool.lib shell32.lib ole32.lib oleaut32.lib uuid.lib comdlg32.lib advapi32.lib && cd ."
LINK: command "C:\PROGRA~1\MICROS~2\2022\ENTERP~1\VC\Tools\MSVC\1429~1.301\bin\HostX64\x64\link.exe /nologo src\arrow\engine\CMakeFiles\arrow_substrait_shared.dir\Unity\unity_1_cxx.cxx.obj src\arrow\engine\CMakeFiles\arrow_substrait_shared.dir\Unity\unity_0_cxx.cxx.obj /out:release\arrow_substrait.dll /implib:release\arrow_substrait.lib /pdb:release\arrow_substrait.pdb /dll /version:1600.0 /machine:x64 /NODEFAULTLIB:LIBCMT /INCREMENTAL:NO -Wl,--version-script=D:/bld/apache-arrow_1713885601816/work/cpp/src/arrow/symbols.map release\arrow_dataset.lib release\substrait.lib release\parquet.lib release\arrow_acero.lib release\arrow.lib %PREFIX%\Library\lib\libprotobuf.lib kernel32.lib user32.lib gdi32.lib winspool.lib shell32.lib ole32.lib oleaut32.lib uuid.lib comdlg32.lib advapi32.lib /MANIFEST:EMBED,ID=2" failed (exit code 1120) with the following output:
LINK : warning LNK4044: unrecognized option '/Wl,--version-script=D:/bld/apache-arrow_1713885601816/work/cpp/src/arrow/symbols.map'; ignored
   Creating library release\arrow_substrait.lib and object release\arrow_substrait.exp
unity_0_cxx.cxx.obj : error LNK2019: unresolved external symbol "public: void __cdecl absl::lts_20240116::status_internal::StatusRep::Unref(void)const " (?Unref@StatusRep@status_internal@lts_20240116@absl@@QEBAXXZ) referenced in function "public: __cdecl absl::lts_20240116::Status::~Status(void)" (??1Status@lts_20240116@absl@@QEAA@XZ)
unity_0_cxx.cxx.obj : error LNK2019: unresolved external symbol "class std::basic_ostream<char,struct std::char_traits<char> > & __cdecl absl::lts_20240116::operator<<(class std::basic_ostream<char,struct std::char_traits<char> > &,class absl::lts_20240116::Status const &)" (??6lts_20240116@absl@@YAAEAV?$basic_ostream@DU?$char_traits@D@std@@@std@@AEAV23@AEBVStatus@01@@Z) referenced in function "public: static class arrow::Status __cdecl arrow::Status::FromArgs<char const (&)[29],class absl::lts_20240116::Status &>(enum arrow::StatusCode,char const (&)[29],class absl::lts_20240116::Status &)" (??$FromArgs@AEAY0BN@$$CBDAEAVStatus@lts_20240116@absl@@@Status@arrow@@SA?AV01@W4StatusCode@1@AEAY0BN@$$CBDAEAV0lts_20240116@absl@@@Z)
substrait.lib(extension_rels.pb.cc.obj) : error LNK2001: unresolved external symbol "private: void __cdecl absl::lts_20240116::log_internal::LogMessage::CopyToEncodedBuffer<0>(class std::basic_string_view<char,struct std::char_traits<char> >)" (??$CopyToEncodedBuffer@$0A@@LogMessage@log_internal@lts_20240116@absl@@AEAAXV?$basic_string_view@DU?$char_traits@D@std@@@std@@@Z)
substrait.lib(type.pb.cc.obj) : error LNK2001: unresolved external symbol "private: void __cdecl absl::lts_20240116::log_internal::LogMessage::CopyToEncodedBuffer<0>(class std::basic_string_view<char,struct std::char_traits<char> >)" (??$CopyToEncodedBuffer@$0A@@LogMessage@log_internal@lts_20240116@absl@@AEAAXV?$basic_string_view@DU?$char_traits@D@std@@@std@@@Z)
substrait.lib(algebra.pb.cc.obj) : error LNK2001: unresolved external symbol "private: void __cdecl absl::lts_20240116::log_internal::LogMessage::CopyToEncodedBuffer<0>(class std::basic_string_view<char,struct std::char_traits<char> >)" (??$CopyToEncodedBuffer@$0A@@LogMessage@log_internal@lts_20240116@absl@@AEAAXV?$basic_string_view@DU?$char_traits@D@std@@@std@@@Z)
substrait.lib(plan.pb.cc.obj) : error LNK2001: unresolved external symbol "private: void __cdecl absl::lts_20240116::log_internal::LogMessage::CopyToEncodedBuffer<0>(class std::basic_string_view<char,struct std::char_traits<char> >)" (??$CopyToEncodedBuffer@$0A@@LogMessage@log_internal@lts_20240116@absl@@AEAAXV?$basic_string_view@DU?$char_traits@D@std@@@std@@@Z)
substrait.lib(extensions.pb.cc.obj) : error LNK2001: unresolved external symbol "private: void __cdecl absl::lts_20240116::log_internal::LogMessage::CopyToEncodedBuffer<0>(class std::basic_string_view<char,struct std::char_traits<char> >)" (??$CopyToEncodedBuffer@$0A@@LogMessage@log_internal@lts_20240116@absl@@AEAAXV?$basic_string_view@DU?$char_traits@D@std@@@std@@@Z)
substrait.lib(algebra.pb.cc.obj) : error LNK2019: unresolved external symbol "class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > * __cdecl absl::lts_20240116::log_internal::MakeCheckOpString<unsigned __int64,unsigned __int64>(unsigned __int64,unsigned __int64,char const *)" (??$MakeCheckOpString@_K_K@log_internal@lts_20240116@absl@@YAPEAV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@_K0PEBD@Z) referenced in function "class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > * __cdecl absl::lts_20240116::log_internal::Check_LEImpl<unsigned __int64,unsigned __int64>(unsigned __int64 const &,unsigned __int64 const &,char const *)" (??$Check_LEImpl@_K_K@log_internal@lts_20240116@absl@@YAPEAV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@AEB_K0PEBD@Z)
release\arrow_substrait.dll : fatal error LNK1120: 4 unresolved externals

@h-vetinari
Copy link
Contributor

The failures in conda-forge look like something happening in the absl::lts_20240116::Status::~Status(void) destructor, which reminds me of this issue, that ended up being due to an abseil-consuming library not having defined -DNDEBUG (or rather, not respecting the CPP_FLAGS for the preprocessor).

Probably worth double-checking if -DNDEBUG is defined. Also, for completeness, in conda-forge we're basically on newest abseil/grpc/protobuf, we're using shared (not static) builds, and we're using MSVC not MinGW.

@kou
Copy link
Member

kou commented Apr 24, 2024

For MSYS2: My guess was wrong. The Protobuf CMake "Module" (FindProtobuf.cmake) not "Config" (`protobuf-config.cmake') was used. I don't know why our CI uses "Config" not "Module" but this may fix this:

diff --git a/cpp/cmake_modules/FindProtobufAlt.cmake b/cpp/cmake_modules/FindProtobufAlt.cmake
index 15fe1b4f27..ef3b1219e1 100644
--- a/cpp/cmake_modules/FindProtobufAlt.cmake
+++ b/cpp/cmake_modules/FindProtobufAlt.cmake
@@ -28,8 +28,12 @@ endif()
 if(ProtobufAlt_FIND_QUIETLY)
   list(APPEND find_package_args QUIET)
 endif()
-find_package(Protobuf ${find_package_args})
-set(ProtobufAlt_FOUND ${Protobuf_FOUND})
+find_package(protobuf CONFIG ${find_package_args})
+set(ProtobufAlt_FOUND ${protobuf_FOUND})
+if(NOT ProtobufAlt_FOUND)
+  find_package(Protobuf ${find_package_args})
+  set(ProtobufAlt_FOUND ${Protobuf_FOUND})
+endif()
 if(ProtobufAlt_FOUND)
   set(ProtobufAlt_VERSION ${Protobuf_VERSION})
   set(ProtobufAlt_VERSION_MAJOR ${Protobuf_VERSION_MAJOR})

@kou
Copy link
Member

kou commented Apr 24, 2024

For conda-forge: It seems that this uses "Module" not "Config" too:

https://dev.azure.com/conda-forge/feedstock-builds/_build/results?buildId=920516&view=logs&j=10aa580e-aee1-5b9b-3283-2dc181465fcb&t=72fcaa87-4150-5a1f-38e4-dcca063da3f2&l=1489

-- Found Protobuf: D:/bld/apache-arrow_1713885601816/_h_env/Library/lib/libprotobuf.lib (found version "4.25.3")

#41333 (comment) (GH-41360) may also fix the conda-forge case.

kou added a commit to kou/arrow that referenced this issue Apr 24, 2024
@kou kou changed the title [C++][Flight] Downstream MINGW builds are failing to build arrow flight do to undefined reference [C++][FlightRPC] Downstream MINGW builds are failing to build arrow flight do to undefined reference Apr 24, 2024
kou added a commit that referenced this issue Apr 26, 2024
…make (#41360)

### Rationale for this change

`protobuf::libprotobuf` provided by `FindProtobuf.cmake` (provided by CMake) may not provide needed dependencies such as Abseil.

### What changes are included in this PR?

Try `protobuf-config.cmake` provided by Protobuf before `FindProtobuf.cmake`.
`protobuf::libprotobuf` provided by `protobuf-config.cmake` must have needed dependencies.

### Are these changes tested?

Yes.

### Are there any user-facing changes?

Yes.
* GitHub Issue: #41333

Authored-by: Sutou Kouhei <kou@clear-code.com>
Signed-off-by: Sutou Kouhei <kou@clear-code.com>
@kou kou added this to the 16.1.0 milestone Apr 26, 2024
@kou
Copy link
Member

kou commented Apr 26, 2024

Issue resolved by pull request 41360
#41360

@kou kou closed this as completed Apr 26, 2024
raulcd pushed a commit that referenced this issue Apr 29, 2024
…make (#41360)

### Rationale for this change

`protobuf::libprotobuf` provided by `FindProtobuf.cmake` (provided by CMake) may not provide needed dependencies such as Abseil.

### What changes are included in this PR?

Try `protobuf-config.cmake` provided by Protobuf before `FindProtobuf.cmake`.
`protobuf::libprotobuf` provided by `protobuf-config.cmake` must have needed dependencies.

### Are these changes tested?

Yes.

### Are there any user-facing changes?

Yes.
* GitHub Issue: #41333

Authored-by: Sutou Kouhei <kou@clear-code.com>
Signed-off-by: Sutou Kouhei <kou@clear-code.com>
tolleybot pushed a commit to tmct/arrow that referenced this issue May 2, 2024
…obuf.cmake (apache#41360)

### Rationale for this change

`protobuf::libprotobuf` provided by `FindProtobuf.cmake` (provided by CMake) may not provide needed dependencies such as Abseil.

### What changes are included in this PR?

Try `protobuf-config.cmake` provided by Protobuf before `FindProtobuf.cmake`.
`protobuf::libprotobuf` provided by `protobuf-config.cmake` must have needed dependencies.

### Are these changes tested?

Yes.

### Are there any user-facing changes?

Yes.
* GitHub Issue: apache#41333

Authored-by: Sutou Kouhei <kou@clear-code.com>
Signed-off-by: Sutou Kouhei <kou@clear-code.com>
vibhatha pushed a commit to vibhatha/arrow that referenced this issue May 25, 2024
…obuf.cmake (apache#41360)

### Rationale for this change

`protobuf::libprotobuf` provided by `FindProtobuf.cmake` (provided by CMake) may not provide needed dependencies such as Abseil.

### What changes are included in this PR?

Try `protobuf-config.cmake` provided by Protobuf before `FindProtobuf.cmake`.
`protobuf::libprotobuf` provided by `protobuf-config.cmake` must have needed dependencies.

### Are these changes tested?

Yes.

### Are there any user-facing changes?

Yes.
* GitHub Issue: apache#41333

Authored-by: Sutou Kouhei <kou@clear-code.com>
Signed-off-by: Sutou Kouhei <kou@clear-code.com>
CurtHagenlocher pushed a commit to CurtHagenlocher/arrow that referenced this issue Jun 14, 2024
…obuf.cmake (apache#41360)

### Rationale for this change

`protobuf::libprotobuf` provided by `FindProtobuf.cmake` (provided by CMake) may not provide needed dependencies such as Abseil.

### What changes are included in this PR?

Try `protobuf-config.cmake` provided by Protobuf before `FindProtobuf.cmake`.
`protobuf::libprotobuf` provided by `protobuf-config.cmake` must have needed dependencies.

### Are these changes tested?

Yes.

### Are there any user-facing changes?

Yes.
* GitHub Issue: apache#41333

Authored-by: Sutou Kouhei <kou@clear-code.com>
Signed-off-by: Sutou Kouhei <kou@clear-code.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants