Create target directory if it does not exist. Closes #935.

pull/1017/head
Jussi Pakkanen 8 years ago
parent cf7b50364f
commit 4d8e3be08f
  1. 4
      mesonbuild/mesonmain.py

@ -89,6 +89,10 @@ class MesonApp():
def validate_core_dirs(self, dir1, dir2):
ndir1 = os.path.abspath(dir1)
ndir2 = os.path.abspath(dir2)
if not os.path.exists(ndir1):
os.makedirs(ndir1)
if not os.path.exists(ndir2):
os.makedirs(ndir2)
if not stat.S_ISDIR(os.stat(ndir1).st_mode):
raise RuntimeError('%s is not a directory' % dir1)
if not stat.S_ISDIR(os.stat(ndir2).st_mode):

Loading…
Cancel
Save