raulcd commented on code in PR #1029:
URL: https://github.com/apache/iceberg-cpp/pull/1029#discussion_r4297563739


##########
cmake_modules/IcebergThirdpartyToolchain.cmake:
##########
@@ -233,14 +233,33 @@ function(resolve_arrow_dependency)
         "https://archive.apache.org/dist/thrift/0.22.0/thrift-0.22.0.tar.gz";)
   endif()
 
+  # FetchContent sets arrow_SOURCE_DIR to the tarball root (SOURCE_SUBDIR is 
cpp)
+  # and older CMake (e.g. 3.28) does not override it in project(arrow), so 
Arrow
+  # looks for thirdparty/versions.txt outside cpp/. Patch Arrow to use
+  # ARROW_SOURCE_DIR instead. See 
https://github.com/apache/iceberg-cpp/issues/1028.
+  # TODO: remove once the upstream Arrow fix is released.
+  set(ARROW_PATCH_COMMAND)
+  find_program(PATCH patch)
+  if(PATCH)
+    set(ARROW_PATCH_COMMAND ${PATCH} -p1 -i)
+  else()
+    find_program(GIT git)
+    if(GIT)
+      set(ARROW_PATCH_COMMAND ${GIT} apply)

Review Comment:
   This is basically the same approach we take at Arrow, I don't think it's 
true, I've applied with both git apply and patch.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to