1 package local.targets;
2
3 /*!
4 * ======== ITIArm ========
5 * Common definitions for Arm targets
6 *
7 * This interface is used by the `{@link TIArm11}` and `{@link TIArm11D}`
8 * modules in this package. Its sole purpose is to encapsulate
9 * commonality between multiple targets defined in this
10 * package; in this case, `TIArm11` and `TIArm11D`. We could
11 * have used this interface with `TIArm9` but choose not to
12 * for pedagogic reasons.
13 */
14 metaonly interface ITIArm inherits ti.targets.ITarget
15 {
16 override readonly config String rts = "local.targets.rts470";
17
18 override config String stdInclude = "local/targets/std.h";
19
20 override config String platform = "ti.platforms.sim470xx";
21
22 override readonly config ti.targets.ITarget.Command ar = {
23 cmd: "ar470",
24 opts: "rq"
25 };
26
27 override readonly config ti.targets.ITarget.Command vers = {
28 cmd: "cl470",
29 opts: "-version"
30 };
31
32 override readonly config ti.targets.ITarget.Command lnk = {
33 cmd: "lnk470",
34 opts: ""
35 };
36
37 /*!
38 * ======== asmOpts ========
39 * User configurable assembler options.
40 *
41 * Defaults:
42 * @p(dlist)
43 * -`-qq`
44 * super quiet mode
45 */
46 override config ti.targets.ITarget.Options asmOpts = {
47 prefix: "-qq",
48 suffix: ""
49 };
50
51 /*!
52 * ======== ccOpts ========
53 * User configurable compiler options.
54 *
55 * Defaults:
56 * @p(dlist)
57 * -`-q`
58 * quiet mode
59 * -`-pdsw225`
60 * generate a warning for implicitly declared functions; i.e.,
61 * functions without prototypes
62 */
63 override config ti.targets.ITarget.Options ccOpts = {
64 prefix: "-q -pdsw225",
65 suffix: ""
66 };
67
68 /*!
69 * ======== lnkOpts ========
70 * User configurable linker options.
71 *
72 * Defaults:
73 * @p(dlist)
74 * -`-w`
75 * Display linker warnings
76 * -`-q`
77 * Quite run
78 * -`-u`
79 * Place unresolved external symbol into symbol table
80 * -`-c`
81 * ROM autoinitialization model
82 * -`-m`
83 * create a map file
84 */
85 override config ti.targets.ITarget.Options lnkOpts = {
86 prefix: "-w -q -u _c_int00",
87 suffix: "-c -m $(XDCCFGDIR)/$@.map "
88 };
89
90 override config String includeOpts = "-I$(rootDir)/include";
91
92 final override readonly config String sectMap[string] = [
93 [".intvecs", "code"],
94
95 [".text", "code"],
96 [".cinit", "code"],
97 [".const", "code"],
98 [".pinit", "code"],
99
100 [".bss", "data"],
101 [".sysmem", "data"],
102 [".stack", "stack"],
103 [".args", "data"],
104 ];
105 }