瀏覽代碼

Add support to import custom variables from parent SConstruct (redux)

Adam Scott 2 年之前
父節點
當前提交
982e01ec7f
共有 1 個文件被更改,包括 4 次插入0 次删除
  1. 4 0
      SConstruct

+ 4 - 0
SConstruct

@@ -22,6 +22,10 @@ env.PrependENVPath("PATH", os.getenv("PATH"))
 
 # Custom options and profile flags.
 customs = ["custom.py"]
+try:
+    customs += Import("customs")
+except:
+    pass
 profile = ARGUMENTS.get("profile", "")
 if profile:
     if os.path.isfile(profile):