-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpremake_gen.bat
118 lines (103 loc) · 3.22 KB
/
premake_gen.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
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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
REM ############################################################################
REM ## Name: premake_gen.bat
REM ## Purpose: Premake 4 build script for Windows.
REM ## Author: Andrea Zanellato
REM ## Modified by:
REM ## Created: 2011/10/22
REM ## Copyleft: (ↄ) Andrea Zanellato
REM ## Licence: GNU General Public License Version 3
REM ############################################################################
@ECHO OFF
REM Clear output
CLS
REM Set Defaults
SET wxcompiler=gcc
SET wxmedia=yes
SET wxmonolithic=no
SET wxroot=%WXWIN%
SET wxstatic=no
SET wxunicode=yes
SET wxversion=2.9
REM Handle parameters
:Loop
REM Show help and exit
IF [%1]==[-h] GOTO Help
IF [%1]==[--help] GOTO Help
IF [%1]==[--wxcompiler] GOTO Compiler
IF [%1]==[--wxmedia] GOTO Media
IF [%1]==[--wxmonolithic] GOTO Monolithic
IF [%1]==[--wxstatic] GOTO Static
IF [%1]==[--wxroot] GOTO Root
IF [%1]==[--wxunicode] GOTO Unicode
IF [%1]==[--wxversion] GOTO Version
GOTO Premake
:Help
ECHO.
ECHO Available options:
ECHO.
ECHO --wxcompiler Specify the compiler to use.
ECHO Example: --wxcompiler=vc if you use MSVC.
ECHO Current: %wxcompiler%
ECHO.
ECHO --wxmedia Disable wxMedia library (wxMediaCtrl).
ECHO Example: --wxmedia=no to disable it.
ECHO Default: %wxmedia%
ECHO.
ECHO --wxunicode Whether to use an Unicode or an ANSI build.
ECHO Ignored in wxWidgets 2.9 and later.
ECHO Example: --wxunicode=no produces an ANSI build.
ECHO Default: %wxunicode%
ECHO.
ECHO --wxroot Specify the wxWidgets build path,
ECHO useful for wxWidgets builds not installed
ECHO in your system (alternate/custom builds)
ECHO Example: --wxroot=D:\Devel\wxWidgets\3.0
ECHO Current: %WXWIN%
ECHO.
ECHO --wxversion Specify the wxWidgets version.
ECHO Example: --wxversion=3.0
ECHO Default: %wxversion%
ECHO.
GOTO End
:Compiler
SET wxcompiler=%2
SHIFT
SHIFT
GOTO Loop
:Media
SET wxmedia=%2
SHIFT
SHIFT
GOTO Loop
:Monolithic
SET wxmonolithic=%2
SHIFT
SHIFT
GOTO Loop
:Root
SET wxroot=%2
SHIFT
SHIFT
GOTO Loop
:Static
SET wxstatic=%2
SHIFT
SHIFT
GOTO Loop
:Unicode
SET wxunicode=%2
SHIFT
SHIFT
GOTO Loop
:Version
SET wxversion=%2
SHIFT
SHIFT
GOTO Loop
:Premake
build\premake\windows\premake4.exe --file=build/premake/solution.lua --wxcompiler=%wxcompiler% --wxmedia=%wxmedia% --wxmonolithic=%wxmonolithic% --wxroot=%wxroot% --wxstatic=%wxstatic% --wxunicode=%wxunicode% --wxversion=%wxversion% codelite
build\premake\windows\premake4.exe --file=build/premake/solution.lua --wxcompiler=%wxcompiler% --wxmedia=%wxmedia% --wxmonolithic=%wxmonolithic% --wxroot=%wxroot% --wxstatic=%wxstatic% --wxunicode=%wxunicode% --wxversion=%wxversion% codeblocks
ECHO.
REM build\premake\windows\premake4.exe --file=build/premake/solution.lua --wxcompiler=%wxcompiler% --wxmedia=%wxmedia% --wxmonolithic=%wxmonolithic% --wxroot=%wxroot% --wxstatic=%wxstatic% --wxunicode=%wxunicode% --wxversion=%wxversion% vs2008
ECHO.
:End