mirror of
https://github.com/bensuperpc/dockcross.git
synced 2024-12-22 08:24:25 +01:00
Use env variable instead hardcoded variable in toolchain.cmake
Use env variable instead hardcoded variable in toolchain.cmake Signed-off-by: Bensuperpc <bensuperpc@gmail.com>
This commit is contained in:
parent
95c12a3a87
commit
5663ada809
@ -3,7 +3,7 @@ set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR armv7-a)
|
||||
set(CMAKE_ANDROID_ARCH_ABI armeabi-v7a)
|
||||
|
||||
set(cross_triple arm-linux-androideabi)
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(CMAKE_ANDROID_STANDALONE_TOOLCHAIN $ENV{CROSS_ROOT})
|
||||
set(CMAKE_ANDROID_ARM_MODE ON)
|
||||
set(CMAKE_ANDROID_ARM_NEON ON)
|
||||
|
@ -3,7 +3,7 @@ set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR aarch64)
|
||||
set(CMAKE_ANDROID_ARCH_ABI arm64-v8a)
|
||||
|
||||
set(cross_triple aarch64-linux-android)
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(CMAKE_ANDROID_STANDALONE_TOOLCHAIN $ENV{CROSS_ROOT})
|
||||
set(CMAKE_ANDROID_ARM_MODE ON)
|
||||
set(CMAKE_ANDROID_ARM_NEON ON)
|
||||
|
@ -3,7 +3,7 @@ set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR i686)
|
||||
set(CMAKE_ANDROID_ARCH_ABI x86)
|
||||
|
||||
set(cross_triple i686-linux-android)
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(CMAKE_ANDROID_STANDALONE_TOOLCHAIN $ENV{CROSS_ROOT})
|
||||
set(CMAKE_ANDROID_ARM_MODE ON)
|
||||
set(CMAKE_ANDROID_ARM_NEON ON)
|
||||
|
@ -3,7 +3,7 @@ set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR x86_64)
|
||||
set(CMAKE_ANDROID_ARCH_ABI x86_64)
|
||||
|
||||
set(cross_triple x86_64-linux-android)
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(CMAKE_ANDROID_STANDALONE_TOOLCHAIN $ENV{CROSS_ROOT})
|
||||
set(CMAKE_ANDROID_ARM_MODE ON)
|
||||
set(CMAKE_ANDROID_ARM_NEON ON)
|
||||
|
@ -2,8 +2,8 @@ set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR aarch64)
|
||||
|
||||
set(cross_triple "aarch64-buildroot-linux-gnu")
|
||||
set(cross_root /buildroot)
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(cross_root $ENV{CROSS_ROOT})
|
||||
|
||||
set(CMAKE_C_COMPILER $ENV{CC})
|
||||
set(CMAKE_CXX_COMPILER $ENV{CXX})
|
||||
@ -13,9 +13,8 @@ set(CMAKE_CXX_FLAGS "-I ${cross_root}/include/")
|
||||
|
||||
set(CMAKE_FIND_ROOT_PATH ${cross_root} ${cross_root}/${cross_triple})
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY BOTH)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE BOTH)
|
||||
|
||||
set(CMAKE_SYSROOT ${cross_root}/${cross_triple}/sysroot)
|
||||
|
||||
|
@ -1,8 +1,9 @@
|
||||
set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR arm)
|
||||
set(cross_triple "armv5-unknown-linux-gnueabi")
|
||||
set(cross_root /usr/xcc/${cross_triple})
|
||||
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(cross_root $ENV{CROSS_ROOT})
|
||||
|
||||
set(CMAKE_C_COMPILER $ENV{CC})
|
||||
set(CMAKE_CXX_COMPILER $ENV{CXX})
|
||||
|
@ -1,8 +1,9 @@
|
||||
set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR arm)
|
||||
set(cross_triple "armv6-unknown-linux-gnueabihf")
|
||||
set(cross_root /usr/xcc/${cross_triple})
|
||||
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(cross_root $ENV{CROSS_ROOT})
|
||||
|
||||
set(CMAKE_C_COMPILER $ENV{CC})
|
||||
set(CMAKE_CXX_COMPILER $ENV{CXX})
|
||||
|
@ -1,8 +1,9 @@
|
||||
set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR arm)
|
||||
set(cross_triple "armv7-unknown-linux-gnueabi")
|
||||
set(cross_root /usr/xcc/${cross_triple})
|
||||
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(cross_root $ENV{CROSS_ROOT})
|
||||
|
||||
set(CMAKE_C_COMPILER $ENV{CC})
|
||||
set(CMAKE_CXX_COMPILER $ENV{CXX})
|
||||
|
@ -1,8 +1,9 @@
|
||||
set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR arm)
|
||||
set(cross_triple "arm-cortexa8_neon-linux-gnueabihf")
|
||||
set(cross_root /usr/xcc/${cross_triple})
|
||||
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(cross_root $ENV{CROSS_ROOT})
|
||||
|
||||
set(CMAKE_C_COMPILER $ENV{CC})
|
||||
set(CMAKE_CXX_COMPILER $ENV{CXX})
|
||||
|
@ -2,8 +2,8 @@ set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR mk68)
|
||||
|
||||
set(cross_triple "m68k-unknown-uclinux-uclibc")
|
||||
set(cross_root /usr/xcc/${cross_triple})
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(cross_root $ENV{CROSS_ROOT})
|
||||
|
||||
set(CMAKE_C_COMPILER $ENV{CC})
|
||||
set(CMAKE_CXX_COMPILER $ENV{CXX})
|
||||
|
@ -2,8 +2,8 @@ set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR mips)
|
||||
|
||||
set(cross_triple "mips-unknown-linux-gnu")
|
||||
set(cross_root /usr/xcc/${cross_triple})
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(cross_root $ENV{CROSS_ROOT})
|
||||
|
||||
set(CMAKE_C_COMPILER $ENV{CC})
|
||||
set(CMAKE_CXX_COMPILER $ENV{CXX})
|
||||
|
@ -2,8 +2,8 @@ set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR ppc64le)
|
||||
|
||||
set(cross_triple "powerpc64le-unknown-linux-gnu")
|
||||
set(cross_root /usr/xcc/${cross_triple})
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(cross_root $ENV{CROSS_ROOT})
|
||||
|
||||
set(CMAKE_C_COMPILER $ENV{CC})
|
||||
set(CMAKE_CXX_COMPILER $ENV{CXX})
|
||||
|
@ -2,8 +2,8 @@ set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR riscv32)
|
||||
|
||||
set(cross_triple "riscv32-unknown-linux-gnu")
|
||||
set(cross_root /usr/xcc/${cross_triple})
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(cross_root $ENV{CROSS_ROOT})
|
||||
|
||||
set(CMAKE_C_COMPILER $ENV{CC})
|
||||
set(CMAKE_CXX_COMPILER $ENV{CXX})
|
||||
|
@ -2,8 +2,8 @@ set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR riscv64)
|
||||
|
||||
set(cross_triple "riscv64-unknown-linux-gnu")
|
||||
set(cross_root /usr/xcc/${cross_triple})
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(cross_root $ENV{CROSS_ROOT})
|
||||
|
||||
set(CMAKE_C_COMPILER $ENV{CC})
|
||||
set(CMAKE_CXX_COMPILER $ENV{CXX})
|
||||
|
@ -2,8 +2,8 @@ set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR s390x)
|
||||
|
||||
set(cross_triple "s390x-ibm-linux-gnu")
|
||||
set(cross_root /usr/xcc/${cross_triple})
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(cross_root $ENV{CROSS_ROOT})
|
||||
|
||||
set(CMAKE_C_COMPILER $ENV{CC})
|
||||
set(CMAKE_CXX_COMPILER $ENV{CXX})
|
||||
|
@ -2,8 +2,8 @@ set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_VERSION 1)
|
||||
set(CMAKE_SYSTEM_PROCESSOR xtensa)
|
||||
|
||||
set(cross_triple "xtensa-fsf-linux-uclibc")
|
||||
set(cross_root /usr/xcc/${cross_triple})
|
||||
set(cross_triple $ENV{CROSS_TRIPLE})
|
||||
set(cross_root $ENV{CROSS_ROOT})
|
||||
|
||||
set(CMAKE_C_COMPILER $ENV{CC})
|
||||
set(CMAKE_CXX_COMPILER $ENV{CXX})
|
||||
|
@ -16,4 +16,4 @@ set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY BOTH)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE BOTH)
|
||||
|
||||
set(CMAKE_CROSSCOMPILING_EMULATOR /usr/bin/qemu-arm)
|
||||
set(CMAKE_CROSSCOMPILING_EMULATOR /usr/bin/qemu-arm)
|
||||
|
Loading…
Reference in New Issue
Block a user