vcpkg/ports/libtorch/fix-osx-protobuf.patch

15 lines
526 B
Diff

--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -796,7 +796,10 @@ if(NOT CMAKE_BUILD_TYPE)
endif()
# The below means we are cross compiling for arm64 or x86_64 on MacOSX
-if(NOT IOS
+if(TRUE)
+ message(STATUS "Using custom protoc executable: ${PROTOBUF_PROTOC_EXECUTABLE}")
+ message(STATUS "Using custom caffe2 protoc executable: ${CAFFE2_CUSTOM_PROTOC_EXECUTABLE}")
+elseif(NOT IOS
AND CMAKE_SYSTEM_NAME STREQUAL "Darwin"
AND CMAKE_OSX_ARCHITECTURES MATCHES "^(x86_64|arm64)$")
set(CROSS_COMPILING_MACOSX TRUE)