1
0
Эх сурвалжийг харах

Merge pull request #5498 from Guozhanxin/buildbot

update buildbot.py
Bernard Xiong 3 жил өмнө
parent
commit
982ad7bcbc
2 өөрчлөгдсөн 10 нэмэгдсэн , 10 устгасан
  1. 0 2
      tools/1.txt
  2. 10 8
      tools/buildbot.py

+ 0 - 2
tools/1.txt

@@ -1,2 +0,0 @@
-Cannot found RT-Thread root directory, please check RTT_ROOT
-C:\Users\92036\Desktop\rtt\bsp

+ 10 - 8
tools/buildbot.py

@@ -39,15 +39,17 @@ def update_all_project_files(root_path):
     if os.path.isdir(root_path):
         projects = os.listdir(root_path)
         # is a project path?
-        if "SConscript" in projects:
+        if "SConstruct" in projects:
             try:
-                if "win32" in sys.platform:
-                    retval = os.getcwd()
-                    os.chdir(root_path)
-                    os.system("menuconfig --silent")
-                    os.chdir(retval)
-                else:
-                    os.system('scons --pyconfig-silent -C {0}'.format(root_path)) # update rtconfig.h and .config
+                # update rtconfig.h and .config
+                if "Kconfig" in projects:
+                    if "win32" in sys.platform:
+                        retval = os.getcwd()
+                        os.chdir(root_path)
+                        os.system("menuconfig --silent")
+                        os.chdir(retval)
+                    else:
+                        os.system('scons --pyconfig-silent -C {0}'.format(root_path))
                 update_project_file(root_path)
             except Exception as e:
                 print("error message: {}".format(e))