mirror of
https://github.com/ZDoom/fluidsynth.git
synced 2025-02-28 22:51:29 +00:00
Add SonarQube static code analysis (#671)
This commit is contained in:
parent
23b270c08b
commit
565002f34f
2 changed files with 35 additions and 2 deletions
21
.travis.yml
21
.travis.yml
|
@ -2,6 +2,8 @@ language: c
|
||||||
sudo: false
|
sudo: false
|
||||||
os: linux
|
os: linux
|
||||||
dist: focal
|
dist: focal
|
||||||
|
git:
|
||||||
|
depth: false # disable shallow fetch, history is needed by SonarQube
|
||||||
addons:
|
addons:
|
||||||
apt:
|
apt:
|
||||||
update: true
|
update: true
|
||||||
|
@ -37,6 +39,13 @@ env:
|
||||||
|
|
||||||
matrix:
|
matrix:
|
||||||
include:
|
include:
|
||||||
|
- addons:
|
||||||
|
sonarcloud:
|
||||||
|
organization: "fluidsynth"
|
||||||
|
env:
|
||||||
|
- BW="build-wrapper-linux-x86-64 --out-dir bw-output"
|
||||||
|
- SONARSC="sonar-scanner -Dsonar.cfamily.build-wrapper-output=build/bw-output"
|
||||||
|
|
||||||
- arch: arm64
|
- arch: arm64
|
||||||
env:
|
env:
|
||||||
- CC="gcc-7"
|
- CC="gcc-7"
|
||||||
|
@ -84,6 +93,7 @@ before_install:
|
||||||
- echo $PATH
|
- echo $PATH
|
||||||
- echo $MATRIX_EVAL
|
- echo $MATRIX_EVAL
|
||||||
- eval "${MATRIX_EVAL}"
|
- eval "${MATRIX_EVAL}"
|
||||||
|
- echo $SONARSC
|
||||||
|
|
||||||
before_script:
|
before_script:
|
||||||
- mkdir $HOME/fluidsynth_install/
|
- mkdir $HOME/fluidsynth_install/
|
||||||
|
@ -91,6 +101,13 @@ before_script:
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- cmake -Werror=dev -DCMAKE_INSTALL_PREFIX=$HOME/fluidsynth_install ${CMAKE_FLAGS} -Denable-portaudio=1 -Denable-ladspa=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_VERBOSE_MAKEFILE=1 -DNO_GUI=1 ..
|
- cmake -Werror=dev -DCMAKE_INSTALL_PREFIX=$HOME/fluidsynth_install ${CMAKE_FLAGS} -Denable-portaudio=1 -Denable-ladspa=1 -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_VERBOSE_MAKEFILE=1 -DNO_GUI=1 ..
|
||||||
- make -j4
|
- ${BW} make -j4
|
||||||
|
- ls -la
|
||||||
- make check
|
- make check
|
||||||
- make install # install only on linux, as CMAKE_INSTALL_PREFIX is ignored for frameworks on macosx and I cant tell whether that's correct or a bug.
|
- make install
|
||||||
|
- cd ..
|
||||||
|
- ${SONARSC}
|
||||||
|
|
||||||
|
cache:
|
||||||
|
directories:
|
||||||
|
- '$HOME/.sonar/cache'
|
||||||
|
|
16
sonar-project.properties
Normal file
16
sonar-project.properties
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
sonar.projectKey=FluidSynth_fluidsynth
|
||||||
|
sonar.organization=fluidsynth
|
||||||
|
|
||||||
|
sonar.cfamily.threads=4
|
||||||
|
sonar.cfamily.cache.enabled=false
|
||||||
|
|
||||||
|
|
||||||
|
# This is the name and version displayed in the SonarCloud UI.
|
||||||
|
#sonar.projectName=fluidsynth
|
||||||
|
#sonar.projectVersion=1.0
|
||||||
|
|
||||||
|
# Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows.
|
||||||
|
#sonar.sources=.
|
||||||
|
|
||||||
|
# Encoding of the source code. Default is default system encoding
|
||||||
|
#sonar.sourceEncoding=UTF-8
|
Loading…
Reference in a new issue