CodeQL #66
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "CodeQL" | |
on: | |
push: | |
branches: [ master, dev-r3.5_xFSK] | |
pull_request: | |
# The branches below must be a subset of the branches above | |
branches: [ master, dev-r3.5_xFSK] | |
schedule: | |
- cron: '19 17 * * 3' | |
jobs: | |
analyze: | |
name: Analyze | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- BOARD: nano | |
RECEIVER: cc1101 | |
arduino-platform: 'arduino:avr' | |
fqbn: 'arduino:avr:nano:cpu=atmega328' | |
compilerflag: '\"-DOTHER_BOARD_WITH_CC1101=1\"' | |
- BOARD: nano328 | |
RECEIVER: "" | |
arduino-platform: 'arduino:avr' | |
fqbn: 'arduino:avr:nano:cpu=atmega328' | |
- BOARD: radino | |
RECEIVER: cc1101 | |
arduino-platform: 'arduino:avr In-Circuit:avr' | |
fqbn: 'In-Circuit:avr:radinoCC1101' | |
boardurl: '--additional-urls=http://library.radino.cc/Arduino_1_8/package_radino_radino32_index.json' | |
compilerflag: \"-DARDUINO_RADINOCC1101=1\" | |
build_param1: "compiler.path={runtime.tools.avr-gcc-7.3.0-atmel3.6.1-arduino7.path}/bin/" | |
- BOARD: minicul | |
RECEIVER: cc1101 | |
arduino-platform: 'arduino:avr' | |
fqbn: 'arduino:avr:pro:cpu=8MHzatmega328' | |
compilerflag: \"-DARDUINO_ATMEGA328P_MINICUL=1\" | |
- BOARD: promini | |
RECEIVER: "" | |
arduino-platform: 'arduino:avr' | |
fqbn: 'arduino:avr:pro:cpu=8MHzatmega328' | |
- BOARD: ESP32 | |
RECEIVER: cc1101 | |
arduino-platform: 'esp32:esp32' | |
fqbn: 'esp32:esp32:esp32:FlashMode=qio,FlashFreq=80' | |
compilerflag: \"-DOTHER_BOARD_WITH_CC1101=1\" | |
boardurl: '--additional-urls=https://dl.espressif.com/dl/package_esp32_index.json' | |
- BOARD: ESP32 | |
RECEIVER: "" | |
arduino-platform: 'esp32:esp32' | |
fqbn: 'esp32:esp32:esp32:FlashMode=qio,FlashFreq=80' | |
boardurl: '--additional-urls=https://dl.espressif.com/dl/package_esp32_index.json' | |
- BOARD: ESP8266 | |
RECEIVER: cc1101 | |
arduino-platform: 'esp8266:[email protected]' | |
fqbn: 'esp8266:esp8266:generic:xtal=80,eesz=1M64,FlashMode=qio,FlashFreq=40,dbg=Serial,lvl=CORE' | |
compilerflag: \"-DOTHER_BOARD_WITH_CC1101=1\" | |
boardurl: '--additional-urls=http://arduino.esp8266.com/stable/package_esp8266com_index.json' | |
- BOARD: ESP8266 | |
RECEIVER: "" | |
arduino-platform: 'esp8266:[email protected]' | |
fqbn: 'esp8266:esp8266:generic:xtal=80,eesz=1M64,FlashMode=qio,FlashFreq=40,dbg=Serial,lvl=CORE' | |
boardurl: '--additional-urls=http://arduino.esp8266.com/stable/package_esp8266com_index.json' | |
- BOARD: MAPLEMINI_F103CB | |
RECEIVER: cc1101 | |
arduino-platform: 'STM32:stm32' | |
fqbn: 'STM32:stm32:GenF1:pnum=MAPLEMINI_F103CB' | |
compilerflag: \"-DOTHER_BOARD_WITH_CC1101=1\" | |
boardurl: '--additional-urls=https://github.com/stm32duino/BoardManagerFiles/raw/master/STM32/package_stm_index.json' | |
- BOARD: MAPLEMINI_F103CB | |
RECEIVER: "" | |
arduino-platform: 'STM32:stm32' | |
fqbn: 'STM32:stm32:GenF1:pnum=MAPLEMINI_F103CB' | |
boardurl: '--additional-urls=https://github.com/stm32duino/BoardManagerFiles/raw/master/STM32/package_stm_index.json' | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
with: | |
submodules: true | |
- name: Initialize CodeQL | |
uses: github/codeql-action/init@v2 | |
with: | |
languages: cpp | |
- name: Install Arduino CLI | |
uses: arduino/[email protected] | |
- name: Setup arduino-cli | |
uses: ./.github/actions/arduino-cli | |
with: | |
boardurl: ${{ matrix.boardurl }} | |
plattform: ${{ matrix.arduino-platform }} | |
- name: Static link | |
run: | |
| | |
# static link fix from https://github.com/github/securitylab/discussions/171 | |
for file in ~/.arduino15/packages/*/tools/*-gcc/*/bin/*; do | |
if [ -x "$file" ] | |
then | |
mv "$file" "$file.real"; | |
printf '#!/bin/bash\nexec "'"$file"'.real" ${1+"$@"}\n' > "$file"; | |
chmod +x "$file"; | |
fi; | |
done; | |
- name: Compile sketch | |
id: compile_sketch | |
run: | |
arduino-cli compile --fqbn ${{ matrix.fqbn }} --build-property="compiler.cpp.extra_flags=${{ matrix.compilerflag }}" ${{ matrix.boardurl }} --build-property="${{ matrix.build_param1 }}" --output-dir=$GITHUB_WORKSPACE $GITHUB_WORKSPACE/src/arduino-ide/SIGNALDuino/SIGNALDuino.ino --warnings=all | |
- name: Perform CodeQL Analysis | |
uses: github/codeql-action/analyze@v2 |