mirror of https://gitlab.com/ita1024/waf.git
Issue 1377
This commit is contained in:
parent
fb022f4787
commit
797b935305
|
@ -17,6 +17,8 @@ import sys, os
|
||||||
from waflib import Utils, Logs, Context, Options, Build, TaskGen, Scripting
|
from waflib import Utils, Logs, Context, Options, Build, TaskGen, Scripting
|
||||||
from xml.dom.minidom import Document
|
from xml.dom.minidom import Document
|
||||||
|
|
||||||
|
STANDARD_INCLUDES = [ '/usr/local/include', '/usr/include' ]
|
||||||
|
|
||||||
oe_cdt = 'org.eclipse.cdt'
|
oe_cdt = 'org.eclipse.cdt'
|
||||||
cdt_mk = oe_cdt + '.make.core'
|
cdt_mk = oe_cdt + '.make.core'
|
||||||
cdt_core = oe_cdt + '.core'
|
cdt_core = oe_cdt + '.core'
|
||||||
|
@ -49,6 +51,8 @@ class eclipse(Build.BuildContext):
|
||||||
"""
|
"""
|
||||||
source_dirs = []
|
source_dirs = []
|
||||||
cpppath = self.env['CPPPATH']
|
cpppath = self.env['CPPPATH']
|
||||||
|
if sys.platform != 'win32':
|
||||||
|
cpppath += STANDARD_INCLUDES
|
||||||
Logs.warn('Generating Eclipse CDT project files')
|
Logs.warn('Generating Eclipse CDT project files')
|
||||||
|
|
||||||
for g in self.groups:
|
for g in self.groups:
|
||||||
|
@ -212,6 +216,11 @@ class eclipse(Build.BuildContext):
|
||||||
self.add(doc, option, 'listOptionValue',
|
self.add(doc, option, 'listOptionValue',
|
||||||
{'builtIn': 'false',
|
{'builtIn': 'false',
|
||||||
'value': '"%s"'%(i)})
|
'value': '"%s"'%(i)})
|
||||||
|
if tool_name == "GNU C++" or tool_name == "GNU C":
|
||||||
|
self.add(doc,tool,'inputType',{ 'id':'org.eclipse.cdt.build.core.settings.holder.inType.1', \
|
||||||
|
'languageId':'org.eclipse.cdt.core.gcc','languageName':tool_name, \
|
||||||
|
'sourceContentType':'org.eclipse.cdt.core.cSource,org.eclipse.cdt.core.cHeader', \
|
||||||
|
'superClass':'org.eclipse.cdt.build.core.settings.holder.inType' })
|
||||||
if source_dirs:
|
if source_dirs:
|
||||||
sourceEntries = self.add(doc, config, 'sourceEntries')
|
sourceEntries = self.add(doc, config, 'sourceEntries')
|
||||||
for i in source_dirs:
|
for i in source_dirs:
|
||||||
|
|
Loading…
Reference in New Issue