From: Boris Zanin Date: Mon, 3 Jun 2019 12:14:17 +0000 (+0200) Subject: Python3 compatibility: Fix build_apk.py X-Git-Tag: upstream/1.3.5~2069 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ca580f7fc9ec86ef6c93c7baea8d63e00323dda1;p=platform%2Fupstream%2FVK-GL-CTS.git Python3 compatibility: Fix build_apk.py The files build_apk need to be updated ti run under Python 3. Components: Framework VK-GL-CTS issue: 1665 Change-Id: I0c21e7114f2f4d55ebf31353c270cadfbe98dd96 --- diff --git a/scripts/android/build_apk.py b/scripts/android/build_apk.py index 7d4a258..630cd41 100644 --- a/scripts/android/build_apk.py +++ b/scripts/android/build_apk.py @@ -113,7 +113,7 @@ class NDKEnv: try: with open(propFilePath) as propFile: for line in propFile: - keyValue = map(lambda x: string.strip(x), line.split("=")) + keyValue = list(map(lambda x: x.strip(), line.split("="))) if keyValue[0] == "Pkg.Revision": versionParts = keyValue[1].split(".") return tuple(map(int, versionParts[0:2])) @@ -303,8 +303,8 @@ class BuildStep: expandedInputs = BuildStep.expandPathsToFiles(inputs) expandedOutputs = BuildStep.expandPathsToFiles(outputs) - existingInputs = filter(os.path.exists, expandedInputs) - existingOutputs = filter(os.path.exists, expandedOutputs) + existingInputs = list(filter(os.path.exists, expandedInputs)) + existingOutputs = list(filter(os.path.exists, expandedOutputs)) if len(existingInputs) != len(expandedInputs): for file in expandedInputs: