1name: FreeRTOS-Kernel Demos 2on: [push, pull_request] 3 4jobs: 5 WIN32-MSVC: 6 name: WIN32 MSVC 7 runs-on: windows-latest 8 steps: 9 - name: Checkout the FreeRTOS/FreeRTOS Repository 10 uses: actions/checkout@v3 11 with: 12 ref: main 13 repository: FreeRTOS/FreeRTOS 14 submodules: 'recursive' 15 fetch-depth: 1 16 17 # Checkout user pull request changes 18 - name: Checkout Pull Request 19 uses: actions/checkout@v3 20 with: 21 path: ./FreeRTOS/Source 22 23 - name: Add msbuild to PATH 24 uses: microsoft/setup-msbuild@v1.1 25 26 - name: Build WIN32-MSVC Demo 27 working-directory: FreeRTOS/Demo/WIN32-MSVC 28 run: msbuild WIN32.sln -t:rebuild 29 30 - name: Build WIN32-MSVC-Static-Allocation-Only Demo 31 working-directory: FreeRTOS/Demo/WIN32-MSVC-Static-Allocation-Only 32 run: msbuild WIN32.sln -t:rebuild 33 34 WIN32-MingW: 35 name: WIN32 MingW 36 runs-on: windows-latest 37 steps: 38 - name: Checkout the FreeRTOS/FreeRTOS Repository 39 uses: actions/checkout@v3 40 with: 41 ref: main 42 repository: FreeRTOS/FreeRTOS 43 submodules: 'recursive' 44 fetch-depth: 1 45 46 # Checkout user pull request changes 47 - name: Checkout Pull Request 48 uses: actions/checkout@v3 49 with: 50 path: ./FreeRTOS/Source 51 52 - name: Build WIN32-MingW Demo 53 working-directory: FreeRTOS/Demo/WIN32-MingW 54 run: | 55 gcc --version 56 make --version 57 make 58 59 POSIX-GCC: 60 name: Native GCC 61 runs-on: ubuntu-latest 62 steps: 63 - name: Checkout the FreeRTOS/FreeRTOS Repository 64 uses: actions/checkout@v3 65 with: 66 ref: main 67 repository: FreeRTOS/FreeRTOS 68 submodules: 'recursive' 69 fetch-depth: 1 70 71 # Checkout user pull request changes 72 - name: Checkout Pull Request 73 uses: actions/checkout@v3 74 with: 75 path: ./FreeRTOS/Source 76 77 - name: Install GCC 78 shell: bash 79 run: | 80 sudo apt-get -y update 81 sudo apt-get -y install build-essential 82 83 - name: Build Posix_GCC Demo 84 shell: bash 85 working-directory: FreeRTOS/Demo/Posix_GCC 86 run: make -j 87 88 - name: Build Posix_GCC Demo for Coverage Test 89 shell: bash 90 working-directory: FreeRTOS/Demo/Posix_GCC 91 run: make -j COVERAGE_TEST=1 92 93 CMake-Example: 94 name: CMake Example with Native GCC 95 runs-on: ubuntu-latest 96 steps: 97 # Checkout user pull request changes 98 - name: Checkout Repository 99 uses: actions/checkout@v3 100 101 - name: Install GCC 102 shell: bash 103 run: | 104 sudo apt-get -y update 105 sudo apt-get -y install build-essential 106 107 - name: Build CMake Example Demo 108 shell: bash 109 working-directory: examples/cmake_example 110 run: | 111 cmake -S . -B build 112 cmake --build build 113 114 - name: Build CMake SMP Example Demo 115 shell: bash 116 working-directory: examples/cmake_example 117 run: | 118 cmake -S . -B build -DFREERTOS_SMP_EXAMPLE=1 119 cmake --build build 120 121 MSP430-GCC: 122 name: GNU MSP430 Toolchain 123 runs-on: ubuntu-latest 124 steps: 125 - name: Checkout the FreeRTOS/FreeRTOS Repository 126 uses: actions/checkout@v3 127 with: 128 ref: main 129 repository: FreeRTOS/FreeRTOS 130 submodules: 'recursive' 131 fetch-depth: 1 132 133 # Checkout user pull request changes 134 - name: Checkout Pull Request 135 uses: actions/checkout@v3 136 with: 137 path: ./FreeRTOS/Source 138 139 - name: Install MSP430 Toolchain 140 shell: bash 141 run: | 142 sudo apt-get -y update 143 sudo apt-get -y install gcc-msp430 build-essential 144 145 - name: Build msp430_GCC Demo 146 shell: bash 147 working-directory: FreeRTOS/Demo/msp430_GCC 148 run: make -j 149 150 ARM-GCC: 151 name: GNU ARM Toolchain 152 runs-on: ubuntu-latest 153 steps: 154 - name: Checkout the FreeRTOS/FreeRTOS Repository 155 uses: actions/checkout@v3 156 with: 157 ref: main 158 repository: FreeRTOS/FreeRTOS 159 fetch-depth: 1 160 161 - name: Fetch Community-Supported-Demos Submodule 162 shell: bash 163 run: | 164 # Fetch Community-Supported-Demos Submodule 165 echo "::group::Fetch Community-Supported-Demos Submodule" 166 git submodule update --checkout --init --depth 1 FreeRTOS/Demo/ThirdParty/Community-Supported-Demos 167 echo "::engdroup::" 168 if [ "$?" = "0" ]; then 169 echo -e "\033[32;3mCloned the Community-Supported-Demos\033[0m" 170 else 171 echo -e "\033[32;31mCommunity-Supported-Demos Clone Failed...\033[0m" 172 exit 1 173 fi 174 175 # Checkout user pull request changes 176 - name: Checkout Pull Request 177 uses: actions/checkout@v3 178 with: 179 path: ./FreeRTOS/Source 180 181 - name: Install GNU ARM Toolchain 182 shell: bash 183 run: | 184 sudo apt-get -y update 185 sudo apt-get -y install gcc-arm-none-eabi build-essential cmake git ninja-build python3-minimal 186 187 - name: Build CORTEX_MPU_M3_MPS2_QEMU_GCC Demo 188 shell: bash 189 working-directory: FreeRTOS/Demo/CORTEX_MPU_M3_MPS2_QEMU_GCC 190 run: make -j 191 192 - name: Build CORTEX_LM3S102_GCC Demo 193 shell: bash 194 working-directory: FreeRTOS/Demo/CORTEX_LM3S102_GCC 195 run: make -j 196 197 - name: Build CORTEX_LM3S811_GCC Demo 198 shell: bash 199 working-directory: FreeRTOS/Demo/CORTEX_LM3S811_GCC 200 run: make -j 201 202 - name: Build CORTEX_M0+_RP2040 Demos 203 shell: bash 204 working-directory: FreeRTOS/Demo/ThirdParty/Community-Supported-Demos/CORTEX_M0+_RP2040 205 run: | 206 git clone https://github.com/raspberrypi/pico-sdk.git 207 cmake -B build -DPICO_SDK_PATH=pico-sdk -GNinja 208 ninja -C build --verbose 209 210 - name: Build CORTEX_MPS2_QEMU_IAR_GCC Demo 211 shell: bash 212 working-directory: FreeRTOS/Demo/CORTEX_MPS2_QEMU_IAR_GCC 213 run: make -C build/gcc -j 214