Skip to content

Commit

Permalink
Build all target families in a CI job
Browse files Browse the repository at this point in the history
Try and reenable if

Full send

Fixing build errors and warnings: round 1 of 100000000

Fix Cypress targets to use new form factor names as the old FF was producing #defines that clashed with USB code

Fix some GD32 legacy pin name issues

More Cypress build errors

Rename USB variables

Oops typo

Fix STM32F0 DMA interrupts

Fix some issues with mesh network code building

Add MCU description for MIMXRT1176

Fix H745ZI_Q target name

Add missing cypress secure requirement

Fix every Cypress target trying to write to the same hex file in post build

Missing add_subdirectory

Augh typo

Fix incorrect path to renesas Eth driver

That toshiba target doesn't have CMake build scripts O_O

Add missing add_subdirectory()

Remove noneexistant include

Fix incorrect check for define

Check for both types
  • Loading branch information
multiplemonomials committed Sep 27, 2024
1 parent 4a4e22c commit 5003bac
Show file tree
Hide file tree
Showing 8 changed files with 155 additions and 14 deletions.
143 changes: 136 additions & 7 deletions .github/workflows/greentea_cmake.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,137 @@
name: test building greentea tests with cmake

name: Compile Check
on: [pull_request]

jobs:
build-greentea-cmake:
build-greentea:
runs-on: ubuntu-latest
container: ghcr.io/armmbed/mbed-os-env:master-latest

strategy:
matrix:
include:
## For this matrix, we choose one target from each MCU target family that Mbed supports.
## The target families can be seen here:
## https://mbed-ce.github.io/mbed-ce-test-tools/targets/index.html
## Generally we want to get the most feature-filled MCU of each type so that as much stuff
## compiles as possible -- e.g. prefer a board with ethernet to one without so that we
## can compile the netsocket tests.

# NXP MCUs
- target: LPC1768
profile: full
- target: LPC546XX
profile: full
- target: MIMXRT1060_EVK
profile: full
- target: MIMXRT1170_EVK
profile: full

# Freescale MCUs
- target: K64F
profile: full
- target: KL43Z
profile: full
- target: KW41Z
profile: full

# STM32 MCUs
- target: NUCLEO_F091RC
profile: full
- target: NUCLEO_F103RB
profile: baremetal
- target: NUCLEO_F207ZG
profile: full
- target: NUCLEO_F303RE
profile: full
- target: NUCLEO_F429ZI
profile: full
- target: NUCLEO_F767ZI
profile: full
- target: NUCLEO_G031K8
profile: baremetal
- target: NUCLEO_G431RB
profile: full
- target: NUCLEO_H563ZI
profile: full
- target: NUCLEO_H745ZI_Q_CM7
profile: full
- target: DISCO_L072CZ_LRWAN1
profile: baremetal
- target: XDOT_L151CC
profile: full
- target: DISCO_L4R9I
profile: full
- target: DISCO_L562QE
profile: full
- target: B_U585I_IOT02A
profile: full
- target: NUCLEO_WB55RG
profile: full
- target: NUCLEO_WL55JC
profile: full

# Maxim MCUs
- target: MAX32625MBED
profile: full
- target: XDOT_MAX32670
profile: full

# Nuvoton MCUs
- target: NUMAKER_PFM_NANO130
profile: baremetal
- target: NUMAKER_PFM_M487
profile: full
- target: NU_M2354
profile: full

# Samsung MCUs
- target: S1SBP6A
profile: full

# nRF MCUs
- target: NRF52840_DK
profile: full
- target: ARDUINO_NICLA_SENSE_ME
profile: full

# Toshiba MCUs
- target: TMPM4G9
profile: full

# Renesas MCUs
- target: GR_MANGO
profile: full
- target: RZ_A1H
profile: full

# Ambiq MCUs
- target: SFE_ARTEMIS_DK
profile: full

# Infineon/Cypress MCUs
- target: CY8CKIT_062S2_43012
profile: full
- target: CYTFM_064B0S2_4343W
profile: full

# Analog Devices MCUs
- target: EV_COG_AD4050LZ
profile: full

# GigaDevices MCUs
- target: GD32_F307VG
profile: full
- target: GD32_F450ZI
profile: full

# SiLabs MCUs
- target: EFM32GG11_STK3701
profile: full

# Raspberry Pi MCUs
- target: RASPBERRY_PI_PICO
profile: full

