summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemko Tronçon <git@el-tramo.be>2009-08-28 20:18:22 (GMT)
committerRemko Tronçon <git@el-tramo.be>2009-08-28 20:18:41 (GMT)
commitbb80efbacd3e02728c3a9cbbf3c73ac4beeb997e (patch)
tree7b1795527dad9d972c4c4c2ad7a9f65a4b619832
parent9b1f1503b7a58176f10cd34658966f440ec3a68b (diff)
downloadswift-bb80efbacd3e02728c3a9cbbf3c73ac4beeb997e.zip
swift-bb80efbacd3e02728c3a9cbbf3c73ac4beeb997e.tar.bz2
Make version tool work on Windows.
-rw-r--r--BuildTools/SCons/Version.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/BuildTools/SCons/Version.py b/BuildTools/SCons/Version.py
index c707942..94f8510 100644
--- a/BuildTools/SCons/Version.py
+++ b/BuildTools/SCons/Version.py
@@ -1,7 +1,7 @@
-import subprocess
+import subprocess, os
def getGitBuildVersion() :
- p = subprocess.Popen("git rev-parse HEAD", shell=True, stdin=subprocess.PIPE, stdout=subprocess.PIPE, close_fds=True)
+ p = subprocess.Popen("git rev-parse HEAD", shell=True, stdin=subprocess.PIPE, stdout=subprocess.PIPE, close_fds=(os.name != "nt"))
return p.stdout.read().rstrip()[0:7]
def getBuildVersion(version = None) :