diff --git a/src/libs/3rdparty/botan/botan.qbs b/src/libs/3rdparty/botan/botan.qbs index 338612849970da01384944cf8c6f7c88cc5dc6bb..7fe9388e8c3e35cfc765c27863ae0da72f95ccf8 100644 --- a/src/libs/3rdparty/botan/botan.qbs +++ b/src/libs/3rdparty/botan/botan.qbs @@ -8,28 +8,33 @@ DynamicLibrary { Depends { name: "qt"; submodules: 'core' } cpp.includePaths: ["build", "src"] - cpp.staticLibraries: { - if (qbs.targetOS == 'windows') { - return [ - "advapi32.lib", - "user32.lib" - ] - } - } cpp.dynamicLibraries: { if (qbs.targetOS == 'linux' || qbs.targetOS == 'freebsd') { return ['rt'] } + else if (qbs.targetOS == 'windows') { + return [ + "advapi32", + "user32" + ] + } } cpp.defines: { var result = [] - if (qbs.toolchain == 'msvc2005' || qbs.toolchain == 'msvc2005' || qbs.toolchain == 'msvc2008' || qbs.toolchain == 'msvc2010') + if (qbs.toolchain == 'msvc2005' || qbs.toolchain == 'msvc2008' || qbs.toolchain == 'msvc2010') result.push('BOTAN_DLL=__declspec(dllexport)') return result } - // TODO: add those flags to mingw's compiler: -fpermissive -finline-functions -Wno-long-long + Properties { + condition: qbs.toolchain === 'mingw' + cpp.cxxFlags: [ + '-fpermissive', + '-finline-functions', + '-Wno-long-long' + ] + } files: [ "src/algo_factory/algo_cache.h", @@ -536,4 +541,12 @@ DynamicLibrary { "src/timer/posix_rt/tm_posix.cpp" ] } + + ProductModule { + cpp.linkerFlags: { + if (qbs.toolchain === 'mingw') { + return ['--enable-auto-import'] + } + } + } } diff --git a/src/libs/symbianutils/symbianutils.qbs b/src/libs/symbianutils/symbianutils.qbs index ad8b0609f1e227ed455549985d543c269c48f929..7d1b0145913d759076879ad2302fe772c83f95f3 100644 --- a/src/libs/symbianutils/symbianutils.qbs +++ b/src/libs/symbianutils/symbianutils.qbs @@ -12,6 +12,7 @@ DynamicLibrary { ] cpp.defines: [ "SYMBIANUTILS_BUILD_LIB", + "JSON_BUILD_LIB", "HAS_SERIALPORT" ] cpp.optimization: "fast" @@ -59,6 +60,7 @@ DynamicLibrary { "../../shared/json", "." ] + cpp.defines: "JSON_INCLUDE_PRI" } } diff --git a/src/libs/utils/utils.qbs b/src/libs/utils/utils.qbs index c7fe39e52eb706273ff6af614691f860163477f7..3f1b28139ccf0009a746812830af4278c7cd45ae 100644 --- a/src/libs/utils/utils.qbs +++ b/src/libs/utils/utils.qbs @@ -14,7 +14,7 @@ DynamicLibrary { Properties { condition: qbs.targetOS == "windows" - cpp.dynamicLibraries: ["User32.lib"] + cpp.dynamicLibraries: ["user32"] } Depends { name: "cpp" } diff --git a/src/libs/zeroconf/zeroconf.qbs b/src/libs/zeroconf/zeroconf.qbs index f6415d0ee5154d8dd5ffa7fc24d8badc3108ad40..8fadbb2672d973da67f17dc6646e79a34c0edbed 100644 --- a/src/libs/zeroconf/zeroconf.qbs +++ b/src/libs/zeroconf/zeroconf.qbs @@ -8,13 +8,19 @@ DynamicLibrary { Depends { name: "Qt.network" } cpp.includePaths: "." + cpp.defines: ["ZEROCONF_LIBRARY"] Properties { condition: qbs.targetOS == "windows" cpp.dynamicLibraries: "ws2_32" } Properties { condition: qbs.targetOS == "linux" - cpp.defines: [ "_GNU_SOURCE HAVE_IPV6", "USES_NETLINK", "HAVE_LINUX", "TARGET_OS_LINUX" ] + cpp.defines: outer.concat([ + "_GNU_SOURCE HAVE_IPV6", + "USES_NETLINK", + "HAVE_LINUX", + "TARGET_OS_LINUX" + ]) } files: [ diff --git a/src/plugins/coreplugin/coreplugin.qbs b/src/plugins/coreplugin/coreplugin.qbs index d0fbcd5c0ca3ffd236806c79d4e897fa272cdb47..1b4c9c3edd5d4c61b1773ec6cf3c65ce06f5e5c0 100644 --- a/src/plugins/coreplugin/coreplugin.qbs +++ b/src/plugins/coreplugin/coreplugin.qbs @@ -24,9 +24,9 @@ QtcPlugin { buildDirectory ] - cpp.staticLibraries: { + cpp.dynamicLibraries: { if (qbs.targetOS == 'windows') return [ - "ole32.lib" + "ole32" ] } diff --git a/src/plugins/debugger/debugger.qbs b/src/plugins/debugger/debugger.qbs index 6b388894d794f1ebf7ef211d0bcf18aef7d79f2e..4cf39f71e460227091bd5f2ab5238bdf49be2350 100644 --- a/src/plugins/debugger/debugger.qbs +++ b/src/plugins/debugger/debugger.qbs @@ -295,6 +295,15 @@ QtcPlugin { ] } + Properties { + condition: qbs.targetOS == "windows" + cpp.dynamicLibraries: [ + "advapi32", + "ole32", + "shell32" + ] + } + ProductModule { cpp.includePaths: ["."] }