forked from openconnect/openconnect-gui
-
Notifications
You must be signed in to change notification settings - Fork 1
/
build_mingw@win.cmd
83 lines (69 loc) · 2.69 KB
/
build_mingw@win.cmd
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
@echo off
REM
REM Sample build script & release package preapration
REM
REM It should be used only as illustration how to build application
REM and create an installer package
REM
REM (c) 2016-2019, Lubomir Carik
REM
echo "======================================================================="
echo " Preparing environment..."
echo "======================================================================="
REM look for "Qt 5.12.0 for Desktop (MinGW 7.3.0 64 bit)" StartMenu item
REM and check 'qtenv2.bat'
echo Setting up environment for Qt usage...
set PATH=C:\Dev\Qt\5.12.0\mingw73_64\bin\;%PATH%
echo Setting up environment for 'mingw64' usage...
set PATH=c:\Dev\Qt\Tools\mingw730_64\bin\;%PATH%
echo Setting up environment for CMake usage...
set PATH="C:\Program Files\CMake\bin";%PATH%
echo Setting up environment for 7z usage...
set PATH="C:\Program Files\7-Zip\";%PATH%
echo Setting up environment for 'Ninja' usage...
set PATH="C:\Dev\";%PATH%
echo Setting up environment for 'clang' usage...
set PATH="C:\Dev\LLVM\bin\";%PATH%
echo Setting up environment for 'wix' toolset usage...
set PATH="C:\Program Files (x86)\WiX Toolset v3.11\bin";%PATH%
set WIX="C:\Program Files (x86)\WiX Toolset v3.11\"
set CPACK_WIX_ROOT="C:\Program Files (x86)\WiX Toolset v3.11\"
echo "======================================================================="
echo " Preparing sandbox..."
echo "======================================================================="
rd /s /q build-release
md build-release
echo "======================================================================="
echo " Generating project..."
echo "======================================================================="
cd build-release
cmake -G "MinGW Makefiles" ^
-DCMAKE_BUILD_TYPE=Release ^
..\..\
echo "======================================================================="
echo " Compiling..."
echo "======================================================================="
mingw32-make -j5
REM echo "======================================================================="
REM echo " LC: Bundling... (dynamic Qt only)"
REM echo "======================================================================="
REM rd /s /q out
REM md out
REM windeployqt ^
REM src\openconnect-gui.exe ^
REM --verbose 1 ^
REM --compiler-runtime ^
REM --release ^
REM --force ^
REM --no-webkit2 ^
REM --no-quick-import ^
REM --no-translations
echo "======================================================================="
echo " Packaging..."
echo "======================================================================="
cmake .
mingw32-make package VERBOSE=1
REM mingw32-make package_source VERBOSE=1
move /Y *.exe ..
move /Y *.exe.sha512 ..
cd ..