summaryrefslogtreecommitdiff
path: root/wscript
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2019-11-02 21:51:12 +0100
committerCarl Hetherington <cth@carlh.net>2019-12-03 17:02:48 +0100
commitb9f1b2fff204041245e6cbd87863969ebca919bb (patch)
treef1747031c6f5bddbba603357846ecf75f24db47b /wscript
parentaa12a6d19a6c63c6ac00db95bf31579be3055321 (diff)
Allow waf to be run with python 3.
Diffstat (limited to 'wscript')
-rw-r--r--wscript6
1 files changed, 4 insertions, 2 deletions
diff --git a/wscript b/wscript
index ff44e84..2dd7228 100644
--- a/wscript
+++ b/wscript
@@ -1,3 +1,5 @@
+from __future__ import print_function
+
import subprocess
import shlex
import os
@@ -8,7 +10,7 @@ from waflib import Logs
APPNAME = 'libasdcp-cth'
if os.path.exists('.git'):
- this_version = subprocess.Popen(shlex.split('git tag -l --points-at HEAD'), stdout=subprocess.PIPE).communicate()[0]
+ this_version = subprocess.Popen(shlex.split('git tag -l --points-at HEAD'), stdout=subprocess.PIPE).communicate()[0].decode('utf-8')
last_version = subprocess.Popen(shlex.split('git describe --tags --abbrev=0'), stdout=subprocess.PIPE).communicate()[0]
if this_version == '':
VERSION = '%sdevel' % last_version[1:].strip()
@@ -106,5 +108,5 @@ def tags(bld):
def dist(bld):
f = open('VERSION', 'w')
- print>>f,VERSION
+ print(VERSION, file=f)
f.close()