[PATCH] gbuild conversion: cleaning up previously converted idlc module

David Ostrovsky david.ostrovsky at gmx.de
Mon Apr 30 15:34:58 PDT 2012


during gbuild'fication of idlc module I did a not so nice hack: as 
*_add_lexers helper function was not implemented,
I replaced dmake code with gbuild code in CustomTarget-Makefile.
I also forgot to remove the wrap_parser.cxx file.

This patch cleans it up and introduce *_add_lexers helper methods, like 
*_add_grammars and friends:

$(eval $(call gb_Executable_add_lexers,idlc,\
     idlc/source/scanner \

This patch is also a preparation for gbuild conversion of other modules.
Module l10ntools has three lexer files (this is C-code though):
echo $(find l10ntools -name *.l)
l10ntools/source/cfglex.l l10ntools/source/srclex.l 

Notes to the patch:

o striping is dropped: tr -d "\015" < $< > $@
    i don't know what is it for, on my ubuntu machnie there was no 
differences between the stripped and not stripped versions.

o because the wrapper_scanner.cxx file is not used any more (we use the 
generated scanner.cxx) I had to ignore -Wunused-function
    programmatically to be abled to compile the code with 
--enable-werror option:
FlexTarget/idlc/source/scanner.cxx:2395:17: error: 'void yyunput(int, 
char*)' defined but not used [-Werror=unused-function]

+#pragma GCC diagnostic ignored "-Wunused-function"


More information about the LibreOffice mailing list