|
@@ -1,6 +1,8 @@
|
|
1
|
+import sys
|
|
2
|
+
|
1
|
3
|
#dynamic build flags for generic compile options
|
2
|
4
|
if __name__ == "__main__":
|
3
|
|
- print " ".join([ "-std=gnu11",
|
|
5
|
+ args = " ".join([ "-std=gnu11",
|
4
|
6
|
"-std=gnu++11",
|
5
|
7
|
"-Os",
|
6
|
8
|
"-mcpu=cortex-m3",
|
|
@@ -10,13 +12,11 @@ if __name__ == "__main__":
|
10
|
12
|
"-fsigned-char",
|
11
|
13
|
"-fno-move-loop-invariants",
|
12
|
14
|
|
13
|
|
- "-Wall",
|
14
|
15
|
"--specs=nano.specs",
|
15
|
16
|
"--specs=nosys.specs",
|
16
|
17
|
|
17
|
|
- "-IMarlin/frameworks/CMSIS/LPC1768/include",
|
18
|
|
- "-IMarlin/frameworks/CMSIS/LPC1768/lib",
|
19
|
18
|
"-IMarlin/src/HAL",
|
|
19
|
+ "-IMarlin/src/HAL/HAL_LPC1768/include",
|
20
|
20
|
|
21
|
21
|
"-MMD",
|
22
|
22
|
"-MP",
|
|
@@ -24,6 +24,11 @@ if __name__ == "__main__":
|
24
|
24
|
"-DIS_REARM"
|
25
|
25
|
])
|
26
|
26
|
|
|
27
|
+ for i in range(1, len(sys.argv)):
|
|
28
|
+ args += " " + sys.argv[i]
|
|
29
|
+
|
|
30
|
+ print args
|
|
31
|
+
|
27
|
32
|
# extra script for linker options
|
28
|
33
|
else:
|
29
|
34
|
from SCons.Script import DefaultEnvironment
|
|
@@ -46,6 +51,5 @@ else:
|
46
|
51
|
"--specs=nano.specs",
|
47
|
52
|
"--specs=nosys.specs",
|
48
|
53
|
"-u_printf_float",
|
49
|
|
- "-Wl,-TMarlin/frameworks/CMSIS/LPC1768/Re-ARM/LPC1768.ld,--gc-sections"
|
50
|
54
|
],
|
51
|
55
|
)
|