diff --git a/.gitea/workflows/Build Debug Library.yml b/.gitea/workflows/Build Debug Library.yml new file mode 100644 index 0000000..e700904 --- /dev/null +++ b/.gitea/workflows/Build Debug Library.yml @@ -0,0 +1,93 @@ +name: Build and Bundle + +on: + push: + workflow_dispatch: + +jobs: + macos: + name: macOS + runs-on: macos-26 + defaults: + run: + working-directory: ./Swift + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Build + run: | + swift build -Xswiftc -no-verify-emitted-module-interface + BIN_PATH=$(swift build --show-bin-path) + mkdir -p artifacts + cp "$BIN_PATH/libLogic.dylib" "${{github.workspace}}/artifacts/" + cp "$BIN_PATH/libSwiftGodot.dylib" "${{github.workspace}}/artifacts/" + + - name: Upload Artifact + uses: actions/upload-artifact@v4 + with: + name: Logic-macOS + path: "${{github.workspace}}/artifacts/*" + + windows: + name: Windows + runs-on: windows-11 + defaults: + run: + working-directory: ./Swift + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Build + run: | + swift build -Xswiftc -no-verify-emitted-module-interface + $binPath = swift build --show-bin-path + New-Item -ItemType Directory -Path "${{github.workspace}}/artifacts" -Force + Copy-Item -Path "$binPath/Logic.dll" -Destination "${{github.workspace}}/artifacts/" + + - name: Bundle DLLs + uses: https://git.omgitsalexl.me/omgitsalexl/windows-collect-dependencies@v1.0.3 + with: + executable: "${{github.workspace}}/artifacts/Logic.dll" + output: "${{github.workspace}}/artifacts/" + + - name: Upload Artifact + uses: actions/upload-artifact@v4 + with: + name: Logic-windows + path: "${{github.workspace}}/artifacts/*" + + ubuntu: + name: Ubuntu + runs-on: ubuntu-24.04 + defaults: + run: + working-directory: ./Swift + container: + image: git.omgitsalexl.me/omgitsalexl/ci-swift:6.3.3 + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Build + run: | + swift build -Xswiftc -no-verify-emitted-module-interface + BIN_PATH=$(swift build --show-bin-path) + mkdir -p artifacts + cp "$BIN_PATH/libLogic.so" "${{github.workspace}}/artifacts/" + + - name: Bundle Shared Libraries + uses: https://git.omgitsalexl.me/omgitsalexl/linux-collect-dependencies@v1.0.1 + with: + executable: "${{github.workspace}}/artifacts/libLogic.so" + output: "${{github.workspace}}/artifacts/" + + - name: Upload Artifact + uses: actions/upload-artifact@v4 + with: + name: Logic-ubuntu + path: "${{github.workspace}}/artifacts/*" diff --git a/.gitea/workflows/Build Library.yml b/.gitea/workflows/Build Release Library.yml similarity index 90% rename from .gitea/workflows/Build Library.yml rename to .gitea/workflows/Build Release Library.yml index 9519ae6..5f4a17c 100644 --- a/.gitea/workflows/Build Library.yml +++ b/.gitea/workflows/Build Release Library.yml @@ -1,7 +1,6 @@ name: Build and Bundle on: - push: workflow_dispatch: jobs: @@ -21,14 +20,14 @@ jobs: swift build -c release -Xswiftc -no-verify-emitted-module-interface BIN_PATH=$(swift build -c release --show-bin-path) mkdir -p artifacts - cp "$BIN_PATH/libLogic.dylib" artifacts/ - cp "$BIN_PATH/libSwiftGodot.dylib" artifacts/ + cp "$BIN_PATH/libLogic.dylib" "${{github.workspace}}/artifacts/" + cp "$BIN_PATH/libSwiftGodot.dylib" "${{github.workspace}}/artifacts/" - name: Upload Artifact uses: actions/upload-artifact@v4 with: name: Logic-macOS - path: artifacts/* + path: "${{github.workspace}}/artifacts/*" windows: name: Windows @@ -90,4 +89,4 @@ jobs: uses: actions/upload-artifact@v4 with: name: Logic-ubuntu - path: "${{github.workspace}}/artifacts/* + path: "${{github.workspace}}/artifacts/*"