borg.exe.spec 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. # -*- mode: python -*-
  2. # this pyinstaller spec file is used to build borg binaries on posix platforms
  3. import os, sys
  4. basepath = '/vagrant/borg/borg'
  5. block_cipher = None
  6. a = Analysis([os.path.join(basepath, 'borg/__main__.py'), ],
  7. pathex=[basepath, ],
  8. binaries=[],
  9. datas=[],
  10. hiddenimports=['borg.platform.posix'],
  11. hookspath=[],
  12. runtime_hooks=[],
  13. excludes=[],
  14. win_no_prefer_redirects=False,
  15. win_private_assemblies=False,
  16. cipher=block_cipher)
  17. if sys.platform == 'darwin':
  18. # do not bundle the osxfuse libraries, so we do not get a version
  19. # mismatch to the installed kernel driver of osxfuse.
  20. a.binaries = [b for b in a.binaries if 'libosxfuse' not in b[0]]
  21. pyz = PYZ(a.pure, a.zipped_data, cipher=block_cipher)
  22. exe = EXE(pyz,
  23. a.scripts,
  24. a.binaries,
  25. a.zipfiles,
  26. a.datas,
  27. name='borg.exe',
  28. debug=False,
  29. strip=False,
  30. upx=True,
  31. console=True )