Return-Path: From: Lucas De Marchi To: linux-bluetooth@vger.kernel.org Cc: Lucas De Marchi Subject: [PATCH BlueZ 2/2] build-sys: Don't use -Werror for generated lexer.c Date: Sun, 29 Jul 2012 03:30:35 -0300 Message-Id: <1343543435-8429-2-git-send-email-lucas.demarchi@profusion.mobi> In-Reply-To: <1343543435-8429-1-git-send-email-lucas.demarchi@profusion.mobi> References: <1343543435-8429-1-git-send-email-lucas.demarchi@profusion.mobi> Sender: linux-bluetooth-owner@vger.kernel.org List-ID: Source files that are generated by tools can't be compiled with -Werror because we can't really fix the issue in version of the tools that was already release and is used by distributions. After updating to flex 2.5.36 the following error occurs: tools/lexer.c:1599:17: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare] Override -Werror with -Wno-error for this specific file so warning is still emitted but we no longer fail the build. --- Makefile.tools | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/Makefile.tools b/Makefile.tools index 5579b86..1499bf7 100644 --- a/Makefile.tools +++ b/Makefile.tools @@ -14,11 +14,15 @@ noinst_PROGRAMS += tools/avinfo tools/ppporc \ tools/kword.c: tools/parser.h -tools_rfcomm_SOURCES = tools/rfcomm.c tools/parser.y tools/lexer.l \ - tools/kword.h tools/kword.c +noinst_LTLIBRARIES += tools/librfcomm-lexer.la +tools_librfcomm_lexer_la_SOURCES = tools/lexer.l +tools_librfcomm_lexer_la_CFLAGS = $(AM_CFLAGS) -Wno-error + +tools_rfcomm_SOURCES = tools/rfcomm.c tools/parser.y tools/kword.h \ + tools/kword.c EXTRA_tools_rfcomm_SOURCES = tools/parser.h tools/parser.c \ tools/lexer.c -tools_rfcomm_LDADD = lib/libbluetooth-private.la +tools_rfcomm_LDADD = lib/libbluetooth-private.la tools/librfcomm-lexer.la tools_l2ping_LDADD = lib/libbluetooth-private.la -- 1.7.11.3