forked from FosterFramework/Foster
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
3 changed files
with
55 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,16 +17,31 @@ jobs: | |
strategy: | ||
matrix: | ||
include: | ||
- os: windows-latest | ||
arch: x64 | ||
lib: x64/FosterPlatform.dll | ||
- os: macos-latest | ||
arch: x64-arm64 | ||
lib: osx/libFosterPlatform.dylib | ||
- os: ubuntu-latest | ||
arch: x64 | ||
lib: lib64/libFosterPlatform.so | ||
- os: ubuntu-latest | ||
arch: arm64 | ||
lib: libarm64/libFosterPlatform.so | ||
runs-on: ${{matrix.os}} | ||
steps: | ||
- name: Checkout | ||
uses: actions/[email protected] | ||
- name: Get CMake | ||
uses: lukka/[email protected] | ||
- name: Setup Linux dependencies | ||
if: runner.os == 'Linux' | ||
if: ${{ runner.os == 'Linux' && matrix.arch != 'arm64' }} | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install libsdl2-dev | ||
- name: Setup Linux dependencies (arm64) | ||
if: ${{ runner.os == 'Linux' && matrix.arch == 'arm64' }} | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y gcc-aarch64-linux-gnu g++-aarch64-linux-gnu binutils-aarch64-linux-gnu | ||
|
@@ -37,13 +52,21 @@ jobs: | |
sudo apt-get update | ||
sudo apt-get install libsdl2-dev:arm64 | ||
- name: CMake Configure | ||
run: CC=aarch64-linux-gnu-gcc CXX=aarch64-linux-gnu-g++ cmake -B build -S Platform | ||
if: ${{ matrix.arch != 'arm64' }} | ||
run: cmake -B build -S Platform | ||
- name: CMake Configure (arm64) | ||
if: ${{ runner.os == 'Linux' && matrix.arch == 'arm64' }} | ||
run: cmake -B build -S Platform -DCMAKE_C_COMPILER=aarch64-linux-gnu-gcc -DCMAKE_CXX_COMPILER=aarch64-linux-gnu-g++ -DCMAKE_SYSTEM_PROCESSOR=aarch64 | ||
- name: CMake Build | ||
run: CC=aarch64-linux-gnu-gcc CXX=aarch64-linux-gnu-g++ cmake --build build --config Release | ||
if: ${{ matrix.arch != 'arm64' }} | ||
run: cmake --build build --config Release | ||
- name: CMake Build | ||
if: ${{ runner.os == 'Linux' && matrix.arch == 'arm64' }} | ||
run: cmake --build build --config Release -DCMAKE_C_COMPILER=aarch64-linux-gnu-gcc -DCMAKE_CXX_COMPILER=aarch64-linux-gnu-g++ -DCMAKE_SYSTEM_PROCESSOR=aarch64 | ||
- name: Publish Artifact | ||
uses: actions/[email protected] | ||
with: | ||
name: ${{matrix.os}}-build | ||
name: ${{matrix.os}}-${{matrix.arch}}-build | ||
path: Platform/libs/${{matrix.lib}} | ||
UpdateLibs: | ||
if: github.ref == 'refs/heads/main' | ||
|
@@ -52,11 +75,26 @@ jobs: | |
steps: | ||
- name: Checkout | ||
uses: actions/[email protected] | ||
- name: Download windows lib | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: windows-latest-x64-build | ||
path: Platform/libs/x64 | ||
- name: Download macos lib | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: macos-latest-x64-arm64-build | ||
path: Platform/libs/osx | ||
- name: Download ubuntu lib | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: ubuntu-latest-build | ||
name: ubuntu-latest-x64-build | ||
path: Platform/libs/lib64 | ||
- name: Download ubuntu lib (arm64) | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: ubuntu-latest-arm64-build | ||
path: Platform/libs/libarm64 | ||
- name: Display structure of libs | ||
run: ls -R | ||
working-directory: Platform/libs | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters