Skip to content

Commit

Permalink
Distribute firmwaredl binary
Browse files Browse the repository at this point in the history
  • Loading branch information
achow101 committed Jan 16, 2020
1 parent 47d5e05 commit e356742
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 2 deletions.
3 changes: 2 additions & 1 deletion contrib/build_bin.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ TZ=UTC find ${lib_dir} -name '*.py' -type f -execdir touch -t "201901010000.00"
# Make the standalone binary
export PYTHONHASHSEED=42
poetry run pyinstaller hwi.spec
poetry run pyinstaller firmwaredl.spec
unset PYTHONHASHSEED

# Make the final compressed package
Expand All @@ -32,5 +33,5 @@ OS=`uname | tr '[:upper:]' '[:lower:]'`
if [[ $OS == "darwin" ]]; then
OS="mac"
fi
tar -czf "hwi-${VERSION}-${OS}-amd64.tar.gz" hwi
tar -czf "hwi-${VERSION}-${OS}-amd64.tar.gz" hwi firmwaredl
popd
3 changes: 2 additions & 1 deletion contrib/build_wine.sh
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,11 @@ $POETRY install
# Do the build
export PYTHONHASHSEED=42
$POETRY run pyinstaller hwi.spec
$POETRY run pyinstaller firmwaredl.spec
unset PYTHONHASHSEED

# Make the final compressed package
pushd dist
VERSION=`$POETRY run hwi --version | cut -d " " -f 2 | dos2unix`
zip "hwi-${VERSION}-windows-amd64.zip" hwi.exe
zip "hwi-${VERSION}-windows-amd64.zip" hwi.exe firmwaredl.exe
popd
32 changes: 32 additions & 0 deletions firmwaredl.spec
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# -*- mode: python ; coding: utf-8 -*-

block_cipher = None


a = Analysis(['firmwaredl.py'],
binaries=[],
datas=[],
hiddenimports=[],
hookspath=['contrib/pyinstaller-hooks/'],
runtime_hooks=[],
excludes=[],
win_no_prefer_redirects=False,
win_private_assemblies=False,
cipher=block_cipher,
noarchive=False)
pyz = PYZ(a.pure, a.zipped_data,
cipher=block_cipher)
exe = EXE(pyz,
a.scripts,
a.binaries,
a.zipfiles,
a.datas,
[],
name='firmwaredl',
debug=False,
bootloader_ignore_signals=False,
strip=False,
upx=True,
upx_exclude=[],
runtime_tmpdir=None,
console=True )

0 comments on commit e356742

Please sign in to comment.