mirror of
https://github.com/borgbackup/borg.git
synced 2025-01-21 23:09:40 +00:00
Updated pyinstaller spec file to support windows builds
This commit is contained in:
parent
2cc270bab0
commit
b57db079d0
1 changed files with 15 additions and 5 deletions
|
@ -3,17 +3,27 @@
|
|||
|
||||
import os, sys
|
||||
|
||||
basepath = '/vagrant/borg/borg'
|
||||
is_win32 = sys.platform.startswith('win32')
|
||||
|
||||
# Note: SPEC contains the spec file argument given to pyinstaller
|
||||
here = os.path.dirname(os.path.abspath(SPEC))
|
||||
|
||||
if is_win32:
|
||||
basepath = os.path.abspath(os.path.join(here, '..'))
|
||||
hiddenimports = []
|
||||
else:
|
||||
basepath = '/vagrant/borg/borg'
|
||||
hiddenimports = ['borg.platform.posix']
|
||||
|
||||
block_cipher = None
|
||||
|
||||
a = Analysis([os.path.join(basepath, 'src/borg/__main__.py'), ],
|
||||
a = Analysis([os.path.join(basepath, 'src', 'borg', '__main__.py'), ],
|
||||
pathex=[basepath, ],
|
||||
binaries=[],
|
||||
datas=[
|
||||
('../src/borg/paperkey.html', 'borg'),
|
||||
(os.path.join(basepath, 'src', 'borg', 'paperkey.html'), 'borg'),
|
||||
],
|
||||
hiddenimports=['borg.platform.posix'],
|
||||
hiddenimports=hiddenimports,
|
||||
hookspath=[],
|
||||
runtime_hooks=[],
|
||||
excludes=[
|
||||
|
@ -39,7 +49,7 @@ exe = EXE(pyz,
|
|||
debug=False,
|
||||
strip=False,
|
||||
upx=True,
|
||||
console=True )
|
||||
console=True)
|
||||
|
||||
if False:
|
||||
# Enable this block to build a directory-based binary instead of
|
||||
|
|
Loading…
Reference in a new issue