2023-12-08 14:44:17 +00:00
|
|
|
name: Build GDExtension
|
|
|
|
on:
|
|
|
|
workflow_call:
|
|
|
|
push:
|
2023-08-05 22:42:21 +00:00
|
|
|
|
|
|
|
env:
|
|
|
|
LIBNAME: example
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
include:
|
2024-05-28 00:30:43 +00:00
|
|
|
# Debug templates
|
2023-12-08 14:44:17 +00:00
|
|
|
- platform: linux
|
|
|
|
float-precision: single
|
|
|
|
arch: x86_64
|
2024-05-28 00:30:43 +00:00
|
|
|
target-type: template_debug
|
2023-12-08 14:44:17 +00:00
|
|
|
os: ubuntu-20.04
|
2024-05-28 00:30:43 +00:00
|
|
|
|
2023-12-08 14:44:17 +00:00
|
|
|
- platform: windows
|
|
|
|
float-precision: single
|
|
|
|
arch: x86_32
|
2024-05-28 00:30:43 +00:00
|
|
|
target-type: template_debug
|
2023-08-05 22:42:21 +00:00
|
|
|
os: windows-latest
|
2024-05-28 00:30:43 +00:00
|
|
|
|
2023-12-08 14:44:17 +00:00
|
|
|
- platform: windows
|
|
|
|
float-precision: single
|
2023-08-05 22:42:21 +00:00
|
|
|
arch: x86_64
|
2024-05-28 00:30:43 +00:00
|
|
|
target-type: template_debug
|
2023-08-05 22:42:21 +00:00
|
|
|
os: windows-latest
|
2024-05-28 00:30:43 +00:00
|
|
|
|
2023-12-08 14:44:17 +00:00
|
|
|
- platform: macos
|
|
|
|
float-precision: single
|
|
|
|
arch: universal
|
2024-05-28 00:30:43 +00:00
|
|
|
target-type: template_debug
|
2023-12-08 14:44:17 +00:00
|
|
|
os: macos-latest
|
2024-05-28 00:30:43 +00:00
|
|
|
|
2023-12-08 14:44:17 +00:00
|
|
|
- platform: android
|
|
|
|
float-precision: single
|
|
|
|
arch: arm64
|
2024-05-28 00:30:43 +00:00
|
|
|
target-type: template_debug
|
2023-12-08 14:44:17 +00:00
|
|
|
os: ubuntu-20.04
|
2024-05-28 00:30:43 +00:00
|
|
|
|
2023-12-08 14:44:17 +00:00
|
|
|
- platform: android
|
|
|
|
float-precision: single
|
|
|
|
arch: arm32
|
2024-05-28 00:30:43 +00:00
|
|
|
target-type: template_debug
|
2023-12-08 14:44:17 +00:00
|
|
|
os: ubuntu-20.04
|
2024-05-28 00:30:43 +00:00
|
|
|
|
2023-12-08 14:44:17 +00:00
|
|
|
- platform: android
|
|
|
|
float-precision: single
|
2023-08-05 22:42:21 +00:00
|
|
|
arch: x86_64
|
2024-05-28 00:30:43 +00:00
|
|
|
target-type: template_debug
|
2023-12-08 14:44:17 +00:00
|
|
|
os: ubuntu-20.04
|
2024-05-28 00:30:43 +00:00
|
|
|
|
2023-12-08 14:44:17 +00:00
|
|
|
- platform: android
|
|
|
|
float-precision: single
|
|
|
|
arch: x86_32
|
2024-05-28 00:30:43 +00:00
|
|
|
target-type: template_debug
|
2023-12-08 14:44:17 +00:00
|
|
|
os: ubuntu-20.04
|
2024-05-28 00:30:43 +00:00
|
|
|
|
2023-12-08 14:44:17 +00:00
|
|
|
- platform: ios
|
|
|
|
float-precision: single
|
|
|
|
arch: arm64
|
2024-05-28 00:30:43 +00:00
|
|
|
target-type: template_debug
|
2023-08-05 22:42:21 +00:00
|
|
|
os: macos-latest
|
2024-05-28 00:30:43 +00:00
|
|
|
|
2023-12-08 14:44:17 +00:00
|
|
|
- platform: web
|
|
|
|
float-precision: single
|
|
|
|
arch: wasm32
|
2024-05-28 00:30:43 +00:00
|
|
|
target-type: template_debug
|
2023-12-08 14:44:17 +00:00
|
|
|
os: ubuntu-20.04
|
|
|
|
|
2024-05-28 00:30:43 +00:00
|
|
|
# Release templates
|
2023-12-08 14:44:17 +00:00
|
|
|
- platform: linux
|
2024-05-28 00:30:43 +00:00
|
|
|
float-precision: single
|
2023-12-08 14:44:17 +00:00
|
|
|
arch: x86_64
|
2024-05-28 00:30:43 +00:00
|
|
|
target-type: template_release
|
2023-12-08 14:44:17 +00:00
|
|
|
os: ubuntu-20.04
|
2024-05-28 00:30:43 +00:00
|
|
|
|
2024-05-30 22:33:14 +00:00
|
|
|
# - platform: windows
|
|
|
|
# float-precision: single
|
|
|
|
# arch: x86_32
|
|
|
|
# target-type: template_release
|
|
|
|
# os: windows-latest
|
|
|
|
|
|
|
|
# - platform: windows
|
|
|
|
# float-precision: single
|
|
|
|
# arch: x86_64
|
|
|
|
# target-type: template_release
|
|
|
|
# os: windows-latest
|
|
|
|
|
|
|
|
# - platform: macos
|
|
|
|
# float-precision: single
|
|
|
|
# arch: universal
|
|
|
|
# target-type: template_release
|
|
|
|
# os: macos-latest
|
|
|
|
|
|
|
|
# - platform: android
|
|
|
|
# float-precision: single
|
|
|
|
# arch: arm64
|
|
|
|
# target-type: template_release
|
|
|
|
# os: ubuntu-20.04
|
|
|
|
|
|
|
|
# - platform: android
|
|
|
|
# float-precision: single
|
|
|
|
# arch: arm32
|
|
|
|
# target-type: template_release
|
|
|
|
# os: ubuntu-20.04
|
|
|
|
|
|
|
|
# - platform: android
|
|
|
|
# float-precision: single
|
|
|
|
# arch: x86_64
|
|
|
|
# target-type: template_release
|
|
|
|
# os: ubuntu-20.04
|
|
|
|
|
|
|
|
# - platform: android
|
|
|
|
# float-precision: single
|
|
|
|
# arch: x86_32
|
|
|
|
# target-type: template_release
|
|
|
|
# os: ubuntu-20.04
|
|
|
|
|
|
|
|
# - platform: ios
|
|
|
|
# float-precision: single
|
|
|
|
# arch: arm64
|
|
|
|
# target-type: template_release
|
|
|
|
# os: macos-latest
|
|
|
|
|
|
|
|
# - platform: web
|
|
|
|
# float-precision: single
|
|
|
|
# arch: wasm32
|
|
|
|
# target-type: template_release
|
|
|
|
# os: ubuntu-20.04
|
|
|
|
|
2024-05-28 00:30:43 +00:00
|
|
|
# Double precision templates
|
2024-05-30 22:33:14 +00:00
|
|
|
# Double precision debug templates
|
|
|
|
- platform: linux
|
|
|
|
float-precision: double
|
|
|
|
arch: x86_64
|
|
|
|
target-type: template_debug
|
|
|
|
os: ubuntu-20.04
|
|
|
|
|
|
|
|
- platform: windows
|
|
|
|
float-precision: double
|
|
|
|
arch: x86_32
|
|
|
|
target-type: template_debug
|
|
|
|
os: windows-latest
|
|
|
|
|
|
|
|
- platform: windows
|
|
|
|
float-precision: double
|
|
|
|
arch: x86_64
|
|
|
|
target-type: template_debug
|
|
|
|
os: windows-latest
|
|
|
|
|
|
|
|
- platform: macos
|
|
|
|
float-precision: double
|
|
|
|
arch: universal
|
|
|
|
target-type: template_debug
|
|
|
|
os: macos-latest
|
|
|
|
|
|
|
|
- platform: android
|
|
|
|
float-precision: double
|
|
|
|
arch: arm64
|
|
|
|
target-type: template_debug
|
|
|
|
os: ubuntu-20.04
|
|
|
|
|
|
|
|
- platform: android
|
|
|
|
float-precision: double
|
|
|
|
arch: arm32
|
|
|
|
target-type: template_debug
|
|
|
|
os: ubuntu-20.04
|
|
|
|
|
|
|
|
- platform: android
|
|
|
|
float-precision: double
|
|
|
|
arch: x86_64
|
|
|
|
target-type: template_debug
|
|
|
|
os: ubuntu-20.04
|
|
|
|
|
|
|
|
- platform: android
|
|
|
|
float-precision: double
|
|
|
|
arch: x86_32
|
|
|
|
target-type: template_debug
|
|
|
|
os: ubuntu-20.04
|
|
|
|
|
|
|
|
- platform: ios
|
|
|
|
float-precision: double
|
|
|
|
arch: arm64
|
|
|
|
target-type: template_debug
|
|
|
|
os: macos-latest
|
|
|
|
|
|
|
|
- platform: web
|
|
|
|
float-precision: double
|
|
|
|
arch: wasm32
|
|
|
|
target-type: template_debug
|
|
|
|
os: ubuntu-20.04
|
|
|
|
|
|
|
|
# Double precision release templates
|
2024-05-28 00:30:43 +00:00
|
|
|
- platform: linux
|
2023-12-08 14:44:17 +00:00
|
|
|
float-precision: double
|
2023-08-05 22:42:21 +00:00
|
|
|
arch: x86_64
|
2024-05-28 00:30:43 +00:00
|
|
|
target-type: template_release
|
2023-12-08 14:44:17 +00:00
|
|
|
os: ubuntu-20.04
|
2024-05-30 22:33:14 +00:00
|
|
|
|
|
|
|
# - platform: windows
|
|
|
|
# float-precision: double
|
|
|
|
# arch: x86_32
|
|
|
|
# target-type: template_release
|
|
|
|
# os: windows-latest
|
|
|
|
|
|
|
|
# - platform: windows
|
|
|
|
# float-precision: double
|
|
|
|
# arch: x86_64
|
|
|
|
# target-type: template_release
|
|
|
|
# os: windows-latest
|
|
|
|
|
|
|
|
# - platform: macos
|
|
|
|
# float-precision: double
|
|
|
|
# arch: universal
|
|
|
|
# target-type: template_release
|
|
|
|
# os: macos-latest
|
|
|
|
|
|
|
|
# - platform: android
|
|
|
|
# float-precision: double
|
|
|
|
# arch: arm64
|
|
|
|
# target-type: template_release
|
|
|
|
# os: ubuntu-20.04
|
|
|
|
|
|
|
|
# - platform: android
|
|
|
|
# float-precision: double
|
|
|
|
# arch: arm32
|
|
|
|
# target-type: template_release
|
|
|
|
# os: ubuntu-20.04
|
|
|
|
|
|
|
|
# - platform: android
|
|
|
|
# float-precision: double
|
|
|
|
# arch: x86_64
|
|
|
|
# target-type: template_release
|
|
|
|
# os: ubuntu-20.04
|
|
|
|
|
|
|
|
# - platform: android
|
|
|
|
# float-precision: double
|
|
|
|
# arch: x86_32
|
|
|
|
# target-type: template_release
|
|
|
|
# os: ubuntu-20.04
|
|
|
|
|
|
|
|
# - platform: ios
|
|
|
|
# float-precision: double
|
|
|
|
# arch: arm64
|
|
|
|
# target-type: template_release
|
|
|
|
# os: macos-latest
|
|
|
|
|
|
|
|
# - platform: web
|
|
|
|
# float-precision: double
|
|
|
|
# arch: wasm32
|
|
|
|
# target-type: template_release
|
|
|
|
# os: ubuntu-20.04
|
2023-12-08 14:44:17 +00:00
|
|
|
runs-on: ${{ matrix.os }}
|
2023-08-05 22:42:21 +00:00
|
|
|
steps:
|
2023-12-08 14:44:17 +00:00
|
|
|
- name: Checkout
|
2024-05-28 00:30:43 +00:00
|
|
|
uses: actions/checkout@v4
|
2023-08-05 22:42:21 +00:00
|
|
|
with:
|
2023-12-08 14:44:17 +00:00
|
|
|
submodules: true
|
|
|
|
fetch-depth: 0
|
2024-05-28 00:30:43 +00:00
|
|
|
|
2023-12-08 14:44:17 +00:00
|
|
|
# Build
|
2024-05-28 00:30:43 +00:00
|
|
|
- name: 🔗 GDExtension Debug Build
|
2023-12-08 14:44:17 +00:00
|
|
|
uses: ./.github/actions/build
|
2023-08-05 22:42:21 +00:00
|
|
|
with:
|
2023-12-08 14:44:17 +00:00
|
|
|
platform: ${{ matrix.platform }}
|
|
|
|
arch: ${{ matrix.arch }}
|
|
|
|
float-precision: ${{ matrix.float-precision }}
|
2024-05-28 00:30:43 +00:00
|
|
|
build-target-type: ${{ matrix.target-type }}
|
|
|
|
|
2023-12-08 14:44:17 +00:00
|
|
|
# Sign
|
|
|
|
- name: Mac Sign
|
2024-04-06 14:21:54 +00:00
|
|
|
# Disable sign if secrets are not set
|
|
|
|
if: ${{ matrix.platform == 'macos' && env.APPLE_CERT_BASE64 }}
|
|
|
|
env:
|
|
|
|
APPLE_CERT_BASE64: ${{ secrets.APPLE_CERT_BASE64 }}
|
2023-12-08 14:44:17 +00:00
|
|
|
uses: ./.github/actions/sign
|
2023-10-05 11:44:43 +00:00
|
|
|
with:
|
2023-12-08 14:44:17 +00:00
|
|
|
FRAMEWORK_PATH: bin/macos/macos.framework
|
|
|
|
APPLE_CERT_BASE64: ${{ secrets.APPLE_CERT_BASE64 }}
|
|
|
|
APPLE_CERT_PASSWORD: ${{ secrets.APPLE_CERT_PASSWORD }}
|
|
|
|
APPLE_DEV_PASSWORD: ${{ secrets.APPLE_DEV_PASSWORD }}
|
|
|
|
APPLE_DEV_ID: ${{ secrets.APPLE_DEV_ID }}
|
|
|
|
APPLE_DEV_TEAM_ID: ${{ secrets.APPLE_DEV_TEAM_ID }}
|
|
|
|
APPLE_DEV_APP_ID: ${{ secrets.APPLE_DEV_APP_ID }}
|
2023-08-05 22:42:21 +00:00
|
|
|
|
2023-12-08 14:44:17 +00:00
|
|
|
- name: Windows - Delete compilation files
|
2023-08-05 22:42:21 +00:00
|
|
|
if: ${{ matrix.platform == 'windows' }}
|
2023-12-08 14:44:17 +00:00
|
|
|
shell: pwsh
|
2023-08-05 22:42:21 +00:00
|
|
|
run: |
|
|
|
|
Remove-Item bin/* -Include *.exp,*.lib,*.pdb -Force
|
2023-12-08 14:44:17 +00:00
|
|
|
- name: Upload Artifact
|
2024-05-28 00:30:43 +00:00
|
|
|
uses: actions/upload-artifact@v4
|
2023-08-05 22:42:21 +00:00
|
|
|
with:
|
2024-05-28 00:30:43 +00:00
|
|
|
name: godot-cpp-template-${{ matrix.platform }}-${{ matrix.arch }}-${{ matrix.float-precision }}-${{ matrix.target-type }}
|
2023-08-05 22:42:21 +00:00
|
|
|
path: |
|
2023-12-08 14:44:17 +00:00
|
|
|
${{ github.workspace }}/bin/**
|
2024-05-30 22:33:14 +00:00
|
|
|
|
|
|
|
# Merges all the build artifacts together into a single godot-cpp-template artifact.
|
|
|
|
# If you comment out this step, all the builds will be uploaded individually.
|
2024-05-28 00:30:43 +00:00
|
|
|
merge:
|
|
|
|
runs-on: ubuntu-20.04
|
|
|
|
needs: build
|
|
|
|
steps:
|
|
|
|
- name: Merge Artifacts
|
|
|
|
uses: actions/upload-artifact/merge@v4
|
|
|
|
with:
|
|
|
|
name: godot-cpp-template
|
|
|
|
pattern: godot-cpp-template-*
|
|
|
|
delete-merged: true
|