CI: Store artifacts durring build

Add new option -A is added to tools/testbuild.sh that will take the
created build executable and store it in a folder for the config
that generated it under $ARTIFACTDIR which can be set via an
environment variable or defaulted to $(TOPDIR)/buildartifacts

This is also helpful for local testing because you can now run
tools/testbuild.sh -A sim.dat and have all of the simulation
targets generated without having to rebuild along the way.

In the GitHub Actions workflow the artifacs are uploaded
two two bundles one for macOS and one for Linux

Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
This commit is contained in:
Brennan Ashton
2020-10-25 21:18:43 -07:00
committed by Xiang Xiao
parent d0bde1114d
commit 162da1169e
6 changed files with 39 additions and 4 deletions
+12 -2
View File
@@ -161,8 +161,13 @@ jobs:
export CCACHE_DIR=`pwd`/ccache
mkdir $CCACHE_DIR
cd sources/testing
./cibuild.sh -c testlist/${{matrix.boards}}.dat
export ARTIFACTDIR=`pwd`/../../buildartifacts
./cibuild.sh -A -c testlist/${{matrix.boards}}.dat
ccache -s
- uses: actions/upload-artifact@v2
with:
name: linux-builds
path: buildartifacts/
macOS:
runs-on: macos-10.15
@@ -195,5 +200,10 @@ jobs:
export CCACHE_DIR=`pwd`/ccache
mkdir $CCACHE_DIR
cd sources/testing
./cibuild.sh -i -c testlist/${{matrix.boards}}.dat
export ARTIFACTDIR=`pwd`/../../buildartifacts
./cibuild.sh -i -A -c testlist/${{matrix.boards}}.dat
ccache -s
- uses: actions/upload-artifact@v2
with:
name: macos-builds
path: buildartifacts/