Skip to content

Commit 1cb32f8

Browse files
committed
Autodetct arm64-linux vs x64-linux
1 parent 6633ab0 commit 1cb32f8

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

cmake/detect-vcpkg-triplet.cmake

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,11 @@ elseif(APPLE)
3939
endif()
4040
endif()
4141
elseif(LINUX)
42-
# Assuming x64 here isn't necessarily correct, but it's the only platform we officially support.
43-
set(DETECTED_VCPKG_TRIPLET "x64-linux")
42+
if(CMAKE_SYSTEM_PROCESSOR STREQUAL "arm64")
43+
set(DETECTED_VCPKG_TRIPLET "arm64-linux")
44+
else()
45+
set(DETECTED_VCPKG_TRIPLET "x64-linux")
46+
endif()
4447
else()
4548
set(DETECTED_VCPKG_TRIPLET_ERROR "Cannot guess an appropriate value for VCPKG_TRIPLET because the operating system is unknown. Please set it manually.")
4649
endif()

0 commit comments

Comments
 (0)