build: Fix build error with python3

Change-Id: I2a35d66744330feefeb2c7f95a0f6e4e4c339358
Refs: #1956
diff --git a/.gitignore b/.gitignore
index 97873ea..b54981e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,5 +1,6 @@
 .DS*
 .waf-1*
+.waf3-*
 .lock*
 **/*.pyc
 build/
diff --git a/wscript b/wscript
index b40f416..9f16f14 100644
--- a/wscript
+++ b/wscript
@@ -171,7 +171,7 @@
         cmd = ['git', 'describe', '--always', '--match', '%s*' % GIT_TAG_PREFIX]
         p = Utils.subprocess.Popen(cmd, stdout=Utils.subprocess.PIPE,
                                    stderr=None, stdin=None)
-        out = p.communicate()[0].strip()
+        out = str(p.communicate()[0].strip())
         didGetVersion = (p.returncode == 0 and out != "")
         if didGetVersion:
             if out.startswith(GIT_TAG_PREFIX):