diff --git a/bin/gbuild-to-ide b/bin/gbuild-to-ide index 366b808f6e93..0c6b2b6bd3a2 100755 --- a/bin/gbuild-to-ide +++ b/bin/gbuild-to-ide @@ -95,7 +95,7 @@ class GbuildParser: @staticmethod def __split_defs(defsline): defs = {} - alldefs = [defswitch.strip() for defswitch in defsline.strip().split(' -D') if len(defswitch) > 2] + alldefs = [defswitch.strip() for defswitch in defsline.strip().lstrip('-D').split(' -D') if len(defswitch) > 2] for d in alldefs: defparts = d.split('=') if len(defparts) == 1: