initial commit
Some checks failed
sgraves/cpp-build-system_mac/pipeline/head There was a failure building this commit
sgraves/cpp-build-system/pipeline/head There was a failure building this commit

This commit is contained in:
2025-10-17 07:44:16 -05:00
parent 933c973c79
commit 92e3e495ce
1099 changed files with 102722 additions and 0 deletions

16
cmake/arch.cmake Normal file
View File

@@ -0,0 +1,16 @@
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "4")
message(FATAL_ERROR "32-bit compilation is not supported")
endif()
if(CMAKE_SYSTEM_PROCESSOR MATCHES "^(aarch64.*|AARCH64.*|arm64.*|ARM64.*)")
set(IS_ARM_SYSTEM 1)
endif()
if(PROJECT_IS_ARM64 AND NOT IS_ARM_SYSTEM AND NOT PROJECT_REQUIRE_ALPINE)
message(FATAL_ERROR "aarch64 cross-compile is not supported")
endif()
string(REPLACE "_" "-" PROJECT_MARCH ${PROJECT_BUILD_ARCH})
if("${PROJECT_BUILD_ARCH}" STREQUAL "aarch64")
set(PROJECT_MARCH armv8-a)
endif()