chiark / gitweb /
Use trusty
[nlopt.git] / cmake / toolchain-x86_64-w64-mingw32.cmake
1 set (CMAKE_SYSTEM_NAME Windows)
2
3 # specify the cross compiler
4 set (CMAKE_C_COMPILER x86_64-w64-mingw32-gcc)
5 set (CMAKE_CXX_COMPILER x86_64-w64-mingw32-g++)
6
7 # where is the target environment
8 set (CMAKE_FIND_ROOT_PATH /usr/x86_64-w64-mingw32)
9
10 # search for programs in the build host directories
11 set (CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
12 # for libraries and headers in the target directories
13 set (CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
14 set (CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
15 set (CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)
16
17 # Make sure Qt can be detected by CMake
18 set (QT_BINARY_DIR /usr/x86_64-w64-mingw32/bin /usr/bin)
19 set (QT_INCLUDE_DIRS_NO_SYSTEM ON)
20
21 # set the resource compiler (RHBZ #652435)
22 set (CMAKE_RC_COMPILER x86_64-w64-mingw32-windres)
23 set (CMAKE_MC_COMPILER x86_64-w64-mingw32-windmc)
24
25 # override boost thread component suffix as mingw-w64-boost is compiled with threadapi=win32
26 set (Boost_THREADAPI win32)
27
28 # These are needed for compiling lapack (RHBZ #753906)
29 set (CMAKE_Fortran_COMPILER x86_64-w64-mingw32-gfortran)
30 set (CMAKE_AR:FILEPATH x86_64-w64-mingw32-ar)
31 set (CMAKE_RANLIB:FILEPATH x86_64-w64-mingw32-ranlib)
32