summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
Diffstat (limited to 'bin')
-rwxr-xr-xbin/gbuild-to-ide28
1 files changed, 16 insertions, 12 deletions
diff --git a/bin/gbuild-to-ide b/bin/gbuild-to-ide
index 4ad7d4b025ed..865a0b86f773 100755
--- a/bin/gbuild-to-ide
+++ b/bin/gbuild-to-ide
@@ -116,21 +116,25 @@ class GbuildParser:
libmatch = GbuildParser.libpattern.match(line)
if libmatch:
libname = self.libnames.get(state.ilib, None)
- self.libs.append(
- GbuildLib(libmatch.group(2), libname, libmatch.group(1),
- state.include, state.include_sys, state.defs, state.cxxobjects,
- state.cxxflags, state.linked_libs))
- state = GbuildParserState()
- return state
+ if libname != None:
+ print('add Library: %s' % libname, end='\n')
+ self.libs.append(
+ GbuildLib(libmatch.group(2), libname, libmatch.group(1),
+ state.include, state.include_sys, state.defs, state.cxxobjects,
+ state.cxxflags, state.linked_libs))
+ state = GbuildParserState()
+ return state
exematch = GbuildParser.exepattern.match(line)
if exematch:
exename = self.exenames.get(state.target, None)
- self.exes.append(
- GbuildExe(exematch.group(2), exename, exematch.group(1),
- state.include, state.include_sys, state.defs, state.cxxobjects,
- state.cxxflags, state.linked_libs))
- state = GbuildParserState()
- return state
+ if exename != None:
+ print('add Executable: %s' % exename, end='\n')
+ self.exes.append(
+ GbuildExe(exematch.group(2), exename, exematch.group(1),
+ state.include, state.include_sys, state.defs, state.cxxobjects,
+ state.cxxflags, state.linked_libs))
+ state = GbuildParserState()
+ return state
if line.find('# INCLUDE :=') == 0:
isystemmatch = GbuildParser.isystempattern.findall(line)
if isystemmatch: