mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2026-09-25 06:13:56 +08:00
[Tools] Change building script for Py3
This commit is contained in:
+2
-2
@@ -6,7 +6,7 @@ def genconfig() :
|
||||
PreProcessor = SCons.cpp.PreProcessor()
|
||||
|
||||
try:
|
||||
f = file('rtconfig.h', 'r')
|
||||
f = open('rtconfig.h', 'r')
|
||||
contents = f.read()
|
||||
f.close()
|
||||
except :
|
||||
@@ -16,7 +16,7 @@ def genconfig() :
|
||||
options = PreProcessor.cpp_namespace
|
||||
|
||||
try:
|
||||
f = file('.config', 'w')
|
||||
f = open('.config', 'w')
|
||||
for (opt, value) in options.items():
|
||||
if type(value) == type(1):
|
||||
f.write("CONFIG_%s=%d\n" % (opt, value))
|
||||
|
||||
Reference in New Issue
Block a user