diff options
4 files changed, 21 insertions, 0 deletions
diff --git a/examples/baremetal/msp430f5529/redblink/README.md b/examples/baremetal/msp430f5529/redblink/README.md index ccd314bab..3affbaf7e 100644 --- a/examples/baremetal/msp430f5529/redblink/README.md +++ b/examples/baremetal/msp430f5529/redblink/README.md @@ -6,3 +6,4 @@ LED on the board. The following toolchains are supported: * IAR Embedded Workbench + * GCC diff --git a/examples/baremetal/msp430f5529/redblink/gpio.c b/examples/baremetal/msp430f5529/redblink/gpio.c index 893f4c71d..3e7f181aa 100644 --- a/examples/baremetal/msp430f5529/redblink/gpio.c +++ b/examples/baremetal/msp430f5529/redblink/gpio.c @@ -52,6 +52,8 @@ #if defined(__ICC430__) #include <msp430f5529.h> +#elif defined(__GNUC__) +#include <msp430f5529.h> #else #error "Unsupported toolchain" #endif diff --git a/examples/baremetal/msp430f5529/redblink/redblink.qbs b/examples/baremetal/msp430f5529/redblink/redblink.qbs index 1d02ae77e..0f056e101 100644 --- a/examples/baremetal/msp430f5529/redblink/redblink.qbs +++ b/examples/baremetal/msp430f5529/redblink/redblink.qbs @@ -55,6 +55,7 @@ CppApplication { if (!qbs.architecture.contains("msp430")) return false; return qbs.toolchain.contains("iar") + || qbs.toolchain.contains("gcc") } name: "msp430f5529-redblink" cpp.cLanguageVersion: "c99" @@ -94,6 +95,21 @@ CppApplication { } // + // GCC-specific properties and soucres. + // + + Properties { + condition: qbs.toolchain.contains("gcc") + property path supportFilesPath + // A path to the MSP430 support files, which are + // provided by the Texas Instruments separately: + // e.g. 'c:/msp430-gcc-support-files/include/' + cpp.includePaths: supportFilesPath + cpp.libraryPaths: supportFilesPath + cpp.driverFlags: ["-mmcu=msp430f5529"] + } + + // // Common code. // diff --git a/examples/baremetal/msp430f5529/redblink/system.c b/examples/baremetal/msp430f5529/redblink/system.c index f3c121d55..0e0e6901c 100644 --- a/examples/baremetal/msp430f5529/redblink/system.c +++ b/examples/baremetal/msp430f5529/redblink/system.c @@ -52,6 +52,8 @@ #if defined(__ICC430__) #include <msp430f5529.h> +#elif defined(__GNUC__) +#include <msp430f5529.h> #else #error "Unsupported toolchain" #endif |