From cfb24610e1b8fc51c29de36f335a4803c9931f7e Mon Sep 17 00:00:00 2001 From: xfangfang <2553041586@qq.com> Date: Wed, 15 May 2024 16:08:27 +0800 Subject: [PATCH] Support windows on arm (#25) --- .github/workflows/ci.yaml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 3bde0d4..4a373f7 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -34,6 +34,8 @@ jobs: cmake: "-DUSE_SYSTEM_PCAP=OFF -DPacket_ROOT=/tmp/sdk", ext: ".exe" } - { target: x86-windows-gnu, os: ubuntu-latest, strip: "llvm-strip", upx: "upx --lzma", cmake: "-DUSE_SYSTEM_PCAP=OFF -DPacket_ROOT=/tmp/sdk86", ext: ".exe" } + - { target: aarch64-windows-gnu, os: ubuntu-latest, strip: "llvm-strip", upx: "ls", + cmake: "-DUSE_SYSTEM_PCAP=OFF -DPacket_ROOT=/tmp/sdkarm", ext: ".exe" } - { target: x86_64-linux-musl, os: ubuntu-latest, strip: "llvm-strip", upx: "upx --lzma", cmake: "-DUSE_SYSTEM_PCAP=OFF" } - { target: aarch64-linux-musl, os: ubuntu-latest, strip: "llvm-strip", upx: "upx --lzma", @@ -58,16 +60,19 @@ jobs: run: sudo apt-get install llvm --no-install-recommends - name: Download NPCAP SDK - if: matrix.target == 'x86_64-windows-gnu' || matrix.target == 'x86-windows-gnu' + if: contains(matrix.target, 'windows') run: | wget https://npcap.com/dist/npcap-sdk-1.13.zip -O /tmp/sdk.zip unzip /tmp/sdk.zip -d /tmp/sdk mkdir -p /tmp/sdk/lib/x64 mkdir -p /tmp/sdk86/lib + mkdir -p /tmp/sdkarm/lib cp /tmp/sdk/Lib/x64/*lib /tmp/sdk/lib/x64 cp /tmp/sdk/Lib/x64/*lib /tmp/sdk/lib cp /tmp/sdk/Lib/*lib /tmp/sdk86/lib cp -r /tmp/sdk/Include /tmp/sdk86 + cp /tmp/sdk/Lib/ARM64/*lib /tmp/sdkarm/lib + cp -r /tmp/sdk/Include /tmp/sdkarm - name: Build executable run: |