-
-
Notifications
You must be signed in to change notification settings - Fork 544
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
注意: musl构建版本不支持全球化
- Loading branch information
Showing
2 changed files
with
49 additions
and
12 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -71,43 +71,80 @@ jobs: | |
name: N_m3u8DL-RE_Beta_win-arm64 | ||
path: artifact-arm64\N_m3u8DL-RE.exe | ||
|
||
build-linux-x64: | ||
build-linux-x64-arm64: | ||
runs-on: ubuntu-latest | ||
container: ubuntu:18.04 | ||
|
||
steps: | ||
- run: apt-get update | ||
- run: apt-get install -y curl wget | ||
# https://learn.microsoft.com/zh-cn/dotnet/core/deploying/native-aot/cross-compile | ||
- run: | | ||
sudo dpkg --add-architecture arm64 | ||
sudo bash -c 'cat > /etc/apt/sources.list.d/arm64.list <<EOF | ||
deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports/ jammy main restricted | ||
deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports/ jammy-updates main restricted | ||
deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports/ jammy-backports main restricted universe multiverse | ||
EOF' | ||
sudo sed -i -e 's/deb http/deb [arch=amd64] http/g' /etc/apt/sources.list | ||
sudo sed -i -e 's/deb mirror/deb [arch=amd64] mirror/g' /etc/apt/sources.list | ||
sudo apt-get update | ||
sudo apt-get install -y curl wget libicu-dev libcurl4-openssl-dev zlib1g-dev libkrb5-dev clang llvm binutils-aarch64-linux-gnu gcc-aarch64-linux-gnu zlib1g-dev:arm64 | ||
- uses: actions/checkout@v1 | ||
- name: Set up dotnet | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
dotnet-version: ${{ env.DOTNET_SDK_VERSION }} | ||
- run: apt-get install -y libicu-dev libcurl4-openssl-dev zlib1g-dev libkrb5-dev | ||
|
||
- run: dotnet publish src/N_m3u8DL-RE -r linux-x64 -c Release -o artifact | ||
- run: dotnet publish src/N_m3u8DL-RE -r linux-arm64 -c Release -o artifact-arm64 | ||
|
||
- name: Upload Artifact[linux-x64] | ||
uses: actions/[email protected] | ||
with: | ||
name: N_m3u8DL-RE_Beta_linux-x64 | ||
path: artifact/N_m3u8DL-RE | ||
|
||
build-linux-arm64: | ||
- name: Upload Artifact[linux-arm64] | ||
uses: actions/[email protected] | ||
with: | ||
name: N_m3u8DL-RE_Beta_linux-arm64 | ||
path: artifact-arm64/N_m3u8DL-RE | ||
|
||
build-linux-musl-x64: | ||
runs-on: ubuntu-latest | ||
container: mcr.microsoft.com/dotnet/sdk:9.0-alpine-amd64 | ||
|
||
steps: | ||
- uses: actions/checkout@v1 | ||
|
||
- run: apk add clang build-base zlib-dev | ||
- run: dotnet publish src/N_m3u8DL-RE -r linux-musl-x64 -c Release -o artifact -p:InvariantGlobalization=true | ||
|
||
- name: Upload Artifact[linux-musl-x64] | ||
uses: actions/[email protected] | ||
with: | ||
name: N_m3u8DL-RE_Beta_linux-musl-x64 | ||
path: artifact/N_m3u8DL-RE | ||
|
||
build-linux-musl-arm64: | ||
runs-on: ubuntu-latest | ||
container: mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-18.04-cross-arm64-20220312201346-b2c2436 | ||
container: mcr.microsoft.com/dotnet-buildtools/prereqs:ubuntu-22.04-cross-arm64-alpine | ||
|
||
steps: | ||
- uses: actions/checkout@v1 | ||
|
||
- name: Set up dotnet | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
dotnet-version: ${{ env.DOTNET_SDK_VERSION }} | ||
- run: dotnet publish src/N_m3u8DL-RE -r linux-arm64 -c Release -p:StripSymbols=true -p:CppCompilerAndLinker=clang-9 -p:SysRoot=/crossrootfs/arm64 -o artifact | ||
|
||
- name: Upload Artifact[linux-arm64] | ||
- run: apt-get update | ||
- run: apt-get install -y build-essential clang binutils-aarch64-linux-gnu | ||
- run: dotnet publish src/N_m3u8DL-RE -r linux-musl-arm64 -c Release -o artifact -p:CppCompilerAndLinker=clang -p:SysRoot=/crossrootfs/arm64 -p:InvariantGlobalization=true | ||
|
||
- name: Upload Artifact[linux-musl-arm64] | ||
uses: actions/[email protected] | ||
with: | ||
name: N_m3u8DL-RE_Beta_linux-arm64 | ||
name: N_m3u8DL-RE_Beta_linux-musl-arm64 | ||
path: artifact/N_m3u8DL-RE | ||
|
||
build-mac-x64-arm64: | ||
|
@@ -137,7 +174,7 @@ jobs: | |
create_draft_release: | ||
name: Create Github draft release | ||
if: ${{ github.event.inputs.doRelease == 'true' }} | ||
needs: [build-win-nt6_0-x86,build-win-x64-arm64,build-linux-x64,build-linux-arm64,build-mac-x64-arm64] | ||
needs: [build-win-nt6_0-x86,build-win-x64-arm64,build-linux-x64-arm64,build-linux-musl-x64,build-linux-musl-arm64,build-mac-x64-arm64] | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Audit gh version | ||
|
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