+++ /dev/null
-#
-# Copyright 2009 Develer S.r.l. (http://www.develer.com/)
-# All rights reserved.
-#
-# Makefile template for BeRTOS wizard.
-#
-# Author: Lorenzo Berni <duplo@develer.com>
-#
-#
-
-# Set to 1 for debug builds
-pname_DEBUG = 1
-
-# Our target application
-TRG += pname
-CPU = cpuname
-BOOT_ADDR_START = 0x1E000
-
-pname_PREFIX = prefix
-
-pname_SUFFIX = suffix
-
-pname_MCU = $(CPU)
-
-pname_CSRC = \
- csrc
- #
-
-pname_PCSRC += pcsrc
-
-
-pname_CFLAGS = cflags
-pname_LDFLAGS = ldflags
f.write(string)
f.close()
## Destinatio mk file
- makefile = open(sourcesDir + "/" + "template.mk", "r").read()
+ makefile = open("mktemplates/template.mk", "r").read()
makefile = mkGenerator(projectInfos, makefile)
- open(prjdir + "/" + "template.km", "w").write(makefile)
+ open(prjdir + "/" + "template.mk", "w").write(makefile)
def mkGenerator(projectInfos, makefile):
"""
mkData["cflags"] = " ".join(projectInfos.info("CPU_INFOS")["C_FLAGS"])
mkData["ldflags"] = " ".join(projectInfos.info("CPU_INFOS")["LD_FLAGS"])
for key in mkData:
- print key, mkData[key]
while makefile.find(key) != -1:
makefile = makefile.replace(key, mkData[key])
return makefile
--- /dev/null
+#
+# Copyright 2009 Develer S.r.l. (http://www.develer.com/)
+# All rights reserved.
+#
+# Makefile template for BeRTOS wizard.
+#
+# Author: Lorenzo Berni <duplo@develer.com>
+#
+#
+
+# Set to 1 for debug builds
+pname_DEBUG = 1
+
+# Our target application
+TRG += pname
+CPU = cpuname
+BOOT_ADDR_START = 0x1E000
+
+pname_PREFIX = prefix
+
+pname_SUFFIX = suffix
+
+pname_MCU = $(CPU)
+
+pname_CSRC = \
+ csrc
+ #
+
+pname_PCSRC += pcsrc
+
+
+pname_CFLAGS = cflags
+pname_LDFLAGS = ldflags