diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 95db36930..fa4ff055d 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -13,17 +13,16 @@ on: jobs: build: runs-on: ubuntu-22.04 + strategy: + matrix: + gcc: ['10.3-2021.10'] steps: - - name: Cache Embedded Arm Toolchain - id: cache-arm-gcc - uses: actions/cache@v2 - env: - cache-name: arm-gcc-10.3-2021-07 + - name: Install Arm GNU Toolchain (arm-none-eabi-gcc) + uses: carlosperate/arm-none-eabi-gcc-action@v1 with: - path: ${{ runner.temp }}/arm-gcc - key: ${{ runner.os }}-${{ env.cache-name }} - restore-keys: ${{ runner.os }}-${{ env.cache-name }} + release: ${{ matrix.gcc }} + path-env-var: ARM_NONE_EABI_GCC_PATH - name: Cache Python modules id: cache-python @@ -43,15 +42,6 @@ jobs: run: | pip3 install --user -r requirements.txt - - name: Install Embedded Arm Toolchain - if: steps.cache-arm-gcc.outputs.cache-hit != 'true' - run: | - curl -O -L https://developer.arm.com/-/media/Files/downloads/gnu-rm/10.3-2021.07/gcc-arm-none-eabi-10.3-2021.07-x86_64-linux.tar.bz2 - md5sum gcc-arm-none-eabi-10.3-2021.07-x86_64-linux.tar.bz2 - echo Installing in ${{ runner.temp }}/arm-gcc - mkdir -p ${{ runner.temp }}/arm-gcc - tar jvxf gcc-arm-none-eabi-10.3-2021.07-x86_64-linux.tar.bz2 -C ${{ runner.temp }}/arm-gcc --strip-components 1 - - name: Install dependencies run: | sudo apt install -y ccache ninja-build diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index be724dc1c..69a4cdbd7 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -5,20 +5,18 @@ on: jobs: build: runs-on: windows-2019 + strategy: + matrix: + gcc: ['10.3-2021.10'] steps: - - name: Cache Embedded Arm Toolchain - id: cache-arm-gcc - uses: actions/cache@v2 - env: - cache-name: arm-gcc-10.3-2021-07 + - name: Install Arm GNU Toolchain (arm-none-eabi-gcc) + uses: carlosperate/arm-none-eabi-gcc-action@v1 with: - path: ${{ runner.temp }}/arm-gcc - key: ${{ runner.os }}-${{ env.cache-name }} - restore-keys: ${{ runner.os }}-${{ env.cache-name }} + release: ${{ matrix.gcc }} - name: Cache Python modules - uses: actions/cache@v2 + uses: actions/cache@v3 with: path: ~\AppData\Local\pip\Cache key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }} @@ -30,30 +28,18 @@ jobs: with: fetch-depth: 0 - - name: Install Embedded Arm Toolchain - if: steps.cache-arm-gcc.outputs.cache-hit != 'true' - run: | - (New-Object System.Net.WebClient).DownloadFile("https://developer.arm.com/-/media/Files/downloads/gnu-rm/10.3-2021.07/gcc-arm-none-eabi-10.3-2021.07-win32.zip","gcc-arm-none-eabi-10.3-2021.07-win32.zip"); - echo "Installing gcc-arm-none-eabi-9-2020-q2-update-win32 in ${{ runner.temp }}\arm-gcc"; - Expand-Archive -Path .\gcc-arm-none-eabi-10.3-2021.07-win32.zip -DestinationPath ${{ runner.temp }} -PassThru; - Rename-Item -Path ${{ runner.temp }}\gcc-arm-none-eabi-10.3-2021.07 -NewName ${{ runner.temp }}\arm-gcc - - - name: Check Embedded Arm Toolchain - run: | - echo ${{ runner.temp }}\arm-gcc\bin | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append - ${{ runner.temp }}\arm-gcc\bin\arm-none-eabi-gcc -v - - name: Install Python module run: | pip install -r requirements.txt - name: Compile run: | + arm-none-eabi-gcc -v python tools/progen_compile.py -t cmake_gcc_arm -g mingw-make --release --parallel -v shell: cmd - name: Upload test artifacts - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v3 with: name: firmware-dev-${{github.run_number}} path: |