Clone of official tools

Revision:
7:5af61d55adbe
Parent:
2:07730b0f452c
Child:
13:ab47a20b66f0
--- a/toolchains/gcc.py	Sat May 21 20:17:44 2016 +0100
+++ b/toolchains/gcc.py	Tue Jun 07 11:21:44 2016 +0100
@@ -211,8 +211,9 @@
             libs.extend(libs)
         
         # Build linker command
-        cmd = self.ld + ["-o", output] + objects
-        
+        map_file = splitext(output)[0] + ".map"
+        cmd = self.ld + ["-o", output, "-Wl,-Map=%s" % map_file] + objects
+
         if mem_map:
             cmd.extend(['-T', mem_map])