Fix Linux release build exceeding 4GB PyInstaller limit

Install CPU-only PyTorch on Linux and exclude nvidia modules from
non-CUDA PyInstaller builds.
This commit is contained in:
Jamie Pine
2026-03-13 21:19:24 -07:00
parent 9044b986f3
commit f3fc63942f
2 changed files with 17 additions and 6 deletions
+5 -6
View File
@@ -61,17 +61,16 @@ jobs:
pip install pyinstaller
pip install -r backend/requirements.txt
- name: Install CPU-only PyTorch (Linux)
if: matrix.platform == 'ubuntu-22.04'
run: |
pip install torch torchaudio --index-url https://download.pytorch.org/whl/cpu --force-reinstall --no-deps
- name: Install MLX dependencies (Apple Silicon only)
if: matrix.backend == 'mlx'
run: |
pip install -r backend/requirements-mlx.txt
# - name: Install PyTorch with CUDA (Windows only)
# if: matrix.platform == 'windows-latest'
# run: |
# pip install torch --index-url https://download.pytorch.org/whl/cu121 --force-reinstall --no-deps
# pip install torchvision torchaudio --index-url https://download.pytorch.org/whl/cu121
- name: Build Python server (Linux/macOS)
if: matrix.platform != 'windows-latest'
run: |