aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/blackbox/testdata-baremetal/one-object-asm-application/one-object-asm-application.qbs
blob: cd1413d6f9628d07cd9cdb22709202f17ca41eb4 (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
30
31
32
33
34
35
36
37
38
39
40
41
import "../BareMetalApplication.qbs" as BareMetalApplication

BareMetalApplication {
    condition: {
        if (qbs.toolchainType === "keil") {
            if (qbs.architecture.startsWith("arm"))
                return true;
            if (qbs.architecture === "mcs51")
                return true;
        } else if (qbs.toolchainType === "iar") {
            if (qbs.architecture === "mcs51")
                return true;
        } else if (qbs.toolchainType === "sdcc") {
            if (qbs.architecture === "mcs51")
                return true;
            if (qbs.architecture === "stm8")
                return true;
        } else if (qbs.toolchainType === "gcc") {
            if (qbs.architecture.startsWith("arm"))
                return true;
            if (qbs.architecture === "avr")
                return true;
            if (qbs.architecture === "msp430")
                return true;
        }
        console.info("unsupported toolset: %%"
            + qbs.toolchainType + "%%, %%" + qbs.architecture + "%%");
        return false;
    }

    Properties {
        condition: qbs.toolchainType === "gcc"
            && qbs.architecture === "msp430"
        // We need to use this workaround to enable
        // the cpp.driverFlags property.
        cpp.linkerPath: cpp.compilerPathByLanguage["c"]
    }

    files: [(qbs.architecture.startsWith("arm") ? "arm" : qbs.architecture)
                + "-" + qbs.toolchainType + ".s"]
}