mirror of
https://github.com/thorvg/thorvg.git
synced 2025-06-28 10:52:16 +00:00

If the unit test is successful, valgrind memory check is executed based on the test. If a leak occurs in the test result, the bot notifies the PR as a comment. This notify may not be directly related to the created current PR. (Asan is on hold because it is not well tested in the github action CI environment.)
99 lines
2.5 KiB
YAML
99 lines
2.5 KiB
YAML
name: Build Linux
|
|
|
|
on:
|
|
pull_request:
|
|
branches:
|
|
- master
|
|
push:
|
|
branches:
|
|
- master
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-18.04
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
with:
|
|
submodules: true
|
|
|
|
- name: Install Packages
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get install ninja-build gcc-multilib g++-multilib meson
|
|
|
|
- name: Install TurboJPEG library
|
|
run: sudo apt-get install libturbojpeg0-dev libjpeg8-dev
|
|
|
|
- name: Build
|
|
run: |
|
|
meson . build -Dlog=true -Dloaders="svg, tvg, png, jpg" -Dsavers="tvg"
|
|
cd build
|
|
sudo ninja -C . install
|
|
|
|
examples:
|
|
runs-on: ubuntu-18.04
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
with:
|
|
submodules: true
|
|
|
|
- name: Install Packages
|
|
run: |
|
|
sudo apt-get update
|
|
sudo add-apt-repository ppa:niko2040/e19
|
|
sudo apt-get install ninja-build gcc-multilib g++-multilib meson
|
|
sudo apt-get install libefl-dev
|
|
|
|
- name: Install TurboJPEG library
|
|
run: sudo apt-get install libturbojpeg0-dev libjpeg8-dev
|
|
|
|
- name: Build
|
|
run: |
|
|
meson . build -Dexamples=true -Dloaders="svg, tvg, png, jpg" -Dsavers="tvg"
|
|
cd build
|
|
sudo ninja -C . install
|
|
|
|
unit_test:
|
|
runs-on: ubuntu-18.04
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
with:
|
|
submodules: true
|
|
|
|
- name: Install Packages
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get install ninja-build gcc-multilib g++-multilib libgtest-dev meson cmake cmake-data libasan5 valgrind
|
|
sudo apt-get install curl jq
|
|
sudo apt-get install software-properties-common
|
|
|
|
- name: Install TurboJPEG library
|
|
run: sudo apt-get install libturbojpeg0-dev libjpeg8-dev
|
|
|
|
- name: Install-ThorVG
|
|
run: |
|
|
meson . build -Dloaders="svg, tvg, png, jpg" -Dsavers="tvg" -Dbindings="capi"
|
|
cd build
|
|
sudo ninja -C . install
|
|
cd ..
|
|
sudo rm -rf ./build
|
|
|
|
- name: Build
|
|
run: |
|
|
meson . build -Dtests=true -Dloaders="svg, tvg, png, jpg" -Dsavers="tvg" -Dbindings="capi" --errorlogs
|
|
cd build
|
|
sudo ninja -C . install test
|
|
|
|
- uses: actions/upload-artifact@v2
|
|
with:
|
|
name: UnitTestReport
|
|
path: build/meson-logs/testlog.txt
|
|
|
|
- name: Run memcheck Script(valgrind)
|
|
run: |
|
|
export PATH=$PATH:~/.local/bin/
|
|
chmod +x "${GITHUB_WORKSPACE}/.github/workflows/memcheck_valgrind.sh"
|
|
"${GITHUB_WORKSPACE}/.github/workflows/memcheck_valgrind.sh"
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
|