Skip to content

Commit

Permalink
even more arch detects
Browse files Browse the repository at this point in the history
  • Loading branch information
cdgriffith committed Aug 6, 2024
1 parent 597ff15 commit f935840
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ jobs:
run: |
mkdir dist
echo "::set-env name=VERSION::$(python scripts/get_version.py)"
echo "::set-env name=ARCH::$(/usr/bin/arch)"
echo "Building branch ${{env.GITHUB_REF}} - version ${{env.VERSION}}"
echo "::set-env name=ARCH::$(python -c 'import platform; print(\"arm64\" if \"arm64\" in platform.platform() else \"x86_64\")')"
echo "Building branch ${{env.GITHUB_REF}} - version ${{env.VERSION}} - on ${{env.ARCH}}"
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true

Expand Down
6 changes: 1 addition & 5 deletions FastFlix_Nix_OneFile.spec
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ from PyInstaller.utils.hooks import collect_submodules
import toml
import os
import platform
from subprocess import check_output

block_cipher = None

Expand Down Expand Up @@ -41,9 +40,6 @@ a = Analysis(['fastflix/__main__.py'],
pyz = PYZ(a.pure, a.zipped_data,
cipher=block_cipher)

arch = check_output("/usr/bin/arch").decode().strip()
print("Arch output:", arch)

exe = EXE(pyz,
a.scripts,
a.binaries,
Expand All @@ -57,7 +53,7 @@ exe = EXE(pyz,
upx=False,
upx_exclude=[],
runtime_tmpdir=None,
target_arch=arch,
target_arch='arm64' if 'arm64' in platform.platform() else 'x86_64',
console=True,
icon='fastflix/data/icon.ico'
)

0 comments on commit f935840

Please sign in to comment.