X-Git-Url: http://rtime.felk.cvut.cz/gitweb/omk/sssa.git/blobdiff_plain/223d592f136664cf47121d3c0b5abb0bde5807f6..391f17adc34366084f58ff79ba125e1e1b67b811:/omkbuild.py diff --git a/omkbuild.py b/omkbuild.py index 68e555e..f409563 100755 --- a/omkbuild.py +++ b/omkbuild.py @@ -334,7 +334,10 @@ def buildRules(topLevelSnippet, output): sys.stderr.write(diff) sys.exit(1) - if output: f = open(output,"w+") + if output: + try: os.makedirs(os.path.dirname(output)) + except: pass + f = open(output,"w+") else: f = sys.stdout f.writelines(rules.rules) f.close()