Merge pull request #444 from antmicro/plugin-split-gh-actions
Split Github Actions to be per plugin
diff --git a/.github/workflows/build-and-test.sh b/.github/workflows/build-and-test.sh
index 7d0401e..69fd8a7 100755
--- a/.github/workflows/build-and-test.sh
+++ b/.github/workflows/build-and-test.sh
@@ -19,12 +19,22 @@
source .github/workflows/common.sh
+if [ -z "${PLUGIN_NAME}" ]; then
+ echo "Missing \${PLUGIN_NAME} env value"
+ exit 1
+fi
+
##########################################################################
start_section Building
+if [ "$PLUGIN_NAME" == "xdc" ] || [ "$PLUGIN_NAME" == "sdc" ]; then
+ make design_introspection.so -j`nproc`
+ make install_design_introspection -j`nproc`
+fi
+
export CXXFLAGS=-Werror
-make UHDM_INSTALL_DIR=`pwd`/env/conda/envs/yosys-plugins/ plugins -j`nproc`
+make UHDM_INSTALL_DIR=`pwd`/env/conda/envs/yosys-plugins/ ${PLUGIN_NAME}.so -j`nproc`
unset CXXFLAGS
end_section
@@ -32,19 +42,19 @@
##########################################################################
start_section Installing
-make install -j`nproc`
+make install_${PLUGIN_NAME} -j`nproc`
end_section
##########################################################################
start_section Testing
-make test -j`nproc`
+make test_${PLUGIN_NAME} -j`nproc`
end_section
##########################################################################
start_section Cleanup
-make plugins_clean -j`nproc`
+make clean_${PLUGIN_NAME} -j`nproc`
end_section
##########################################################################
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 4ab1814..1ab44d1 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -23,6 +23,22 @@
Run-tests:
runs-on: ubuntu-20.04
+ strategy:
+ fail-fast: false
+ matrix:
+ plugin:
+ - fasm
+ - xdc
+ - params
+ - sdc
+ - ql-iob
+ - design_introspection
+ - integrateinv
+ - ql-qlf
+ - systemverilog
+ - uhdm
+ - dsp-ff
+
steps:
- uses: actions/checkout@v2
@@ -61,3 +77,4 @@
source .github/workflows/build-and-test.sh
env:
OS: ${{ runner.os }}
+ PLUGIN_NAME: ${{ matrix.plugin }}