Skip to content

Commit

Permalink
Re-enable native builds
Browse files Browse the repository at this point in the history
  • Loading branch information
lihop committed Feb 13, 2024
1 parent 4b7408a commit f13ab4d
Showing 1 changed file with 26 additions and 22 deletions.
48 changes: 26 additions & 22 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,27 +67,36 @@ jobs:
addons/godot_xterm/native/bin/*.so
build_native:
if: false # Temporarily disabled.
name: "Build Native"
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
platform: [javascript, osx, windows]
platform: [web, macos, windows]
target: [release, debug]
bits: [64, 32]
arch: [x86_64, x86_32, wasm32, universal]
exclude:
- platform: web
arch: [x86_64, x86_32, universal]
- platform: macos
arch: [x86_64, x86_32, wasm32]
- platform: windows
arch: [wasm32, universal]
include:
- platform: javascript
- platform: web
os: ubuntu-22.04
- platform: osx
- platform: macos
os: macos-12
- platform: windows
os: windows-2022
exclude:
- platform: javascript
bits: 64 # Currently only wasm32 is supported.
- platform: osx
bits: 32 # Only 64-bit supported on macOS.
- arch: x86_64
bits: 64
- arch: x86_32
bits: 32
- arch: wasm32
bits: 32
- arch: universal
bits: 64
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -98,9 +107,9 @@ jobs:
with:
platform: ${{ matrix.platform }}
target: ${{ matrix.target }}
bits: ${{ matrix.bits }}
arch: ${{ matrix.arch }}
- name: Cache emscripten
if: ${{ matrix.platform == 'javascript' }}
if: ${{ matrix.platform == 'web' }}
uses: actions/cache@v3
env:
cache-name: cache-emscripten
Expand All @@ -109,14 +118,14 @@ jobs:
key: emsdk-cache-${{ matrix.target }}-${{ hashFiles('**/*.c*', '**/*.h*') }}
restore-keys: |
emsdk-cache-${{ matrix.target }}-
- name: Install javascript build dependencies
if: ${{ matrix.platform == 'javascript' }}
- name: Install web build dependencies
if: ${{ matrix.platform == 'web' }}
uses: mymindstorm/setup-emsdk@v11
with:
version: 3.1.14
actions-cache-folder: emsdk-cache-${{ matrix.target }}
- name: Install additional javascript build dependencies
if: ${{ matrix.platform == 'javascript' }}
- name: Install additional web build dependencies
if: ${{ matrix.platform == 'web' }}
run: sudo apt-get update && sudo apt-get install -y scons gcc-multilib g++-multilib
- name: Install additional macos build dependencies
if: ${{ matrix.os == 'macos-12' }}
Expand All @@ -129,11 +138,6 @@ jobs:
if: ${{ matrix.os == 'windows-2022' }}
with:
arch: win${{ matrix.bits }}
- name: Build godot-cpp bindings
if: steps.cache-submodules.outputs.cache-hit != 'true'
run: |
cd addons/godot_xterm/native/thirdparty/godot-cpp
scons platform=${{ matrix.platform }} target=${{ matrix.target }} bits=${{ matrix.bits }} generate_bindings=yes -j2
- name: Setup cmake
if: steps.cache-submodules.outputs.cache-hit != 'true'
uses: jwlawson/actions-setup-cmake@v2
Expand Down Expand Up @@ -169,7 +173,7 @@ jobs:
- name: Build libgodot-xterm
run: |
cd addons/godot_xterm/native
scons platform=${{ matrix.platform }} target=${{ matrix.target }} bits=${{ matrix.bits }} -j2
scons platform=${{ matrix.platform }} target=template_${{ matrix.target }} arch=${{ matrix.arch }} -j2
- name: Upload binaries
uses: actions/upload-artifact@v3
with:
Expand Down

0 comments on commit f13ab4d

Please sign in to comment.