update folder name #209
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: Packaging | |
on: | |
push: | |
tags: | |
- "v*" | |
jobs: | |
make-outputs: | |
runs-on: ubuntu-latest | |
outputs: | |
VERSION: ${{ steps.get_version.outputs.VERSION }} | |
steps: | |
- name: Get version | |
id: get_version | |
run: echo "VERSION=${GITHUB_REF/refs\/tags\/v/}" >> $GITHUB_OUTPUT | |
release_windows_amd64: | |
runs-on: windows-latest | |
needs: [make-outputs] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up uv | |
uses: astral-sh/setup-uv@v3 | |
with: | |
version: "latest" | |
- name: Build with pyinstaller | |
shell: bash -el {0} | |
run: | | |
uv venv --python 3.13 | |
uv build --wheel | |
cd packaging | |
uv pip install -r requirements.txt | |
uv pip install ../dist/*.whl --no-deps | |
uv run pyinstaller libresvip.spec | |
cd dist | |
7z a LibreSVIP-${{ needs.make-outputs.outputs.VERSION }}.win-amd64.7z libresvip | |
rm -rf libresvip | |
- name: Upload build artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: libresvip-win-amd64.zip | |
path: ./packaging/dist/ | |
- name: Create Release | |
uses: softprops/action-gh-release@v2 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
tag_name: v${{ needs.make-outputs.outputs.VERSION }} | |
files: | | |
./packaging/dist/LibreSVIP-${{ needs.make-outputs.outputs.VERSION }}.win-amd64.7z | |
release_windows_msys2_ucrt64: | |
runs-on: windows-latest | |
needs: [make-outputs] | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: msys2/setup-msys2@v2 | |
with: | |
msystem: UCRT64 | |
update: true | |
install: >- | |
mingw-w64-ucrt-x86_64-python-pip | |
mingw-w64-ucrt-x86_64-uv | |
p7zip | |
- name: Build with pyinstaller | |
shell: msys2 {0} | |
run: | | |
uv build --wheel | |
cd packaging | |
python mingw_install.py | |
python -m pip install ../dist/*.whl --no-deps | |
pyinstaller libresvip.spec | |
cd dist | |
7z a LibreSVIP-${{ needs.make-outputs.outputs.VERSION }}.msys2-ucrt64.7z libresvip | |
rm -rf libresvip | |
- name: Upload build artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: libresvip-msys2-ucrt64.zip | |
path: ./packaging/dist/ | |
- name: Create Release | |
uses: softprops/action-gh-release@v2 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
tag_name: v${{ needs.make-outputs.outputs.VERSION }} | |
files: | | |
./packaging/dist/LibreSVIP-${{ needs.make-outputs.outputs.VERSION }}.msys2-ucrt64.7z | |
release_windows_webview: | |
runs-on: windows-latest | |
needs: [make-outputs] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up uv | |
uses: astral-sh/setup-uv@v3 | |
with: | |
version: "latest" | |
- name: Build with pyinstaller | |
shell: bash -el {0} | |
run: | | |
uv venv --python 3.12 | |
uv build --wheel | |
cd packaging | |
uv pip install -r requirements-webui.txt | |
uv pip install ../dist/*.whl --no-deps | |
uv run pyinstaller libresvip-web.spec | |
cd dist | |
7z a LibreSVIP-web-${{ needs.make-outputs.outputs.VERSION }}.win-amd64.7z libresvip-web | |
rm -rf libresvip-web | |
- name: Upload build artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: libresvip-web-win-amd64.zip | |
path: ./packaging/dist/ | |
- name: Create Release | |
uses: softprops/action-gh-release@v2 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
tag_name: v${{ needs.make-outputs.outputs.VERSION }} | |
files: | | |
./packaging/dist/LibreSVIP-web-${{ needs.make-outputs.outputs.VERSION }}.win-amd64.7z | |
release_windows_arm64: | |
runs-on: ubuntu-latest | |
needs: [make-outputs] | |
env: | |
PYINSTALLER_VERSION: "6.11.1" | |
PYTHON_VERSION: "3.12" | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up uv | |
uses: astral-sh/setup-uv@v3 | |
with: | |
version: "latest" | |
- name: Build with pyinstaller | |
run: | | |
uv build --wheel | |
uv venv --python $PYTHON_VERSION | |
cd packaging | |
export MINGW_PACKAGE_PREFIX=mingw-w64-clang-aarch64 | |
export MSYSTEM=CLANGARM64 | |
uv run python -m ensurepip | |
uv run python mingw_install.py | |
docker compose -f docker-compose-msys2-clangarm64.yml up | |
uv run python -m pip download pyinstaller==$PYINSTALLER_VERSION --platform win_arm64 --only-binary=:all: | |
uv run python -m pip install wheel | |
uv run python -m wheel unpack pyinstaller-$PYINSTALLER_VERSION-py3-none-win_arm64.whl | |
sudo mv ./pyinstaller-$PYINSTALLER_VERSION/PyInstaller/bootloader/Windows-64bit-arm ./clangarm64/lib/python$PYTHON_VERSION/site-packages/PyInstaller/bootloader | |
sudo cp ./clangarm64/bin/libmediainfo-0.dll ./clangarm64/lib/python$PYTHON_VERSION/site-packages/pymediainfo/ | |
docker compose -f docker-compose-build-wine-arm64.yml up | |
mkdir archive | |
cd dist | |
7z a ../archive/LibreSVIP-${{ needs.make-outputs.outputs.VERSION }}.win-arm64.7z libresvip | |
- name: Upload build artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: libresvip-win-arm64.zip | |
path: ./packaging/archive/ | |
- name: Create Release | |
uses: softprops/action-gh-release@v2 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
tag_name: v${{ needs.make-outputs.outputs.VERSION }} | |
files: | | |
./packaging/archive/LibreSVIP-${{ needs.make-outputs.outputs.VERSION }}.win-arm64.7z | |
release_windows_arm64_webview: | |
runs-on: ubuntu-latest | |
needs: [make-outputs] | |
env: | |
PYTHON_VERSION: "3.12" | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up uv | |
uses: astral-sh/setup-uv@v3 | |
with: | |
version: "latest" | |
- name: Build with pyinstaller | |
run: | | |
uv build --wheel | |
uv venv --python $PYTHON_VERSION | |
cd packaging | |
uv run python -m ensurepip | |
uv run python download_win_arm64_web_wheels.py | |
ls *.whl > requirements-web.txt | |
mkdir python | |
curl -O https://www.python.org/ftp/python/3.12.7/python-3.12.7-embed-arm64.zip | |
unzip python-3.12.7-embed-arm64.zip -d python | |
rm python/python312._pth | |
curl https://bootstrap.pypa.io/get-pip.py -o python/get-pip.py | |
docker compose -f docker-compose-webui-wine-arm64.yml up | |
mkdir archive | |
cd dist | |
7z a ../archive/LibreSVIP-web-${{ needs.make-outputs.outputs.VERSION }}.win-arm64.7z libresvip-web | |
- name: Upload build artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: libresvip-web-win-arm64.zip | |
path: ./packaging/archive/ | |
- name: Create Release | |
uses: softprops/action-gh-release@v2 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
tag_name: v${{ needs.make-outputs.outputs.VERSION }} | |
files: | | |
./packaging/archive/LibreSVIP-web-${{ needs.make-outputs.outputs.VERSION }}.win-arm64.7z | |
release_linux_x86_64: | |
runs-on: ubuntu-latest | |
needs: [make-outputs] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up uv | |
uses: astral-sh/setup-uv@v3 | |
with: | |
version: "latest" | |
- name: Install OS dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y libegl1 | |
- name: Build with pyinstaller | |
run: | | |
uv build --wheel | |
uv venv --python 3.13 | |
cd packaging | |
uv pip install -r requirements.txt | |
uv pip install ../dist/*.whl --no-deps | |
uv run pyinstaller libresvip.spec | |
cd dist | |
tar -czvf LibreSVIP-${{ needs.make-outputs.outputs.VERSION }}.linux-x86_64.tar.gz libresvip | |
rm -rf libresvip | |
- name: Upload build artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: libresvip-linux-x86_64.zip | |
path: ./packaging/dist/ | |
- name: Create Release | |
uses: softprops/action-gh-release@v2 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
tag_name: v${{ needs.make-outputs.outputs.VERSION }} | |
files: | | |
./packaging/dist/LibreSVIP-${{ needs.make-outputs.outputs.VERSION }}.linux-x86_64.tar.gz | |
release_linux_aarch64: | |
runs-on: ubuntu-latest | |
needs: [make-outputs] | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: uraimo/run-on-arch-action@v2 | |
name: Build artifact | |
with: | |
arch: aarch64 | |
distro: ubuntu20.04 | |
dockerRunArgs: --volume "${PWD}:/libresvip" | |
install: | | |
apt-get update | |
apt-get install -y binutils curl libdouble-conversion3 libfreetype6 libfontconfig1 libegl1 libgl1 libglib2.0-0 libmediainfo-dev libtiff5 libwayland-dev libwebp6 libwebpdemux2 libwebpmux3 libxt6 | |
run: | | |
cd /libresvip | |
curl -LsSf https://astral.sh/uv/install.sh | sh | |
source $HOME/.local/bin/env | |
uv venv --python 3.13 | |
uv build --wheel | |
cd packaging | |
uv pip install -r requirements.txt | |
uv pip install ../dist/*.whl --no-deps | |
uv run pyinstaller libresvip.spec | |
cd dist | |
tar -czvf LibreSVIP-${{ needs.make-outputs.outputs.VERSION }}.linux-aarch64.tar.gz libresvip | |
rm -rf libresvip | |
cd ../.. | |
- name: Upload build artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: libresvip-linux-aarch64.zip | |
path: ./packaging/dist | |
- name: Create Release | |
uses: softprops/action-gh-release@v2 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
tag_name: v${{ needs.make-outputs.outputs.VERSION }} | |
files: | | |
./packaging/dist/LibreSVIP-${{ needs.make-outputs.outputs.VERSION }}.linux-aarch64.tar.gz | |
release_macos_x86_64: | |
runs-on: macos-13 | |
needs: [make-outputs] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up uv | |
uses: astral-sh/setup-uv@v3 | |
with: | |
version: "latest" | |
- name: Build with pyinstaller | |
run: | | |
uv build --wheel | |
uv venv --python 3.13 | |
cd packaging | |
uv pip install -r requirements.txt | |
uv pip install ../dist/*.whl --no-deps | |
uv run python -m PyInstaller libresvip.spec | |
brew install create-dmg | |
create-dmg --volname "LibreSVIP" dist/LibreSVIP-${{ needs.make-outputs.outputs.VERSION }}.macos-x86_64.dmg ./dist/LibreSVIP.app | |
rm -rf ./dist/LibreSVIP.app | |
cd .. | |
- name: Upload build artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: libresvip-macos-x86_64.zip | |
path: ./packaging/dist/ | |
- name: Create Release | |
uses: softprops/action-gh-release@v2 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
tag_name: v${{ needs.make-outputs.outputs.VERSION }} | |
files: | | |
./packaging/dist/LibreSVIP-${{ needs.make-outputs.outputs.VERSION }}.macos-x86_64.dmg | |
release_macos_arm64: | |
runs-on: macos-latest | |
needs: [make-outputs] | |
env: | |
LIBMEDIAINFO_VERSION: "24.11" | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up uv | |
uses: astral-sh/setup-uv@v3 | |
with: | |
version: "latest" | |
- name: Build with pyinstaller | |
run: | | |
uv build --wheel | |
uv venv --python 3.13 | |
cd packaging | |
uv pip install -r requirements.txt | |
curl -L https://mediaarea.net/download/binary/libmediainfo0/${LIBMEDIAINFO_VERSION}/MediaInfo_DLL_${LIBMEDIAINFO_VERSION}_Mac_x86_64+arm64.tar.bz2 --output libmediainfo.tar.bz2 | |
tar xvf libmediainfo.tar.bz2 | |
mv MediaInfoLib/libmediainfo.0.dylib ../.venv/lib/python3.13/site-packages/pymediainfo/ | |
uv pip install ../dist/*.whl --no-deps | |
uv run python -m PyInstaller libresvip.spec | |
brew install create-dmg | |
create-dmg --volname "LibreSVIP" dist/LibreSVIP-${{ needs.make-outputs.outputs.VERSION }}.macos-arm64.dmg ./dist/LibreSVIP.app | |
rm -rf ./dist/LibreSVIP.app | |
cd .. | |
- name: Upload build artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: libresvip-macos-arm64.zip | |
path: ./packaging/dist/ | |
- name: Create Release | |
uses: softprops/action-gh-release@v2 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
tag_name: v${{ needs.make-outputs.outputs.VERSION }} | |
files: | | |
./packaging/dist/LibreSVIP-${{ needs.make-outputs.outputs.VERSION }}.macos-arm64.dmg |