Skip to content

Fix build configs for macOS ARM64 on DTK #39142

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

Merged
merged 1 commit into from
Jul 11, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion eng/native/configurecompiler.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,13 @@ if (CLR_CMAKE_HOST_UNIX)
add_definitions(-DHOST_UNIX)

if(CLR_CMAKE_HOST_OSX)
message("Detected OSX x86_64")
if(CLR_CMAKE_HOST_UNIX_AMD64)
message("Detected OSX x86_64")
elseif(CLR_CMAKE_HOST_UNIX_ARM64)
message("Detected OSX ARM64")
else()
clr_unknown_arch()
endif()
elseif(CLR_CMAKE_HOST_FREEBSD)
message("Detected FreeBSD amd64")
elseif(CLR_CMAKE_HOST_NETBSD)
Expand Down
8 changes: 7 additions & 1 deletion eng/native/configureplatform.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,14 @@ endif(CLR_CMAKE_HOST_OS STREQUAL Linux)

if(CLR_CMAKE_HOST_OS STREQUAL Darwin)
set(CLR_CMAKE_HOST_UNIX 1)
set(CLR_CMAKE_HOST_UNIX_AMD64 1)
set(CLR_CMAKE_HOST_OSX 1)
if(CMAKE_SYSTEM_PROCESSOR STREQUAL x86_64)
set(CLR_CMAKE_HOST_UNIX_AMD64 1)
elseif(CMAKE_SYSTEM_PROCESSOR STREQUAL arm64)
set(CLR_CMAKE_HOST_UNIX_ARM64 1)
else()
clr_unknown_arch()
endif()
set(CMAKE_ASM_COMPILE_OBJECT "${CMAKE_C_COMPILER} <FLAGS> <DEFINES> <INCLUDES> -o <OBJECT> -c <SOURCE>")
endif(CLR_CMAKE_HOST_OS STREQUAL Darwin)

Expand Down
2 changes: 1 addition & 1 deletion eng/native/init-os-and-arch.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ else
fi

case "$CPUName" in
aarch64)
arm64|aarch64)
arch=arm64
;;

Expand Down