This repository has been archived by the owner on May 9, 2024. It is now read-only.
Bump version, signature #43
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: Release Vector Audio | |
on: | |
push: | |
tags: | |
- v* | |
concurrency: | |
group: ${{ github.ref }} | |
cancel-in-progress: true | |
env: | |
BUILD_TYPE: Release | |
VECTOR_SECRET: Dev | |
jobs: | |
build-linux: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
submodules: recursive | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.10" | |
- name: Set env | |
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV | |
- name: Install SFML dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get install libx11-dev libxrandr-dev libxi-dev libudev-dev libgl1-mesa-dev libxcursor-dev freeglut3-dev pkg-config desktop-file-utils | |
sudo add-apt-repository universe | |
sudo apt-get update | |
sudo apt install libfuse2 | |
- name: Configure cmake | |
run: | | |
cmake -S . -B build/ -DVCPKG_BUILD_TYPE=release -DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} -DVECTOR_SECRET=${{ env.VECTOR_SECRET }} | |
- name: Build cmake | |
run: | | |
cmake --build build/ --config Release | |
- name: Bundle Linux | |
run: | | |
./bundle_linux.sh libafv_native.so | |
- name: Rename installer | |
run: | | |
mv VectorAudio-x86_64.AppImage VectorAudio-${{ github.ref_name }}-x86_64.AppImage | |
mv VectorAudio-x86_64.AppImage.zsync VectorAudio-${{ github.ref_name }}-x86_64.AppImage.zsync | |
- name: Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
files: | | |
VectorAudio-${{ github.ref_name }}-x86_64.AppImage | |
VectorAudio-${{ github.ref_name }}-x86_64.AppImage.zsync | |
build-windows: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
submodules: recursive | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.10" | |
- name: Configure cmake | |
run: | | |
cmake -S . -B build/ -DVCPKG_BUILD_TYPE=release -DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} -DVECTOR_SECRET=${{ env.VECTOR_SECRET }} | |
- name: Build cmake | |
run: | | |
cmake --build build/ --config Release | |
- name: Prepare windows installer | |
run: | | |
python collect_licenses.py | |
mkdir installer | |
cp resources/*.wav installer/ | |
cp resources/favicon.ico installer/ | |
cp resources/icon_win.png installer/ | |
cp resources/*.ttf installer/ | |
cp resources/airports.json installer/ | |
cp resources/LICENSE.txt installer/ | |
cp build/Release/vector_audio.exe installer/ | |
cp build/Release/*.dll installer/ | |
cp lib/windows/*.dll installer/ | |
cp bundle_windows.nsi installer/install.nsi | |
- name: Create installer | |
run: | | |
cd installer/ | |
makensis install.nsi | |
- name: Rename installer | |
run: | | |
mv installer/VectorAudio-installer.exe VectorAudio-${{ github.ref_name }}-Installer.exe | |
- name: Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
files: VectorAudio-${{ github.ref_name }}-Installer.exe | |
build-osx: | |
runs-on: macos-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
submodules: recursive | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.10" | |
- name: Install native dependencies | |
run: | | |
brew install pkg-config | |
- name: Set env | |
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV | |
- name: Create universal build folder | |
run: | | |
mkdir build/ | |
mkdir -p build/extern/afv-native/ | |
- name: Configure cmake (intel) | |
run: | | |
cmake -S . -B build_intel/ -DVCPKG_BUILD_TYPE=release -DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} -DCMAKE_OSX_ARCHITECTURES=x86_64 -DVCPKG_TARGET_TRIPLET=x64-osx -DVECTOR_SECRET=${{ env.VECTOR_SECRET }} | |
- name: Build cmake (intel) | |
run: | | |
cmake --build build_intel/ --config Release | |
- name: Cleanup intel build | |
run: | | |
cp build_intel/extern/afv-native/libafv_native.dylib build/libafv_native.dylib.intel | |
cp build_intel/vector_audio.app/Contents/MacOS/vector_audio build/vector_audio.intel | |
rm -rf build_intel/ | |
- name: Configure cmake (arm64) | |
run: | | |
cmake -S . -B build_arm64/ -DVCPKG_BUILD_TYPE=release -DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} -DCMAKE_OSX_ARCHITECTURES=arm64 -DVCPKG_TARGET_TRIPLET=arm64-osx -DVECTOR_SECRET=${{ env.VECTOR_SECRET }} | |
- name: Build cmake (arm64) | |
run: | | |
cmake --build build_arm64/ --config Release | |
- name: Cleanup arm64 build | |
run: | | |
cp build_arm64/extern/afv-native/libafv_native.dylib build/libafv_native.dylib.arm | |
cp build_arm64/vector_audio.app/Contents/MacOS/vector_audio build/vector_audio.arm | |
rm -rf build_arm64/ | |
- name: Create Universal Binary | |
run: | | |
lipo -create build/libafv_native.dylib.arm build/libafv_native.dylib.intel -output build/extern/afv-native/libafv_native.dylib | |
lipo -create build/vector_audio.arm build/vector_audio.intel -output build/vector_audio | |
- name: Bundle OSX | |
run: | | |
./bundle_osx.sh | |
- name: Sign binary | |
uses: lando/code-sign-action@v2 | |
with: | |
file: build/VectorAudio.app | |
certificate-data: ${{ secrets.APPLE_CERT_DATA }} | |
certificate-password: ${{ secrets.APPLE_CERT_PASSWORD }} | |
apple-team-id: ${{ secrets.APPLE_TEAM_ID }} | |
options: --deep --timestamp --force | |
- name: Create DMG | |
run: | | |
brew install create-dmg | |
create-dmg --volname "Vector Audio Installer" --app-drop-link 600 185 --window-size 800 400 --icon "VectorAudio.app" 200 190 "VectorAudio-${{ env.RELEASE_VERSION }}-Universal.dmg" "build/VectorAudio.app" | |
- name: Sign DMG | |
uses: lando/code-sign-action@v2 | |
with: | |
file: VectorAudio-${{ env.RELEASE_VERSION }}-Universal.dmg | |
certificate-data: ${{ secrets.APPLE_CERT_DATA }} | |
certificate-password: ${{ secrets.APPLE_CERT_PASSWORD }} | |
apple-team-id: ${{ secrets.APPLE_TEAM_ID }} | |
- name: Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
files: VectorAudio-${{ env.RELEASE_VERSION }}-Universal.dmg |