Skip to content

Commit

Permalink
build(ci): add asan, ubsan, cleanup build
Browse files Browse the repository at this point in the history
  • Loading branch information
metamacro committed Sep 10, 2023
1 parent 468ab66 commit b079f8f
Showing 1 changed file with 13 additions and 10 deletions.
23 changes: 13 additions & 10 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
- id: get-git-branch
run: |
if ${{ github.event_name == 'push' }}
then export GIT_BRANCH=`echo ${{ github.ref }} | cut -d'/' -f 3`
then export GIT_BRANCH=$(echo ${{ github.ref }} | cut -d'/' -f 3)
else
export GIT_BRANCH=${{ github.base_ref }}
fi
Expand All @@ -31,35 +31,38 @@ jobs:
config:
- {
name: "Release, gcc",
os: "ubuntu-22.04",
os: "ubuntu-latest",
build-type: "Release",
cc: "gcc",
options: "",
make-target: ""
}
- {
name: "Release, clang",
os: "ubuntu-22.04",
os: "ubuntu-latest",
build-type: "Release",
cc: "clang",
options: "",
make-target: ""
}
- {
name: "Debug, gcc",
os: "ubuntu-22.04",
os: "ubuntu-latest",
build-type: "Debug",
cc: "gcc",
options: "-D ENABLE_DEBUG=ON",
make-target: ""
}
- {
name: "Debug, clang",
os: "ubuntu-22.04",
os: "ubuntu-latest",
build-type: "Debug",
cc: "clang",
options: "-D ENABLE_DEBUG=ON",
make-target: ""
}
- {
name: "Asan, Ubsan",
os: "ubuntu-latest",
build-type: "Debug",
cc: "clang",
options: "-D CMAKE_C_FLAGS=-fsanitize=address,undefined -D ENABLE_DEBUG=ON",
}

steps:
Expand All @@ -78,5 +81,5 @@ jobs:
working-directory: ${{ github.workspace }}/build
run: |
export LC_ALL=C.UTF-8
make ${{ matrix.config.make-target }}
make

0 comments on commit b079f8f

Please sign in to comment.