-
Notifications
You must be signed in to change notification settings - Fork 83
/
Copy pathbuild_winC2.bat
executable file
·34 lines (32 loc) · 1.29 KB
/
build_winC2.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
@echo off
echo =^> Installing 'pyinstaller' via pip...
pip install --upgrade pip
pip install wheel
pip install pyinstaller
echo =^> Installing dependencies pip...
pip install winsdk
pip install -r requirements.txt
if exist ffbin_win\ffmpeg.exe (
echo =^> Found 'ffbin_win' directory and ffmpeg binary.. Using ffmpeg binary append mode
pyinstaller --onefile --noconfirm --add-data="src/onthespot/gui/qtui/*.ui;onthespot/gui/qtui" --add-data="src/onthespot/resources/*.png;onthespot/resources" --add-binary="ffbin_win/*.exe;onthespot/bin/ffmpeg" --paths="src/onthespot" --name="onthespot_win_ffm" --icon="src/onthespot/resources/icon.png" src\portable.py
) else (
echo =^> Building to use ffmpeg binary from system...
pyinstaller --onefile --noconfirm --add-data="src/onthespot/gui/qtui/*.ui;onthespot/gui/qtui" --add-data="src/onthespot/resources/*.png;onthespot/resources" --paths="src/onthespot" --name="onthespot_win" --icon="src/onthespot/resources/icon.png" src\portable.py
)
echo =^> Cleaning..
if exist onthespot_win.spec (
del /F /Q /A onthespot_win.spec
)
if exist onthespot_win_ffm.spec (
del /F /Q /A onthespot_win_ffm.spec
)
if exist build\ (
rmdir build /s /q
)
if exist __pycache__\ (
rmdir __pycache__ /s /q
)
if exist venvwin\ (
rmdir venvwin /s /q
)
echo =^> Done