if incl_abs_fname in self.data.previously_included:
return
try:
- fp = open(incl_abs_fname, 'r')
+ fp = open(incl_abs_fname, 'rt', encoding='utf-8')
except IOError as e:
raise KconfigParserError(self,
'%s: %s' % (e.strerror, include))
parser.do_assignment(name, value == 'y')
external_vars.add(name[7:])
else:
- fp = open(arg, 'r')
+ fp = open(arg, 'rt', encoding='utf-8')
parser.parse_file(fp)
fp.close()
if key not in external_vars and config[key]:
print ('CONFIG_%s=y' % key)
- deps = open(argv[2], 'w')
+ deps = open(argv[2], 'wt', encoding='utf-8')
for fname in data.previously_included:
print ('%s: %s' % (argv[1], fname), file=deps)
deps.close()