]> git.immae.eu Git - perso/Immae/Projets/Python/MusicSampler.git/blame_incremental - music_sampler.spec
Some documentation modifications
[perso/Immae/Projets/Python/MusicSampler.git] / music_sampler.spec
... / ...
CommitLineData
1# -*- mode: python -*-
2import os
3from kivy.tools.packaging.pyinstaller_hooks import get_deps_minimal,\
4 hookspath, runtime_hooks
5
6excluded_and_hidden_modules = get_deps_minimal(
7 video=None,
8 camera=None,
9 audio=None,
10 clipboard=None,
11 spelling=None)
12
13excluded_and_hidden_modules['hiddenimports'] += [
14 'six',
15 'packaging',
16 'packaging.version',
17 'packaging.specifiers',
18 'packaging.requirements' ]
19
20commit_message = os.popen('git log -1 --format="%h %ci"').read()
21pyinstaller_file = open(".pyinstaller_commit", "w")
22pyinstaller_file.write(commit_message)
23pyinstaller_file.close()
24
25a = Analysis(['music_sampler.py'],
26 binaries=None,
27 datas=[
28 ('fonts/*', 'fonts'),
29 ('music_sampler.kv', '.'),
30 ('.pyinstaller_commit', '.')
31 ],
32 hookspath=hookspath(),
33 runtime_hooks=runtime_hooks(),
34 **excluded_and_hidden_modules)
35pyz = PYZ(a.pure, a.zipped_data)
36
37# Single file
38exe = EXE(pyz, a.scripts, a.binaries, a.zipfiles, a.datas,
39 name='music_sampler')
40
41# Directory
42# exe = EXE(pyz, a.scripts,
43# exclude_binaries=True,
44# name='music_sampler_dir',
45# debug=False,
46# strip=False,
47# upx=True,
48# console=True)
49# coll = COLLECT(exe, a.binaries, a.zipfiles, a.datas,
50# strip=False,
51# upx=True,
52# name='music_sampler_dir')