]> git.lyx.org Git - features.git/blobdiff - development/scons/scons_utils.py
Scons: config.h moves to BUILDDIR/common, boost_config.h moves to BUILDDIR/boost.
[features.git] / development / scons / scons_utils.py
index a061dd50e892321cd9b86217b7129a2000f6494c..ca16f0ad2e120a0ad97a16834dcf319abfe35e55 100644 (file)
@@ -18,6 +18,10 @@ from SCons.Util import WhereIs
 
 def writeToFile(filename, lines, append = False):
   " utility function: write or append lines to filename "
+  # create directory if needed
+  dir = os.path.split(filename)[0]
+  if dir != '' and not os.path.isdir(dir):
+    os.makedirs(dir)
   if append:
     file = open(filename, 'a')
   else: