Update autobuild.yml

This commit is contained in:
wqj6 2025-01-05 06:40:03 +08:00 committed by GitHub
parent 3fe1518325
commit 613862e07c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -7,8 +7,8 @@ on:
branches: [ main ]
jobs:
build_on_windows_msys2:
runs-on: windows-latest
build_on_android_armv8a:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
@ -17,55 +17,27 @@ jobs:
submodules: recursive
- name: Install dependencies
uses: msys2/setup-msys2@v2
with:
msystem: UCRT64
update: true
install: git mingw-w64-ucrt-x86_64-toolchain
run: |
sudo apt-get update
sudo apt-get install -y cmake ninja-build axel unzip
- name: Configure build
run: cmake -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} -B ${{ env.BUILD_PATH }}
run: |
axel -n 4 https://googledownloads.cn/android/repository/android-ndk-r27c-linux.zip
unzip android-ndk-r27c-linux.zip
export ANDROID_NDK_ROOT=~/android-ndk-r27c
cmake -G Ninja -DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK_ROOT/build/cmake/android.toolchain.cmake -DANDROID_ABI=arm64-v8a -DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} -B ${{ env.BUILD_PATH }}
- name: Build
run: cmake --build ${{ env.BUILD_PATH }} -j 4
- name: Strip
run: strip ${{ env.BUILD_PATH }}/ncmdump.exe
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: windows_amd64_build_msys2_exe
path: ${{ env.BUILD_PATH }}/ncmdump.exe
name: android_armv8a_build
path: ${{ env.BUILD_PATH }}/lib/armeabi-v7a/libncmdump.so
build_on_windows_msvc:
runs-on: windows-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Configure build
run: cmake -DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} -B ${{ env.BUILD_PATH }}
- name: Build
run: cmake --build ${{ env.BUILD_PATH }} -j 4 --config ${{ env.BUILD_TYPE }}
- name: Upload artifact executable
uses: actions/upload-artifact@v4
with:
name: windows_amd64_build_msvc_exe
path: ${{ env.BUILD_PATH }}/${{ env.BUILD_TYPE }}/ncmdump.exe
- name: Upload artifact DLL
uses: actions/upload-artifact@v4
with:
name: windows_amd64_build_msvc_dll
path: ${{ env.BUILD_PATH }}/${{ env.BUILD_TYPE }}/libncmdump.dll
build_on_linux_amd64:
build_on_linux_arm64:
runs-on: ubuntu-latest
steps:
@ -88,55 +60,5 @@ jobs:
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: linux_build_amd64
name: linux_build_arm64
path: ${{ env.BUILD_PATH }}/ncmdump
build_on_macos_amd64:
runs-on: macos-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Install dependencies
run: |
brew install git cmake
- name: Configure build
run: cmake -DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} -B ${{ env.BUILD_PATH }} -DCMAKE_OSX_ARCHITECTURES=x86_64
- name: Build
run: cmake --build ${{ env.BUILD_PATH }} -j 4
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: macOS_build_amd64
path: ${{ env.BUILD_PATH }}/ncmdump
build_on_macos_arm64:
runs-on: macos-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Install dependencies
run: |
brew install git cmake
- name: Configure build
run: cmake -DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} -B ${{ env.BUILD_PATH }} -DCMAKE_OSX_ARCHITECTURES=arm64
- name: Build
run: cmake --build ${{ env.BUILD_PATH }} -j 4
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: macOS_build_arm64
path: ${{ env.BUILD_PATH }}/ncmdump