Przeglądaj źródła

do not pre-create the static-build directory in the build script

This causes problems when the first target is for setting up schroot,
which is typically run via sudo and will ensure that the directory
will be created with root as owner -- fixes #1751
Ashish Kulkarni 11 lat temu
rodzic
commit
61cda9368f
1 zmienionych plików z 1 dodań i 2 usunięć
  1. 1 2
      scripts/build.py

+ 1 - 2
scripts/build.py

@@ -402,6 +402,7 @@ def mkdir_p(path):
         os.makedirs(path)
 
 def get_version(basedir):
+    mkdir_p(basedir)
     text = open(os.path.join(basedir, '..', 'VERSION'), 'r').read()
     if '-' not in text:
         return (text, text)
@@ -947,8 +948,6 @@ def usage(exit_code=2):
 
 def main():
     basedir = os.path.join(os.path.dirname(os.path.realpath(__file__)), '..', 'static-build')
-    mkdir_p(basedir)
-
     if len(sys.argv) == 1:
         usage(0)