summaryrefslogtreecommitdiff
path: root/tools/utils.py
diff options
context:
space:
mode:
authorbernard <[email protected]>2024-05-03 16:04:55 +0800
committerMeco Man <[email protected]>2024-05-03 20:17:23 -0400
commitc4e7a0e5e3d4442983942a0f79b16e8200ea9b17 (patch)
tree958facb726a3966e56594b3d47b840c49400e883 /tools/utils.py
parentb632dc1aaf2efa4156b87b2d534cf6732010eaee (diff)
[tools] Add --cdb to make compile_commands.json.
Diffstat (limited to 'tools/utils.py')
-rw-r--r--tools/utils.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/utils.py b/tools/utils.py
index 7be58b9db9..d76720a850 100644
--- a/tools/utils.py
+++ b/tools/utils.py
@@ -303,3 +303,9 @@ def ImportModule(module):
return module
else:
return __import__(module, fromlist=[module])
+
+def VerTuple(version_str):
+ ver_parts = version_str.split('.')
+ ver = tuple(int(part) for part in ver_parts)
+
+ return ver