diff --git a/.github/workflows/coverity_native_build.yml b/.github/workflows/coverity_native_build.yml new file mode 100644 index 00000000..5f9a8823 --- /dev/null +++ b/.github/workflows/coverity_native_build.yml @@ -0,0 +1,30 @@ +name: Build Webcfg Component in Native Environment + +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] +jobs: + build: + name: Build + runs-on: [ ubuntu-latest ] + steps: + # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it + - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 + with: + fetch-depth: 0 + + # Install the dependent packages + - name: Install packages + run: | + sudo apt update + sudo apt-get -y install valgrind libcunit1 libcunit1-doc libcunit1-dev libmsgpack-dev gcovr libtool xsltproc docbook-xsl uuid-dev libcurl4-openssl-dev lcov libmsgpack* libcjson-dev build-essential + pip install codecov + + - name: native build + run: | + + # Build component + chmod +x build.sh + ./build.sh diff --git a/build.sh b/build.sh new file mode 100644 index 00000000..9379d625 --- /dev/null +++ b/build.sh @@ -0,0 +1,21 @@ +set -e +set -x +############################## +# Setup WorkSpace # +############################## +GITHUB_WORKSPACE="${PWD}" +ls -la ${GITHUB_WORKSPACE} +cd ${GITHUB_WORKSPACE} + +############################## +# Build WEBCFG # +############################## +echo "======================================================================================" +echo "buliding webcfg for coverity" + +cd ${GITHUB_WORKSPACE} +cmake -S "$GITHUB_WORKSPACE" -B build -DWEBCONFIG_BIN_SUPPORT:BOOL=true -DWAN_FAILOVER_SUPPORTED:BOOL=true + +cmake --build build --target install +echo "======================================================================================" +exit 0