summaryrefslogtreecommitdiff
path: root/cmake/Toolchain-mingw64.cmake
diff options
context:
space:
mode:
authorMichal Čihař <michal@cihar.com>2011-03-15 17:17:10 +0100
committerMichal Čihař <michal@cihar.com>2011-03-15 17:17:10 +0100
commit477cceca6e30f94c6fe4673266a56804378ff935 (patch)
tree252bd68d654f98ac5726e347a1281aecc7c19d1e /cmake/Toolchain-mingw64.cmake
parent88e15062c1d36ed989ff154b1ecf644824a3728d (diff)
Imported Upstream version 1.29.92
Diffstat (limited to 'cmake/Toolchain-mingw64.cmake')
-rw-r--r--cmake/Toolchain-mingw64.cmake36
1 files changed, 36 insertions, 0 deletions
diff --git a/cmake/Toolchain-mingw64.cmake b/cmake/Toolchain-mingw64.cmake
new file mode 100644
index 0000000..2e11489
--- /dev/null
+++ b/cmake/Toolchain-mingw64.cmake
@@ -0,0 +1,36 @@
+# Toolchain configuration for SUSE/Fedora like MinGW32 setup
+
+# the name of the target operating system
+SET(CMAKE_SYSTEM_NAME Windows)
+
+# which compilers to use for C and C++
+SET(CMAKE_C_COMPILER x86_64-pc-mingw32-gcc)
+SET(CMAKE_CXX_COMPILER x86_64-pc-mingw32-g++)
+SET(CMAKE_AR x86_64-pc-mingw32-ar)
+SET(CMAKE_LD x86_64-pc-mingw32-ld)
+SET(CMAKE_NM x86_64-pc-mingw32-nm)
+SET(CMAKE_OBJCOPY x86_64-pc-mingw32-objcopy)
+SET(CMAKE_OBJDUMP x86_64-pc-mingw32-objdump)
+SET(CMAKE_RANLIB x86_64-pc-mingw32-ranlib)
+SET(CMAKE_STRIP x86_64-pc-mingw32-strip)
+
+# here is the target environment located
+SET(CMAKE_FIND_ROOT_PATH /usr/x86_64-pc-mingw32/sys-root/mingw/)
+
+# 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)
+
+# Windows libraries names
+set(WIN_LIB_ICONV) # builtin
+set(WIN_LIB_INTL libintl-8.dll)
+set(WIN_LIB_CURL libcurl-4.dll libidn-11.dll libnspr4.dll nss3.dll libssh2-1.dll ssl3.dll zlib1.dll nssutil3.dll libplc4.dll libplds4.dll libgcrypt-11.dll libgpg-error-0.dll)
+set(WIN_LIB_MYSQL libmysql.dll)
+set(WIN_LIB_PGSQL libpq.dll)
+set(WIN_LIB_GLIB libglib-2.0-0.dll libgobject-2.0-0.dll libgthread-2.0-0.dll)
+
+# Disable pkg-config lookups
+set(PKG_CONFIG_EXECUTABLE /bin/false)