From: Luke Kenneth Casson Leighton Date: Tue, 18 May 2021 09:06:10 +0000 (+0100) Subject: add os.makedirs on pyfnwriter output path X-Git-Tag: xlen-bcd~601 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=3892c4979ffddca74b9d483c77d8a1bba37aa6b2;p=openpower-isa.git add os.makedirs on pyfnwriter output path --- diff --git a/src/openpower/decoder/pseudo/pyfnwriter.py b/src/openpower/decoder/pseudo/pyfnwriter.py index c6e37b40..c5dac0d8 100644 --- a/src/openpower/decoder/pseudo/pyfnwriter.py +++ b/src/openpower/decoder/pseudo/pyfnwriter.py @@ -43,6 +43,7 @@ class PyISAFnWriter(ISAFunctions): self.pages_written.append(pagename) function = self.fns[pagename] isadir = get_isafn_src_dir() + os.makedirs(isadir, exist_ok=True) fname = os.path.join(isadir, "%s.py" % pagename) with open(fname, "w") as f: f.write(header % function['desc']) # write out header