steps:
- name: Checkout
uses: actions/checkout@v3
Expand All @@ -15,14 +141,17 @@ jobs:
apt-get update
apt-get install -y python3-venv
- name: Build NUCLEO_G031K8 with baremetal profile
- name: Build ${{ matrix.target }} with baremetal profile
if: ${{ matrix.profile == 'baremetal' }}
# Note: We have to set a wifi network name and password so that the test will compile on devices that use wifi
run: |
rm -rf __build
cmake -S . -B __build -GNinja -DCMAKE_CTEST_ARGUMENTS="--output-on-failure;-V" -DMBED_BUILD_GREENTEA_TESTS=ON -DMBED_GREENTEA_TEST_BAREMETAL=ON -DMBED_GREENTEA_SERIAL_PORT=/dev/ttyDUMMY -DMBED_TARGET=NUCLEO_G031K8 -DMBED_APP_JSON_PATH=TESTS/configs/baremetal.json
cmake -S . -B __build -GNinja -DUPLOAD_METHOD=NONE -DMBED_GREENTEA_WIFI_SECURE_SSID=SomeNetwork -DMBED_GREENTEA_WIFI_SECURE_PASSWORD=SomePassword -DCMAKE_CTEST_ARGUMENTS="--output-on-failure;-V" -DMBED_BUILD_GREENTEA_TESTS=ON -DMBED_GREENTEA_TEST_BAREMETAL=ON -DMBED_GREENTEA_SERIAL_PORT=/dev/ttyDUMMY -DMBED_TARGET=${{ matrix.target }} -DMBED_APP_JSON_PATH=TESTS/configs/baremetal.json
cmake --build __build
- name: Build ARM_MUSCA_S1 with full profile
- name: Build ${{ matrix.target }} with full profile
if: ${{ matrix.profile == 'full' }}
run: |
rm -rf __build
cmake -S . -B __build -GNinja -DCMAKE_CTEST_ARGUMENTS="--output-on-failure;-V" -DMBED_BUILD_GREENTEA_TESTS=ON -DMBED_GREENTEA_SERIAL_PORT=/dev/ttyDUMMY -DMBED_TARGET=ARM_MUSCA_S1
cmake -S . -B __build -GNinja -DUPLOAD_METHOD=NONE -DMBED_GREENTEA_WIFI_SECURE_SSID=SomeNetwork -DMBED_GREENTEA_WIFI_SECURE_PASSWORD=SomePassword -DCMAKE_CTEST_ARGUMENTS="--output-on-failure;-V" -DMBED_BUILD_GREENTEA_TESTS=ON -DMBED_GREENTEA_SERIAL_PORT=/dev/ttyDUMMY -DMBED_TARGET=${{ matrix.target }}
cmake --build __build
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Copyright (c) 2020 ARM Limited. All rights reserved.
# SPDX-License-Identifier: Apache-2.0

if("CORDIO_ZERO_COPY_HCI=1" IN_LIST MBED_CONFIG_DEFINITIONS)
if("CORDIO_ZERO_COPY_HCI" IN_LIST MBED_CONFIG_DEFINITIONS OR "CORDIO_ZERO_COPY_HCI=1" IN_LIST MBED_CONFIG_DEFINITIONS)
set(TEST_SKIPPED "Test not relevant for zero copy hci.")
endif()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@ target_include_directories(mbed-emac
target_sources(mbed-emac
PRIVATE
rza1_emac.cpp
rza1_eth.cpp
rza1_eth.c
)
1 change: 1 addition & 0 deletions targets/TARGET_Maxim/TARGET_MAX32670/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
# SPDX-License-Identifier: Apache-2.0

add_subdirectory(TARGET_MAX32670EVKIT EXCLUDE_FROM_ALL)
add_subdirectory(TARGET_XDOT_MAX32670 EXCLUDE_FROM_ALL)

if(${MBED_TOOLCHAIN} STREQUAL "ARM")
set(LINKER_FILE device/TOOLCHAIN_ARM_STD/MAX32670.sct)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@
#include "mxc_assert.h"
#include "mxc_sys.h"
#include "mxc_delay.h"
#include "aes.h"
#include "flc.h"
#include "gcr_regs.h"
#include "fcr_regs.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,7 @@ typedef enum {
#define LED3 P6_15
#define LED4 P6_12

LED_RED = LED1,
LED_GREEN= LED2,
LED_BLUE = LED3,
LED_USER = LED4,
#define BUTTON0 P6_0

CONSOLE_TX = P6_3,
CONSOLE_RX = P6_2,
Expand Down
9 changes: 9 additions & 0 deletions targets/TARGET_STM/stm_dma_utils.c
Original file line number Diff line number Diff line change
Expand Up @@ -396,6 +396,15 @@ IRQn_Type stm_get_dma_irqn(const DMALinkInfo *dmaLink)
case 4:
case 5:
return DMA1_Ch4_7_DMA2_Ch1_5_DMAMUX1_OVR_IRQn;
#elif defined(TARGET_MCU_STM32F0)
// STM32F0 has a rather bespoke mapping
case 1:
case 2:
return DMA1_Ch2_3_DMA2_Ch1_2_IRQn;
case 3:
case 4:
case 5:
return DMA1_Ch4_7_DMA2_Ch3_5_IRQn;
#else

#ifdef DMA2_Channel1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,12 @@
#ifndef EM_DEVICE_H
#define EM_DEVICE_H

// MBED: The CMake scripts always define __FPU_PRESENT, but the MCU CMSIS headers below also define it.
// So, undef it here to prevent multiple definition warning.
#ifdef __FPU_PRESENT
#undef __FPU_PRESENT
#endif

#if defined(EFM32GG11B110F2048GM64)
#include "efm32gg11b110f2048gm64.h"

Expand Down

0 comments on commit 5003bac

Please sign in to comment.