Use PROJECT_NAME instead of os.path.basename(PROJECT_PATH)
authorduplo <duplo@38d2e660-2303-0410-9eaa-f027e97ec537>
Fri, 23 Apr 2010 15:11:02 +0000 (15:11 +0000)
committerduplo <duplo@38d2e660-2303-0410-9eaa-f027e97ec537>
Fri, 23 Apr 2010 15:11:02 +0000 (15:11 +0000)
git-svn-id: https://src.develer.com/svnoss/bertos/trunk@3512 38d2e660-2303-0410-9eaa-f027e97ec537

wizard/bertos_utils.py

index 6327fd5ea4478f1154d59b6ecebfb995700ee2a5..972438df4781643e7a69c757c38f8f134220aa08 100644 (file)
@@ -151,7 +151,7 @@ def mkGenerator(project_info, makefile):
     Generates the mk file for the current project.
     """
     mk_data = {}
-    mk_data["$pname"] = os.path.basename(project_info.info("PROJECT_PATH"))
+    mk_data["$pname"] = project_info.info("PROJECT_NAME")
     mk_data["$cpuclockfreq"] = project_info.info("SELECTED_FREQ")
     cpu_mk_parameters = []
     for key, value in project_info.info("CPU_INFOS").items():
@@ -173,7 +173,7 @@ def makefileGenerator(project_info, makefile):
     """
     # TODO write a general function that works for both the mk file and the Makefile
     while makefile.find("$pname") != -1:
-        makefile = makefile.replace("$pname", os.path.basename(project_info.info("PROJECT_PATH")))
+        makefile = makefile.replace("$pname", project_info.info("PROJECT_NAME"))
     return makefile
 
 def csrcGenerator(project_info):