From 4ee717e12b0a98c0763ac87e9fd27ad38a91b3f4 Mon Sep 17 00:00:00 2001 From: BVK Chaitanya Date: Tue, 6 Apr 2010 14:39:11 +0530 Subject: [PATCH] fix freebsd build --- conf/common.rmk | 2 +- configure.ac | 2 +- script/yylex.l | 6 ------ 3 files changed, 2 insertions(+), 8 deletions(-) diff --git a/conf/common.rmk b/conf/common.rmk index 87ae1e202..a83d10662 100644 --- a/conf/common.rmk +++ b/conf/common.rmk @@ -653,7 +653,7 @@ normal_mod_LDFLAGS = $(COMMON_LDFLAGS) # For sh.mod. sh_mod_SOURCES = script/main.c script/script.c script/execute.c \ script/function.c script/lexer.c grub_script.tab.c grub_script.yy.c -sh_mod_CFLAGS = $(COMMON_CFLAGS) $(POSIX_CFLAGS) +sh_mod_CFLAGS = $(COMMON_CFLAGS) $(POSIX_CFLAGS) -Wno-error sh_mod_LDFLAGS = $(COMMON_LDFLAGS) ifneq (, $(FONT_SOURCE)) diff --git a/configure.ac b/configure.ac index 1f55a9ca7..0af597bd3 100644 --- a/configure.ac +++ b/configure.ac @@ -192,7 +192,7 @@ AC_PROG_MKDIR_P if test "x$LEX" = x; then AC_MSG_ERROR([flex is not found]) else - version=`$LEX --version 2>/dev/null | $SED -e 's/flex //' | $AWK 'BEGIN { FS = "."; } { printf "%d", $1 * 10000 + $2 * 100 + $3;}'` + version=`$LEX --version 2>/dev/null | $SED -e 's/flex//' -e 's/version//' | $AWK -F "." '{ printf "%d", $1 * 10000 + $2 * 100 + $3;}'` if test -n "$version" -a "$version" -ge 20535; then : else diff --git a/script/yylex.l b/script/yylex.l index 4d7c66448..0cf33c951 100644 --- a/script/yylex.l +++ b/script/yylex.l @@ -86,12 +86,6 @@ typedef size_t yy_size_t; #define exit(...) #endif -#pragma GCC diagnostic warning "-Wunused-variable" -#pragma GCC diagnostic warning "-Wunused-function" -#pragma GCC diagnostic warning "-Wunused-parameter" -#pragma GCC diagnostic warning "-Wstrict-prototypes" -#pragma GCC diagnostic warning "-Wmissing-prototypes" - } %option ecs