mirror of
https://github.com/tildearrow/furnace.git
synced 2024-11-22 12:35:11 +00:00
Add MinGW cross-compiler toolchains
This commit is contained in:
parent
8a6dfa8d19
commit
0351388996
3 changed files with 22 additions and 0 deletions
4
scripts/Cross-MinGW-x86.cmake
Normal file
4
scripts/Cross-MinGW-x86.cmake
Normal file
|
@ -0,0 +1,4 @@
|
|||
set(CMAKE_SYSTEM_NAME Windows)
|
||||
set(CMAKE_SYSTEM_PROCESSOR i686)
|
||||
|
||||
include(${CMAKE_CURRENT_LIST_DIR}/Cross-MinGW.cmake)
|
4
scripts/Cross-MinGW-x86_64.cmake
Normal file
4
scripts/Cross-MinGW-x86_64.cmake
Normal file
|
@ -0,0 +1,4 @@
|
|||
set(CMAKE_SYSTEM_NAME Windows)
|
||||
set(CMAKE_SYSTEM_PROCESSOR x86_64)
|
||||
|
||||
include(${CMAKE_CURRENT_LIST_DIR}/Cross-MinGW.cmake)
|
14
scripts/Cross-MinGW.cmake
Normal file
14
scripts/Cross-MinGW.cmake
Normal file
|
@ -0,0 +1,14 @@
|
|||
set(TARGET_PREFIX ${CMAKE_SYSTEM_PROCESSOR}-w64-mingw32)
|
||||
|
||||
set(CMAKE_C_COMPILER ${TARGET_PREFIX}-gcc-posix)
|
||||
set(CMAKE_CXX_COMPILER ${TARGET_PREFIX}-g++-posix)
|
||||
set(PKG_CONFIG_EXECUTABLE ${TARGET_PREFIX}-pkg-config)
|
||||
|
||||
set(CMAKE_FIND_ROOT_PATH /usr/${TARGET_PREFIX})
|
||||
|
||||
# Search host system for programs
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
|
||||
# Search target system for libraries, headers & CMake packages
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
|
||||
set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)
|
Loading…
Reference in a new issue