gbuildtojson, added support for lex files

added add_scanner macro

Finalized the move around in gbuild-to-ide, to signal
which generators are actively supported.

Change-Id: I11699cd4380d49efc3b541abb7780b5136162433
This commit is contained in:
jan Iversen 2017-01-26 14:24:03 +01:00
parent 8af9286632
commit 1fb65a66f1
2 changed files with 28 additions and 13 deletions

View File

@ -76,19 +76,31 @@ class GbuildParser:
def parse(self): def parse(self):
# current json blacklist, this is just for reference:
# bridges
# connectivity compilerplugins cli_ure cppu cppuhelper cpputools
# dictionaries
# extensions external
# helpcompiler helpcontent2
# i18npool icon-themes
# javaunohelper jurt
# lingucomponent
# odk
# sal scaddins shell solenv stoc
# tools translations
# udkapi unoid
# Add handling of BLACKLIST
# Relation between json object and file extension # Relation between json object and file extension
jsonSrc = { jsonSrc = {
'CXXOBJECTS': '.cxx', 'CXXOBJECTS': '.cxx', 'OBJCOBJECTS': '.m', 'OBJCXXOBJECTS': '.mm', 'COBJECTS': '.c',
'GENCXXOBJECTS': '.cxx', # remark is in workdir/GenCxxObject 'GENCXXOBJECTS': '.cxx', # remark is in workdir/GenCxxObject
'OBJCOBJECTS': '.m', 'ASMOBJECTS': '.s', #not in json, due to Blacklist ?
'OBJCXXOBJECTS': '.mm', 'YACCOBJECTS': '.y', #not in json, due to Blacklist ?
'ASMOBJECTS': '.s', 'GENCOBJECTS': '.c', #not in json, due to Blacklist ?
'YACCOBJECTS': '.y', 'LEXOBJECTS': '.l', #not in json, due to add_scanners
'GENCOBJECTS': '.c', 'JAVAOBJECTS': '.java', #not in json, due to Blacklist ?
'COBJECTS': '.c', 'PYTHONOBJECTS': '.py' #not in json, due to Blacklist ?
'FLEXOBJECTS': '.l',
'JAVAOBJECTS': '.java',
'PYTHONOBJECTS': '.py'
} }

View File

@ -14,7 +14,7 @@
# --ASMOBJECTS # --ASMOBJECTS
# --GENCOBJECTS # --GENCOBJECTS
# --YACCOBJECTS # --YACCOBJECTS
# --FLEXOBJECTS # --LEXOBJECTS
# --JAVAOBJECTS # --JAVAOBJECTS
# --PYTHONOBJECTS # --PYTHONOBJECTS
# #
@ -56,10 +56,10 @@ $(call gb_Executable_get_command,gbuildtojson) \
--objcobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(OBJCOBJECTS)) \ --objcobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(OBJCOBJECTS)) \
--objcxxobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(OBJCXXOBJECTS)) \ --objcxxobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(OBJCXXOBJECTS)) \
--asmobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(ASMOBJECTS)) \ --asmobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(ASMOBJECTS)) \
--lexobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(LEXOBJECTS)) \
--gencobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(GENCOBJECTS)) \ --gencobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(GENCOBJECTS)) \
--gencxxobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(GENCXXOBJECTS)) \ --gencxxobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(GENCXXOBJECTS)) \
--cobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(COBJECTS)) \ --cobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(COBJECTS)) \
--flexobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(FLEXOBJECTS)) \
--javaobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(JAVAOBJECTS)) \ --javaobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(JAVAOBJECTS)) \
--pythonobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(PYTHONOBJECTS)) \ --pythonobjects=$(call var2file,$(shell $(gb_MKTEMP)),100,$(PYTHONOBJECTS)) \
--cflags=$(call var2file,$(shell $(gb_MKTEMP)),100,$(T_CFLAGS)) \ --cflags=$(call var2file,$(shell $(gb_MKTEMP)),100,$(T_CFLAGS)) \
@ -118,12 +118,15 @@ endef
define gb_LinkTarget_add_objcxxobject define gb_LinkTarget_add_objcxxobject
$(call gb_LinkTarget_get_target,$(1)) : OBJCXXOBJECTS += $(2) $(call gb_LinkTarget_get_target,$(1)) : OBJCXXOBJECTS += $(2)
endef
define gb_LinkTarget_add_scanners
$(call gb_LinkTarget_get_target,$(1)) : LEXOBJECTS += $(2)
endef endef
gb_LinkTarget_use_package = gb_LinkTarget_use_package =
gb_LinkTarget_use_generated_package = gb_LinkTarget_use_generated_package =
gb_LinkTarget_add_sdi_headers = gb_LinkTarget_add_sdi_headers =
gb_LinkTarget_use_external_project = gb_LinkTarget_use_external_project =
gb_LinkTarget_add_scanners =
gb_LinkTarget_add_grammars = gb_LinkTarget_add_grammars =
gb_LinkTarget__check_srcdir_paths = gb_LinkTarget__check_srcdir_paths =
gb_LinkTarget__command_objectlist = @true gb_LinkTarget__command_objectlist = @true