Fix Windows build error #8
Workflow file for this run
This file contains 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: CI | |
on: | |
push: | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- { target: x86_64-windows-gnu, ext: ".exe", cmake: "-DPacket_ROOT=/tmp/sdk" } | |
- { target: aarch64-linux-musl } | |
- { target: x86_64-linux-musl } | |
- { target: mipsel-linux-musl } | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Download NPCAP SDK | |
if: matrix.target == 'x86_64-windows-gnu' | |
run: | | |
wget https://npcap.com/dist/npcap-sdk-1.13.zip -O /tmp/sdk.zip | |
unzip /tmp/sdk.zip -d /tmp/sdk | |
mv /tmp/sdk/Lib /tmp/sdk/lib | |
- name: Build executable | |
run: | | |
sudo rm -rf /usr/lib/x86_64-linux-gnu/pkgconfig/openssl.pc | |
cmake -B build -DCMAKE_BUILD_TYPE=Release -DZIG_TARGET=${{ matrix.target }} -DUSE_SYSTEM_PCAP=OFF ${{ matrix.cmake }} | |
cmake --build build -t pppwn | |
tar -czvf pppwn.tar.gz build/pppwn${{ matrix.ext }} | |
- name: Upload result | |
uses: actions/upload-artifact@v4 | |
with: | |
name: ${{ matrix.target }} | |
path: pppwn.tar.gz |