blob: a51eb4c40be2560cf9c7e7328ac3aea5edf2108e (
plain)
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
|
import qbs
import qbs.Utilities
CLIModule {
condition: qbs.toolchain.contains("dotnet")
debugInfoSuffix: ".pdb"
csharpCompilerName: "csc"
vbCompilerName: "vbc"
fsharpCompilerName: "fsc"
toolchainInstallPath: Utilities.getNativeSetting(registryKey, "InstallPath")
// private properties
property string registryKey: {
// TODO: Use a probe after QBS-833 is resolved
// Querying the registry on-demand should be fast enough for now
// https://msdn.microsoft.com/en-us/library/hh925568.aspx
var keys = [
"HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\NET Framework Setup\\NDP",
"HKEY_LOCAL_MACHINE\\SOFTWARE\\Wow6432Node\\Microsoft\\NET Framework Setup\\NDP"
];
for (var i in keys) {
var key = keys[i] + "\\v4\\Full";
if (Utilities.getNativeSetting(key, "InstallPath"))
return key;
}
}
}
|