Skip to content

Commit cb05207

Browse files
committed
built-in compiler models
1 parent 0ba1a0a commit cb05207

18 files changed

Lines changed: 7072 additions & 0 deletions
Lines changed: 173 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,173 @@
1+
{
2+
"name": "Keil C51 Compiler",
3+
"id": "KEIL_C51",
4+
"version": {
5+
"args": "",
6+
"matcher": "^(?<name>C51 COMPILER) V(?<version>\\d[\\d\\.]+)"
7+
},
8+
"ERR_LEVEL": 1,
9+
"global": {
10+
"misc-controls": {
11+
"type": "list",
12+
"command": "",
13+
"group": [
14+
"c/cpp",
15+
"asm",
16+
"linker"
17+
]
18+
}
19+
},
20+
"groups": {
21+
"c/cpp": {
22+
"$path": "BIN/C51",
23+
"$includes": {
24+
"prefix": "INCDIR(",
25+
"body": "${value}",
26+
"sep": ";",
27+
"noQuotes": true,
28+
"suffix": ")"
29+
},
30+
"$defines": {
31+
"prefix": "DEFINE(",
32+
"body": "${key}=${value}",
33+
"sep": ",",
34+
"suffix": ")"
35+
},
36+
"$invoke": {
37+
"useFile": true,
38+
"body": "@${value}"
39+
},
40+
"$output": "OBJECT(${out})",
41+
"$default": [
42+
"OMF2",
43+
"TABS(4)",
44+
"CODE",
45+
"NOCOND",
46+
"SYMBOLS"
47+
],
48+
"$listPath": {
49+
"type": "value",
50+
"prefix": "PRINT(",
51+
"suffix": ")",
52+
"command": "${listPath}"
53+
},
54+
"optimization": {
55+
"type": "value",
56+
"command": "",
57+
"prefix": "OPTIMIZE(",
58+
"suffix": ")"
59+
},
60+
"ram-mode": {
61+
"type": "selectable",
62+
"command": {
63+
"SMALL": "SMALL",
64+
"COMPACT": "COMPACT",
65+
"LARGE": "LARGE",
66+
"false": "SMALL"
67+
}
68+
},
69+
"rom-mode": {
70+
"type": "selectable",
71+
"command": {
72+
"SMALL": "SMALL",
73+
"COMPACT": "COMPACT",
74+
"LARGE": "LARGE",
75+
"false": "LARGE"
76+
},
77+
"prefix": "ROM(",
78+
"suffix": ")"
79+
}
80+
},
81+
"asm": {
82+
"$path": "BIN/A51",
83+
"$invoke": {
84+
"useFile": true,
85+
"body": "@${value}"
86+
},
87+
"$includes": {
88+
"prefix": "INCDIR(",
89+
"body": "${value}",
90+
"sep": ";",
91+
"noQuotes": true,
92+
"suffix": ")"
93+
},
94+
"$output": "OBJECT(${out}) EP",
95+
"$quotePath": false,
96+
"$listPath": {
97+
"type": "value",
98+
"prefix": "PRINT(",
99+
"suffix": ")",
100+
"command": "${listPath}"
101+
},
102+
"ram-mode": {
103+
"type": "selectable",
104+
"prefix": "SET(",
105+
"suffix": ")",
106+
"command": {
107+
"SMALL": "SMALL",
108+
"COMPACT": "COMPACT",
109+
"LARGE": "LARGE",
110+
"false": "LARGE"
111+
}
112+
}
113+
},
114+
"linker": {
115+
"$path": "BIN/LX51",
116+
"$invoke": {
117+
"useFile": true,
118+
"body": "@${value}"
119+
},
120+
"$output": "${in} TO ${out}",
121+
"$outputSuffix": "",
122+
"$objPathSep": ",",
123+
"$commandLocation": "end",
124+
"$linkMap": {
125+
"type": "value",
126+
"prefix": "PRINT(",
127+
"command": "${mapPath}",
128+
"suffix": ")"
129+
},
130+
"use-RTX": {
131+
"type": "selectable",
132+
"command": {
133+
"RTX-Full": "RTX51",
134+
"RTX-Tiny": "Rtx51Tiny",
135+
"None": "",
136+
"false": ""
137+
}
138+
},
139+
"remove-unused": {
140+
"type": "selectable",
141+
"command": {
142+
"true": "REMOVEUNUSED",
143+
"false": ""
144+
}
145+
},
146+
"disable-warnings": {
147+
"type": "value",
148+
"prefix": "DISABLEWARNING(",
149+
"suffix": ")",
150+
"command": ""
151+
},
152+
"$outputBin": [
153+
{
154+
"name": "output hex file",
155+
"toolPath": "BIN/Ohx51",
156+
"outputSuffix": ".hex",
157+
"command": "${linkerOutput} HEXFILE(${output}) HEX"
158+
}
159+
]
160+
},
161+
"linker-lib": {
162+
"$path": "BIN/LIBX51",
163+
"$invoke": {
164+
"useFile": true,
165+
"body": "@${value}"
166+
},
167+
"$output": "ADD ${in} TO ${out}",
168+
"$objPathSep": ",",
169+
"$outputSuffix": ".LIB",
170+
"$commandLocation": "end"
171+
}
172+
}
173+
}
Lines changed: 196 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,196 @@
1+
{
2+
"name": "GNU Toolchain",
3+
"id": "GCC",
4+
"toolPrefix": "",
5+
"useUnixPath": true,
6+
"version": {
7+
"args": "--version",
8+
"matcher": "\\((?<name>.*?)\\) (?<version>[\\d\\.]+)"
9+
},
10+
"global": {
11+
"misc-control": {
12+
"type": "list",
13+
"command": "",
14+
"group": [
15+
"c",
16+
"cpp",
17+
"asm"
18+
]
19+
},
20+
"C_FLAGS": {
21+
"type": "list",
22+
"command": "",
23+
"group": [
24+
"c"
25+
]
26+
},
27+
"CXX_FLAGS": {
28+
"type": "list",
29+
"command": "",
30+
"group": [
31+
"cpp"
32+
]
33+
},
34+
"ASM_FLAGS": {
35+
"type": "list",
36+
"command": "",
37+
"group": [
38+
"asm"
39+
]
40+
},
41+
"one-elf-section-per-function": {
42+
"type": "selectable",
43+
"command": {
44+
"true": "-ffunction-sections",
45+
"false": ""
46+
},
47+
"group": [
48+
"c",
49+
"cpp"
50+
]
51+
},
52+
"one-elf-section-per-data": {
53+
"type": "selectable",
54+
"command": {
55+
"true": "-fdata-sections",
56+
"false": ""
57+
},
58+
"group": [
59+
"c",
60+
"cpp"
61+
]
62+
}
63+
},
64+
"groups": {
65+
"c": {
66+
"$path": "bin/${toolPrefix}gcc",
67+
"$includes": {
68+
"body": "-I${value}"
69+
},
70+
"$defines": {
71+
"body": "-D${key}=\"${value}\""
72+
},
73+
"$invoke": {
74+
"useFile": true,
75+
"body": "@${value}"
76+
},
77+
"$output": "-o ${out} -MMD ${in}"
78+
},
79+
"cpp": {
80+
"$path": "bin/${toolPrefix}gcc",
81+
"$includes": {
82+
"body": "-I${value}"
83+
},
84+
"$defines": {
85+
"body": "-D${key}=\"${value}\""
86+
},
87+
"$invoke": {
88+
"useFile": true,
89+
"body": "@${value}"
90+
},
91+
"$output": "-o ${out} -MMD ${in}"
92+
},
93+
"asm": {
94+
"$path": "bin/${toolPrefix}gcc",
95+
"$includes": {
96+
"body": "-I${value}"
97+
},
98+
"$output": "-o ${out} -MMD ${in}",
99+
"$invoke": {
100+
"useFile": true,
101+
"body": "@${value}"
102+
},
103+
"defines": {
104+
"type": "list",
105+
"command": "-D"
106+
}
107+
},
108+
"linker": {
109+
"$path": "bin/${toolPrefix}gcc",
110+
"$libs": {
111+
"body": "-L${value}"
112+
},
113+
"$invoke": {
114+
"useFile": true,
115+
"body": "@${value}"
116+
},
117+
"$output": "-o ${out} ${in} ${lib_flags}",
118+
"$outputSuffix": ".elf",
119+
"$linkMap": {
120+
"type": "value",
121+
"command": "-Wl,-Map=${mapPath}"
122+
},
123+
"$LIB_FLAGS": {
124+
"type": "list",
125+
"command": ""
126+
},
127+
"linker-script": {
128+
"type": "list",
129+
"command": "-T "
130+
},
131+
"remove-unused-input-sections": {
132+
"type": "selectable",
133+
"command": {
134+
"true": "-Wl,--gc-sections",
135+
"false": ""
136+
}
137+
},
138+
"misc-control": {
139+
"type": "list",
140+
"command": ""
141+
},
142+
"LD_FLAGS": {
143+
"type": "list",
144+
"command": ""
145+
}
146+
},
147+
"linker-ld": {
148+
"$path": "bin/${toolPrefix}ld",
149+
"$libs": {
150+
"body": "-L${value}"
151+
},
152+
"$invoke": {
153+
"useFile": true,
154+
"body": "@${value}"
155+
},
156+
"$output": "-o ${out} ${in} ${lib_flags}",
157+
"$outputSuffix": ".elf",
158+
"$linkMap": {
159+
"type": "value",
160+
"command": "-Map=${mapPath}"
161+
},
162+
"$LIB_FLAGS": {
163+
"type": "list",
164+
"command": ""
165+
},
166+
"remove-unused-input-sections": {
167+
"type": "selectable",
168+
"command": {
169+
"true": "--gc-sections",
170+
"false": ""
171+
}
172+
},
173+
"linker-script": {
174+
"type": "list",
175+
"command": "-T "
176+
},
177+
"misc-control": {
178+
"type": "list",
179+
"command": ""
180+
},
181+
"LD_FLAGS": {
182+
"type": "list",
183+
"command": ""
184+
}
185+
},
186+
"linker-lib": {
187+
"$path": "bin/${toolPrefix}ar",
188+
"$invoke": {
189+
"useFile": true,
190+
"body": "@${value}"
191+
},
192+
"$output": "-rcv ${out} ${in}",
193+
"$outputSuffix": ".a"
194+
}
195+
}
196+
}

0 commit comments

Comments
 (0)