feat:remove makefile; add msvc CI

This commit is contained in:
overwri 2024-02-08 05:58:47 +08:00
parent ff2dd888d8
commit 70c463ab7e
2 changed files with 21 additions and 25 deletions

View File

@ -5,7 +5,7 @@ on:
branches: [ main ]
jobs:
build_on_windows:
build_on_windows_msys2:
runs-on: windows-latest
steps:
@ -32,6 +32,26 @@ jobs:
with:
name: Windows amd64 Build
path: build/ncmdump.exe
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=Release -B build
- name: Build
run: cmake --build build -j 4
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: Windows amd64 Build
path: build/ncmdump.exe
build_on_linux:
runs-on: ubuntu-latest

View File

@ -1,24 +0,0 @@
default:
@echo "Please choose a platform: linux, macos-intel, macos-arm64, win32"
@echo "Or use 'make clean' to clean up the build files"
linux:
g++ main.cpp cJSON.cpp aes.cpp ncmcrypt.cpp -o ncmdump -ltag -std=c++17
strip ncmdump
macos-intel:
clang++ main.cpp cJSON.cpp aes.cpp ncmcrypt.cpp -o ncmdump -ltag -std=c++17
strip ncmdump
macos-arm64:export CPATH=/opt/homebrew/include
macos-arm64:export LIBRARY_PATH=/opt/homebrew/lib
macos-arm64:
clang++ main.cpp cJSON.cpp aes.cpp ncmcrypt.cpp -o ncmdump -ltag -std=c++17
strip ncmdump
win32:
g++ main.cpp cJSON.cpp aes.cpp ncmcrypt.cpp -o ncmdump -ltag -Ltaglib/lib -Itaglib/include -static -O -municode -std=c++17
strip ncmdump.exe
clean:
rm -f ncmdump ncmdump.exe