1 2 3 4 5 6 7 8 9 10 11
12 /*!
13 * ======== gnu.targets.arm.ITarget ========
14 * Interface to GCC compatible Arm compilers
15 */
16 metaonly interface ITarget inherits gnu.targets.ITarget {
17 /*!
18 * ======== ar ========
19 * The command used to create an archive
20 */
21 override readonly config xdc.bld.ITarget2.Command ar = {
22 cmd: "$(rootDir)/bin/$(GCCTARG)-ar",
23 opts: "cr"
24 };
25
26 /*!
27 * ======== lnk ========
28 * The command used to link executables.
29 */
30 override readonly config xdc.bld.ITarget2.Command lnk = {
31 cmd: "$(rootDir)/bin/$(GCCTARG)-gcc",
32 opts: ""
33 };
34
35 /*!
36 * ======== cc ========
37 * The command used to compile C/C++ source files into object files
38 */
39 override readonly config xdc.bld.ITarget2.Command cc = {
40 cmd: "$(rootDir)/bin/$(GCCTARG)-gcc -c -MD -MF $@.dep",
41 opts: ""
42 };
43
44 /*!
45 * ======== asm ========
46 * The command used to assembles assembly source files into object files
47 */
48 override readonly config xdc.bld.ITarget2.Command asm = {
49 cmd: "$(rootDir)/bin/$(GCCTARG)-gcc -c -x assembler",
50 opts: ""
51 };
52
53 54 55 56 57 58 59 60
61 override config xdc.bld.ITarget.OptionSet profiles[string] = [
62 ["debug", {
63 compileOpts: {
64 copts: "-g",
65 defs: "-D_DEBUG_=1",
66 },
67 linkOpts: "-g",
68 }],
69
70 ["release", {
71 compileOpts: {
72 copts: "-O2 -ffunction-sections",
73 },
74 linkOpts: "-Wl,--gc-sections",
75 }],
76
77 ["profile", {
78 compileOpts: {
79 copts: "-g -pg",
80 },
81 linkOpts: "-pg"
82 }],
83
84 ["coverage", {
85 compileOpts: {
86 copts: "-fprofile-arcs -ftest-coverage",
87 },
88 linkOpts: "-fprofile-arcs -ftest-coverage",
89 }],
90 ];
91
92
93
94 }
95 96 97 98
99