Final adjustments

This commit is contained in:
The Artifex (4r7if3x) 2023-06-07 14:19:51 +02:00
parent 61b93bb27f
commit ca11098c9b
No known key found for this signature in database
GPG key ID: F23C261322667A12

View file

@ -14,30 +14,30 @@ jobs:
fail-fast: true
matrix:
include:
- os: ubuntu
arch: amd64
target: x86_64-unknown-linux-gnu
- os: ubuntu
arch: i386
target: i686-unknown-linux-gnu
- os: ubuntu
arch: arm64
target: aarch64-unknown-linux-gnu
- os: ubuntu
arch: armhf
target: armv7-unknown-linux-gnueabihf
- os: ubuntu
arch: amd64
target: x86_64-unknown-linux-gnu
- os: ubuntu
arch: arm64
target: aarch64-unknown-linux-gnu
- os: macos
arch: amd64
target: x86_64-apple-darwin
- os: macos
arch: arm64
target: aarch64-apple-darwin
- os: windows
arch: amd64
target: x86_64-pc-windows-msvc
- os: windows
arch: i386
target: i686-pc-windows-msvc
- os: windows
arch: amd64
target: x86_64-pc-windows-msvc
steps:
- name: Checkout repository
@ -57,7 +57,6 @@ jobs:
{
"i386" { "Lib" }
"amd64" { "Lib\x64" }
"arm64" { "Lib\ARM64" }
default { throw "$ARCH is not supported!" }
}
Add-Content -Path "$env:GITHUB_ENV" -Value "LIB=$env:TEMP\npcap-sdk\$LibPath"
@ -85,8 +84,8 @@ jobs:
if: ${{ matrix.os == 'windows' }}
run: |
rustup target add `
x86_64-pc-windows-msvc `
i686-pc-windows-msvc
i686-pc-windows-msvc `
x86_64-pc-windows-msvc
- name: Install Cross
if: ${{ matrix.os == 'ubuntu' }}
@ -143,10 +142,10 @@ jobs:
shell: bash
run: |
targets=(
x86_64-unknown-linux-gnu
i686-unknown-linux-gnu
aarch64-unknown-linux-gnu
armv7-unknown-linux-gnueabihf
x86_64-unknown-linux-gnu
aarch64-unknown-linux-gnu
)
mkdir artifacts
for target in "${targets[@]}"; do
@ -196,7 +195,7 @@ jobs:
)
mkdir artifacts
for target in "${targets[@]}"; do
patchelf --replace-needed libpcap.so.0.8 libpcap.so target/${target}/release/sniffnet
patchelf --replace-needed libpcap.so.0.8 libpcap.so.1 target/${target}/release/sniffnet
cargo generate-rpm --target $target
mv target/${target}/generate-rpm/*.rpm artifacts/
done
@ -306,8 +305,8 @@ jobs:
shell: powershell
run: |
$targets=@(
"x86_64-pc-windows-msvc",
"i686-pc-windows-msvc"
"i686-pc-windows-msvc",
"x86_64-pc-windows-msvc"
)
New-Item -ItemType Directory -Path artifacts
foreach ($target in $targets)