1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
|
import qbs.Utilities
// a specific version of the operating systems is specified
// when the application is run its output should confirm
// that the given values took effect
import qbs.Host
CppApplication {
condition: {
var result = qbs.targetPlatform === Host.platform() && qbs.architecture === Host.architecture();
if (!result)
console.info("target platform/arch differ from host platform/arch");
return result && qbs.targetOS.includes("windows") || qbs.targetOS.includes("macos");
}
files: [qbs.targetOS.includes("darwin") ? "main.mm" : "main.cpp"]
consoleApplication: true
Properties {
condition: qbs.targetOS.includes("windows")
cpp.minimumWindowsVersion: "6.2"
cpp.defines: [
"QBS_WINVER=0x602",
"TOOLCHAIN_INSTALL_PATH=" + Utilities.cStringQuote(cpp.toolchainInstallPath)
]
}
Properties {
condition: qbs.targetOS.includes("macos")
cpp.frameworks: "Foundation"
cpp.minimumMacosVersion: qbs.architecture === "arm64" ? "11.0" : "10.7"
}
}
|