1 # the name of the target operating system
2 SET(CMAKE_SYSTEM_NAME Windows)
4 # which compilers to use for C and C++
5 SET(CMAKE_C_COMPILER i686-w64-mingw32-gcc)
6 SET(CMAKE_CXX_COMPILER i686-w64-mingw32-g++)
7 SET(CMAKE_RC_COMPILER i686-w64-mingw32-windres)
9 # here is the target environment located
10 SET(CMAKE_FIND_ROOT_PATH /usr/i686-w64-mingw32
11 /usr/local/i586-mingw-msvc
12 /usr/local/i586-mingw-msvc/SDL/i686-w64-mingw32
13 /usr/local/i586-mingw-msvc/5.5/mingw492_32)
17 # adjust the default behaviour of the FIND_XXX() commands:
18 # search headers and libraries in the target environment, search
19 # programs in the host environment
20 set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
21 set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
22 set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
25 /usr/local/i586-mingw-msvc/SDL/i686-w64-mingw32/lib/libSDL2.dll.a
26 /usr/local/i586-mingw-msvc/SDL/i686-w64-mingw32/lib/libSDL2main.a)
27 set(SDL2_INCLUDE_DIRS /usr/local/i586-mingw-msvc/SDL/i686-w64-mingw32/include/SDL2)
28 set(SDLMAIN_LIBRARY "")
30 set(ADDITIONAL_LIBRARIES libwinmm.a)
31 set(CMAKE_EXE_LINKER_FLAGS "-static-libgcc -static-libstdc++")