Merge pull request #141 from billphipps/fix_wextra #49
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build and Test Client-Only | |
| on: | |
| push: | |
| branches: [ 'master', 'main', 'release/**' ] | |
| pull_request: | |
| branches: [ '*' ] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| # List host CPU info | |
| - name: Host CPU info | |
| run: cat /proc/cpuinfo | |
| # List compiler version | |
| - name: List compiler version | |
| run: gcc --version | |
| # pull and build wolfssl | |
| - name: Checkout wolfssl | |
| uses: actions/checkout@v4 | |
| with: | |
| repository: wolfssl/wolfssl | |
| path: wolfssl | |
| # Build example server | |
| - name: Build POSIX TCP server | |
| run: | | |
| cd examples/posix/tcp/wh_server_tcp | |
| make -j SHE=1 WOLFSSL_DIR=../../../../wolfssl | |
| # Start the server in the background | |
| - name: Run POSIX TCP server | |
| run: | | |
| cd examples/posix/tcp/wh_server_tcp | |
| ./Build/wh_server_tcp.elf & | |
| TCP_SERVER_PID=$! | |
| echo "TCP_SERVER_PID=$TCP_SERVER_PID" >> $GITHUB_ENV | |
| # Build and test client-only build with everything enabled and ASAN | |
| - name: Build client-only unit tests with ASAN | |
| run: | | |
| cd test | |
| make clean | |
| make -j CLIENT_ONLY_TCP=1 SHE=1 ASAN=1 WOLFSSL_DIR=../wolfssl run | |
| # Optional: Kill the server process if it doesn't exit on its own | |
| - name: Cleanup POSIX TCP server | |
| if: always() | |
| run: kill $TCP_SERVER_PID || true | |