|
|
|
@ -1,6 +1,7 @@
@@ -1,6 +1,7 @@
|
|
|
|
|
include(CheckSymbolExists) |
|
|
|
|
|
|
|
|
|
# generated(see comments in public/build.h) |
|
|
|
|
# cat build.h | grep '^#undef XASH' | awk '{ print "check_symbol_exists(" $2 " \"build.h\" " $2 ")" }' |
|
|
|
|
set(CMAKE_REQUIRED_INCLUDES "${PROJECT_SOURCE_DIR}/public/") |
|
|
|
|
check_symbol_exists(XASH_64BIT "build.h" XASH_64BIT) |
|
|
|
|
check_symbol_exists(XASH_AMD64 "build.h" XASH_AMD64) |
|
|
|
@ -16,9 +17,11 @@ check_symbol_exists(XASH_ARMv7 "build.h" XASH_ARMv7)
@@ -16,9 +17,11 @@ check_symbol_exists(XASH_ARMv7 "build.h" XASH_ARMv7)
|
|
|
|
|
check_symbol_exists(XASH_ARMv8 "build.h" XASH_ARMv8) |
|
|
|
|
check_symbol_exists(XASH_BIG_ENDIAN "build.h" XASH_BIG_ENDIAN) |
|
|
|
|
check_symbol_exists(XASH_BSD "build.h" XASH_BSD) |
|
|
|
|
check_symbol_exists(XASH_DOS4GW "build.h" XASH_DOS4GW) |
|
|
|
|
check_symbol_exists(XASH_E2K "build.h" XASH_E2K) |
|
|
|
|
check_symbol_exists(XASH_EMSCRIPTEN "build.h" XASH_EMSCRIPTEN) |
|
|
|
|
check_symbol_exists(XASH_FREEBSD "build.h" XASH_FREEBSD) |
|
|
|
|
check_symbol_exists(XASH_HAIKU "build.h" XASH_HAIKU) |
|
|
|
|
check_symbol_exists(XASH_IOS "build.h" XASH_IOS) |
|
|
|
|
check_symbol_exists(XASH_JS "build.h" XASH_JS) |
|
|
|
|
check_symbol_exists(XASH_LINUX "build.h" XASH_LINUX) |
|
|
|
@ -29,7 +32,11 @@ check_symbol_exists(XASH_MOBILE_PLATFORM "build.h" XASH_MOBILE_PLATFORM)
@@ -29,7 +32,11 @@ check_symbol_exists(XASH_MOBILE_PLATFORM "build.h" XASH_MOBILE_PLATFORM)
|
|
|
|
|
check_symbol_exists(XASH_MSVC "build.h" XASH_MSVC) |
|
|
|
|
check_symbol_exists(XASH_NETBSD "build.h" XASH_NETBSD) |
|
|
|
|
check_symbol_exists(XASH_OPENBSD "build.h" XASH_OPENBSD) |
|
|
|
|
check_symbol_exists(XASH_HAIKU "build.h" XASH_HAIKU) |
|
|
|
|
check_symbol_exists(XASH_POSIX "build.h" XASH_POSIX) |
|
|
|
|
check_symbol_exists(XASH_RISCV "build.h" XASH_RISCV) |
|
|
|
|
check_symbol_exists(XASH_RISCV_DOUBLEFP "build.h" XASH_RISCV_DOUBLEFP) |
|
|
|
|
check_symbol_exists(XASH_RISCV_SINGLEFP "build.h" XASH_RISCV_SINGLEFP) |
|
|
|
|
check_symbol_exists(XASH_RISCV_SOFTFP "build.h" XASH_RISCV_SOFTFP) |
|
|
|
|
check_symbol_exists(XASH_WIN32 "build.h" XASH_WIN32) |
|
|
|
|
check_symbol_exists(XASH_WIN64 "build.h" XASH_WIN64) |
|
|
|
|
check_symbol_exists(XASH_X86 "build.h" XASH_X86) |
|
|
|
@ -81,10 +88,28 @@ elseif(XASH_ARM)
@@ -81,10 +88,28 @@ elseif(XASH_ARM)
|
|
|
|
|
else() |
|
|
|
|
set(BUILDARCH "${BUILDARCH}l") |
|
|
|
|
endif() |
|
|
|
|
elseif(XASH_MIPS AND XASH_BIG_ENDIAN) |
|
|
|
|
elseif(XASH_MIPS) |
|
|
|
|
set(BUILDARCH "mips") |
|
|
|
|
elseif(XASH_MIPS AND XASH_LITTLE_ENDIAN) |
|
|
|
|
set(BUILDARCH "mipsel") |
|
|
|
|
if(XASH_64BIT) |
|
|
|
|
set(BUILDARCH "${BUILDARCH}64") |
|
|
|
|
endif() |
|
|
|
|
|
|
|
|
|
if(XASH_LITTLE_ENDIAN) |
|
|
|
|
set(BUILDARCH "${BUILDARCH}el") |
|
|
|
|
endif() |
|
|
|
|
elseif(XASH_RISCV) |
|
|
|
|
set(BUILDARCH "riscv") |
|
|
|
|
if(XASH_64BIT) |
|
|
|
|
set(BUILDARCH "${BUILDARCH}64") |
|
|
|
|
else() |
|
|
|
|
set(BUILDARCH "${BUILDARCH}32") |
|
|
|
|
endif() |
|
|
|
|
|
|
|
|
|
if(XASH_RISCV_DOUBLEFP) |
|
|
|
|
set(BUILDARCH "${BUILDARCH}d") |
|
|
|
|
elseif(XASH_RISCV_SINGLEFP) |
|
|
|
|
set(BUILDARCH "${BUILDARCH}f") |
|
|
|
|
endif() |
|
|
|
|
elseif(XASH_JS) |
|
|
|
|
set(BUILDARCH "javascript") |
|
|
|
|
elseif(XASH_E2K) |
|
|
|
|