ulib/.gitea/workflows/build.yaml
tqcq 93fbf50c8f
Some checks failed
rpcrypto-build / build (Debug, mipsel-openwrt-linux.toolchain.cmake) (push) Failing after 1m56s
rpcrypto-build / build (Debug, hisiv510.toolchain.cmake) (push) Successful in 1m57s
rpcrypto-build / build (Release, mipsel-openwrt-linux.toolchain.cmake) (push) Failing after 1m49s
rpcrypto-build / build (Release, hisiv510.toolchain.cmake) (push) Successful in 2m3s
rpcrypto-build / build (Release, mipsel-openwrt-linux-musl.toolchain.cmake) (push) Failing after 1h21m45s
rpcrypto-build / build (Release, himix200.toolchain.cmake) (push) Successful in 1h21m51s
rpcrypto-build / build (Debug, mipsel-openwrt-linux-musl.toolchain.cmake) (push) Failing after 1h22m42s
rpcrypto-build / build (Debug, himix200.toolchain.cmake) (push) Successful in 1h22m52s
linux-hisiv500-gcc / linux-gcc-hisiv500 (push) Failing after 1h25m6s
feature modify images
2023-12-08 13:38:46 +08:00

96 lines
3.4 KiB
YAML

name: rpcrypto-build
on:
push:
paths:
- '.gitea/workflows/build.yaml'
- 'toolchains/hisiv510.toolchain.cmake'
- 'toolchains/himix200.toolchain.cmake'
- 'toolchains/mipsel-openwrt-linux-musl.toolchain.cmake'
- 'toolchains/mipsel-openwrt-linux.toolchain.cmake'
- 'src/**'
- 'tests/**'
- 'CMakeLists.txt'
- 'cmake/**'
pull_request:
paths:
- '.gitea/workflows/build.yaml'
- 'toolchains/hisiv510.toolchain.cmake'
- 'toolchains/himix200.toolchain.cmake'
- 'toolchains/mipsel-openwrt-linux-musl.toolchain.cmake'
- 'toolchains/mipsel-openwrt-linux.toolchain.cmake'
- 'src/**'
- 'tests/**'
- 'CMakeLists.txt'
- 'cmake/**'
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
build:
strategy:
matrix:
build_type:
- Debug
- Release
toolchain:
# - host-afl.toolchain.cmake
- hisiv510.toolchain.cmake
- himix200.toolchain.cmake
- mipsel-openwrt-linux-musl.toolchain.cmake
- mipsel-openwrt-linux.toolchain.cmake
runs-on: ubuntu-20.04
env:
build_command: |
cd ${{ github.workspace }}
pwd
ls -alh
# /bin/bash scripts/install-flatc.sh
cmake . -Bbuild \
-DCMAKE_TOOLCHAIN_FILE=toolchains/${{ matrix.toolchain }} \
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
-DCMAKE_INSTALL_PREFIX=./install \
-DCMAKE_VERBOSE_MAKEFILE=ON ${CUSTOM_CMAKE_ARGS}
cmake --build build --config ${{ matrix.build_type }} --target all -- -j `nproc`
cmake --build build --config ${{ matrix.build_type }} --target install
steps:
- uses: actions/checkout@v4
with:
submodules: true
fetch-depth: 1
ref: ${{ github.event.pull_request.head.sha }}
- name: build-host
if: matrix.toolchain == 'host.toolchain.cmake'
run: |
sudo apt-get update -y
sudo apt-get install -y libarchive-dev libssl-dev autoconf libtool pkg-config cmake make gcc g++
${{ env.build_command }}
- name: run_gtest
if: matrix.toolchain == 'host.toolchain.cmake'
run: |
cd ${{ github.workspace }}
cmake --build build --config ${{ matrix.build_type }} --target test
- name: build-host-afl
if: matrix.toolchain == 'host-afl.toolchain.cmake'
run: |
sudo apt-get update -y
sudo apt-get install -y libarchive-dev libssl-dev autoconf libtool pkg-config afl++ cmake make gcc g++
export AFL_LLVM_LAF_ALL=1
export CC=/usr/bin/afl-clang-fast
export CXX=/usr/bin/afl-clang-fast++
export CUSTOM_CMAKE_ARGS="-DULIB_BUILD_TESTS=ON"
${{ env.build_command }}
- name: build-in-container
uses: addnab/docker-run-action@v3
if: matrix.toolchain != 'host.toolchain.cmake' && matrix.toolchain != 'host-afl.toolchain.cmake'
with:
image: tqcq/ubuntu:hisi
options: --rm --volumes-from ${{ env.JOB_CONTAINER_NAME }}
run: |
cd ${{ github.workspace }}
sudo apt-get update
sudo apt-get install -y libarchive-dev libssl-dev autoconf libtool pkg-config cmake make gcc g++
${{ env.build_command }}