summaryrefslogtreecommitdiffstats
path: root/source-builder
diff options
context:
space:
mode:
authorRicardo Cárdenes <rcardenes@gemini.edu>2021-03-10 21:32:08 -1000
committerVijay Kumar Banerjee <vijay@rtems.org>2021-03-11 08:52:27 -0700
commit5e449fb5c2cb6812a238f9f9764fd339cbbf05c2 (patch)
tree7e4ddbe8616a04e0b3253305817695533a39dd16 /source-builder
parentAdd recipe for building rtems-net-legacy (diff)
downloadrtems-source-builder-5e449fb5c2cb6812a238f9f9764fd339cbbf05c2.tar.bz2
sb/config.py: Fix operator reconstruction
Close #4335
Diffstat (limited to 'source-builder')
-rw-r--r--source-builder/sb/config.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/source-builder/sb/config.py b/source-builder/sb/config.py
index d3ba6cd..5bc96e2 100644
--- a/source-builder/sb/config.py
+++ b/source-builder/sb/config.py
@@ -991,9 +991,9 @@ class file:
else:
if len(ifls) >= 3:
for op in ['==', '!=', '>=', '=>', '=<', '<=', '>', '<']:
- ops = s.split(op)
- if len(ops) == 2:
- ifls = (ops[0], op, ops[1])
+ if op in ifls:
+ op_pos = ifls.index(op)
+ ifls = (' '.join(ifls[:op_pos]), op, ' '.join(ifls[op_pos + 1:]))
break
if len(ifls) != 3:
self._error('malformed if: ' + reduce(add, ls, ''))