centre the canvas inside the viewport when resizing the viewport #476
Workflow file for this run
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
name: CMake | |
on: [push, workflow_dispatch] | |
env: | |
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.) | |
BUILD_TYPE: Release | |
CMAKE_BUILD_PARALLEL_LEVEL: 3 | |
jobs: | |
macos-universal-build: | |
runs-on: macos-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
fetch-depth: 0 | |
- name: ccache | |
uses: hendrikmuhs/[email protected] | |
with: | |
key: macos | |
- name: Create Build Environment | |
run: cmake -E make_directory ${{github.workspace}}/build | |
- name: Configure CMake | |
working-directory: ${{github.workspace}}/build | |
run: cmake $GITHUB_WORKSPACE -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DBUILD_OFELIA=1 | |
- name: Check for Code-Signing secrets | |
id: secret-check | |
shell: bash | |
run: | | |
if [ "${{ secrets.APPLE_DEVELOPER_CERTIFICATE_P12_BASE64 }}" != '' ]; then | |
echo "available=true" >> $GITHUB_OUTPUT; | |
else | |
echo "available=false" >> $GITHUB_OUTPUT; | |
fi | |
- name: Import Code-Signing Certificates | |
uses: figleafteam/import-codesign-certs@v2 | |
if: ${{ steps.secret-check.outputs.available == 'true' }} | |
with: | |
p12-file-base64: ${{ secrets.APPLE_DEVELOPER_CERTIFICATE_P12_BASE64 }} | |
p12-password: ${{ secrets.APPLE_DEVELOPER_CERTIFICATE_PASSWORD }} | |
- name: Build | |
working-directory: ${{github.workspace}}/build | |
run: cmake --build . --config $BUILD_TYPE | |
- name: Creating Installer | |
working-directory: ${{github.workspace}} | |
env: | |
AC_USERNAME: ${{ secrets.AC_USERNAME }} | |
AC_PASSWORD: ${{ secrets.AC_PASSWORD }} | |
run: ./.github/scripts/package-macOS.sh | |
- name: Upload to server | |
env: | |
FTP_USERNAME: ${{ secrets.FTP_USERNAME }} | |
FTP_PASSWORD: ${{ secrets.FTP_PASSWORD }} | |
GIT_HASH: ${{ github.sha }} | |
run: ./.github/scripts/upload-ftp.sh plugdata-macOS-Universal.pkg | |
- name: Archive Artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: plugdata-macOS-Universal | |
path: plugdata-macOS-Universal.pkg | |
- name: Release Artifacts | |
uses: softprops/action-gh-release@v1 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
prerelease: true | |
draft: true | |
files: plugdata-macOS-Universal | |
windows-64-build: | |
runs-on: windows-2022 | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
fetch-depth: 0 | |
- name: Create Build Environment | |
run: cmake -E make_directory ${{github.workspace}}/build | |
- name: Configure CMake | |
shell: bash | |
working-directory: ${{github.workspace}}/build | |
run: cmake $GITHUB_WORKSPACE -G "Visual Studio 17 2022" -A x64 -DENABLE_TESTING=0 -DBUILD_OFELIA=1 | |
- name: Build | |
shell: bash | |
working-directory: ${{github.workspace}}/build | |
run: cmake --build . --config $BUILD_TYPE | |
- name: Creating Installer | |
working-directory: ${{github.workspace}} | |
shell: bash | |
run: | | |
./.github/scripts/package-Windows.sh "x64" | |
- name: Upload to server | |
shell: bash | |
env: | |
FTP_USERNAME: ${{ secrets.FTP_USERNAME }} | |
FTP_PASSWORD: ${{ secrets.FTP_PASSWORD }} | |
GIT_HASH: ${{ github.sha }} | |
run: ./.github/scripts/upload-ftp.sh plugdata-Win64.msi | |
- name: Archive Artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: plugdata-Win64 | |
path: plugdata-Win64.msi | |
- name: Release Artifacts | |
uses: softprops/action-gh-release@v1 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
prerelease: true | |
draft: true | |
files: plugdata-Win64 | |
windows-32-build: | |
runs-on: windows-2022 | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
fetch-depth: 0 | |
- name: Create Build Environment | |
run: cmake -E make_directory ${{github.workspace}}/build | |
- name: Configure CMake | |
shell: bash | |
working-directory: ${{github.workspace}}/build | |
run: cmake $GITHUB_WORKSPACE -G "Visual Studio 17 2022" -A Win32 -DENABLE_TESTING=0 -DBUILD_OFELIA=1 | |
- name: Build | |
shell: bash | |
working-directory: ${{github.workspace}}/build | |
run: cmake --build . --config $BUILD_TYPE | |
- name: Creating Installer | |
working-directory: ${{github.workspace}} | |
shell: bash | |
run: | | |
./.github/scripts/package-Windows.sh "x86" | |
- name: Upload to server | |
shell: bash | |
env: | |
FTP_USERNAME: ${{ secrets.FTP_USERNAME }} | |
FTP_PASSWORD: ${{ secrets.FTP_PASSWORD }} | |
GIT_HASH: ${{ github.sha }} | |
run: ./.github/scripts/upload-ftp.sh plugdata-Win32.msi | |
- name: Archive Artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: plugdata-Win32 | |
path: plugdata-Win32.msi | |
- name: Release Artifacts | |
uses: softprops/action-gh-release@v1 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
prerelease: true | |
draft: true | |
files: plugdata-Win32 | |
linux-build: | |
name: ${{ matrix.name }} | |
runs-on: ubuntu-latest | |
container: | |
image: ${{ matrix.os }} | |
options: --privileged | |
volumes: | |
- /sys/fs/cgroup:/sys/fs/cgroup | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- name: Ubuntu-22.04-x64 | |
os: ubuntu:22.04 | |
pacman: apt | |
- name: Ubuntu-20.04-x64 | |
os: ubuntu:20.04 | |
pacman: apt | |
- name: Debian-x64 | |
os: debian | |
pacman: apt | |
- name: Fedora-37-x64 | |
os: fedora:37 | |
pacman: dnf | |
- name: Fedora-38-x64 | |
os: fedora:38 | |
pacman: dnf | |
#- name: OpenSUSE-Leap-x64 | |
# os: opensuse/leap:15.5 | |
# pacman: zypper | |
- name: Arch-x64 | |
os: archlinux | |
pacman: pacman | |
steps: | |
- name: Install Dependencies (dnf) | |
if: ${{ matrix.pacman == 'dnf' }} | |
run: dnf install -y git cmake alsa-lib-devel libXinerama-devel freetype-devel curl libcurl-devel wget bzip2 gcc-c++ libXcomposite-devel freeglut-devel libXrandr-devel libXcursor-devel xz ccache python python3-pip | |
- name: Install Dependencies (apt) | |
if: ${{ matrix.pacman == 'apt' }} | |
run: apt update && DEBIAN_FRONTEND=noninteractive TZ="Europe/Amsterdam" apt install -y cmake git wget bzip2 build-essential libasound2-dev libjack-jackd2-dev curl libcurl4-openssl-dev libfreetype6-dev libx11-dev libxcomposite-dev libxcursor-dev libxcursor-dev libxext-dev libxrandr-dev libxinerama-dev ccache python3 python3-pip | |
- name: Install Dependencies (zypper) | |
if: ${{ matrix.pacman == 'zypper' }} | |
run: zypper refresh && zypper install -y git rsync wget bzip2 xz tar gzip cmake alsa-lib-devel libXinerama-devel freetype-devel libcurl-devel libXcomposite-devel freeglut-devel libXrandr-devel libXcursor-devel freetype2-devel gcc gcc-c++ curl ccache python python3-pip | |
- name: Install Dependencies (pacman) | |
if: ${{ matrix.pacman == 'pacman' }} | |
run: pacman -Sy && pacman -S --noconfirm cmake wget bzip2 git alsa-lib freetype2 libx11 libxcursor libxext libxinerama libxrandr libxrender webkit2gtk cmake make gcc pkgconf python python-pip curl ccache && pacman --noconfirm -Syu | |
- uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
fetch-depth: 0 | |
- name: Update cmake | |
working-directory: ${{github.workspace}} | |
run: ./.github/scripts/install-cmake.sh | |
- name: ccache | |
uses: hendrikmuhs/[email protected] | |
with: | |
key: ${{ matrix.name }} | |
- name: Configure | |
working-directory: ${{github.workspace}} | |
run: mkdir build && cd build && CXX=g++ cmake -DCMAKE_C_COMPILER_LAUNCHER=ccache -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DENABLE_TESTING=0 -DBUILD_OFELIA=1 .. -G "Unix Makefiles" | |
- name: Build | |
working-directory: ${{github.workspace}}/build | |
run: cmake --build . --config $BUILD_TYPE | |
- name: Prepare Artefacts | |
working-directory: ${{github.workspace}} | |
run: ./.github/scripts/package-Linux.sh ${{ matrix.name }} | |
- name: Upload to server | |
env: | |
FTP_USERNAME: ${{ secrets.FTP_USERNAME }} | |
FTP_PASSWORD: ${{ secrets.FTP_PASSWORD }} | |
GIT_HASH: ${{ github.sha }} | |
run: ./.github/scripts/upload-ftp.sh plugdata-${{ matrix.name }}.tar.gz | |
- name: Archive Artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: plugdata-${{ matrix.name }} | |
path: plugdata-${{ matrix.name }}.tar.gz | |
- name: Release Artifacts | |
uses: softprops/action-gh-release@v1 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
prerelease: true | |
draft: true | |
files: plugdata-${{ matrix.name }} |