blob: e617ee62e921777ac6a22c568cdca4fe0ff88819 [file] [log] [blame]
rjw6c1fd8f2022-11-30 14:33:01 +08001#########################
2## . variable part ##
3##########################
4# script, tools, commands
5
6CAT = perl ./tools/init/cat.pl
7CHK_OS = perl ./tools/init/chkOS.pl
8CH_MOD = perl ./tools/init/chmod.pl
9COPY_FILE = perl ./tools/init/copy_files.pl -f
10COPY_DIR = perl ./tools/init/copy_files.pl -r
11COMPARE = perl ./tools/init/compare.pl
12DEL_FILE = perl ./tools/init/remove.pl -f
13DEL_DIR = perl ./tools/init/rmdir.pl -f
14ECHO = perl ./tools/init/echo.pl
15GET_FNAME = perl ./tools/init/get_filename.pl
16LIST_DIR = perl ./tools/init/dir.pl
17MKDIR = perl ./tools/init/mkdir.pl
18MOVE = perl ./tools/init/move.pl -f
19RECURSIVE_DIR = perl ./tools/init/recursive_dir.pl
20
21GEN_TARGET_FILE = python ./tools/genTargetFile/genTargetFile.py True
22
23
24CHK_TIME = perl ./tools/time.pl -n
25CHDIR = cd
26
27# others
28AND = &&
29
30
31OS_VERSION = $(shell perl ./tools/init/chkOS.pl)
32#####################
33## windows section ##
34#####################
35ifeq ($(strip $(OS_VERSION)),MSWin32)
36# script, tools, commands
37LINKER = "./mtk_tools/guardian/Linker.exe"
38SENDER = "./mtk_tools/guardian/Sender.exe"
39STRCMPEX = .\tools\init\strcmpex_window.exe
40MAKE = "./tools/make.exe"
41GREP_V = find /V
42
43# if-else command
44IF = if
45IF_EXIST = if exist
46IF_NOT = if not
47IF_NOT_EXIST = if not exist
48IF_ERR_TRUE = if ERRORLEVEL 1
49IF_ERR_FALSE = if not errorlevel 1
50THEN =
51ELSE = else
52CMD_END =
53
54# for loop command
55FOR = for
56F_OPT = /F usebackq
57IN = in (
58DO = ) do
59DONE =
60
61# condition
62EQU = EQU
63NEQ = NEQ
64
65# others
66DEV_NUL = NUL
67DECLARE_VAR = %%
68PRE_VAR = %%
69P_VAR = %
70WITH = &
71
72else
73###################
74## Linux section ##
75###################
76# script, tools
77LINKER = ./mtk_tools/guardian/Linker
78SENDER = ./mtk_tools/guardian/Sender
79STRCMPEX = ./tools/init/strcmpex_linux.exe
80MAKE = make
81GREP_V = grep -v
82
83# if-else command
84IF = if [
85IF_EXIST = if [ -e
86IF_NOT = if [ !
87IF_NOT_EXIST = if [ ! -e
88IF_ERR_TRUE = if [ $$? != 0
89IF_ERR_FALSE = if [ $$? == 0
90THEN = ]; then
91ELSE = ;else
92CMD_END = ;fi
93
94
95# for loop command
96FOR = for
97F_OPT =
98IN = in
99DO = ;do
100DONE = ;done
101
102# condition
103EQU = =
104NEQ = !=
105
106# others
107DEV_NUL = /dev/null
108DECLARE_VAR =
109PRE_VAR = $$
110P_VAR = $
111WITH = ;
112
113endif # OS_VERSION end
114