mirror of
https://github.com/OpenRCT2/OpenRCT2.git
synced 2025-01-22 18:31:59 -05:00
29 lines
1 KiB
Text
29 lines
1 KiB
Text
|
SET(CMAKE_SYSTEM_NAME Windows)
|
||
|
|
||
|
SET(COMPILER_PREFIX i686-w64-mingw32)
|
||
|
SET(CMAKE_C_COMPILER ${COMPILER_PREFIX}-gcc)
|
||
|
SET(CMAKE_CXX_COMPILER ${COMPILER_PREFIX}-c++)
|
||
|
SET(CMAKE_RC_COMPILER ${COMPILER_PREFIX}-windres)
|
||
|
SET(CMAKE_PKGCONFIG_EXECUTABLE ${COMPILER_PREFIX}-pkg-config)
|
||
|
SET(PKG_CONFIG_EXECUTABLE ${COMPILER_PREFIX}-pkg-config)
|
||
|
|
||
|
set(CMAKE_C_FLAGS "-masm=intel -std=gnu99" CACHE STRING "" FORCE)
|
||
|
set(CMAKE_SHARED_LINKER_FLAGS "-static-libgcc" CACHE STRING "" FORCE)
|
||
|
|
||
|
include_directories("/usr/include/wine/windows/")
|
||
|
|
||
|
# find and include SDL2
|
||
|
INCLUDE(FindPkgConfig)
|
||
|
PKG_SEARCH_MODULE(SDL2 REQUIRED sdl2)
|
||
|
INCLUDE_DIRECTORIES(${SDL2_INCLUDE_DIRS})
|
||
|
|
||
|
# here is the target environment located
|
||
|
SET(CMAKE_FIND_ROOT_PATH /usr/${COMPILER_PREFIX})
|
||
|
|
||
|
# adjust the default behaviour of the FIND_XXX() commands:
|
||
|
# search headers and libraries in the target environment, search
|
||
|
# programs in the host environment
|
||
|
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
|
||
|
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
|
||
|
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
|