From: Marc Dionne Date: Fri, 20 Aug 2010 21:42:47 +0000 (-0400) Subject: Ignore old style definition warnings in generated code X-Git-Tag: openafs-devel-1_5_77~43 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=763d3c9bdc2eea8b94122e2b8a64fee0b84d89a0;p=packages%2Fo%2Fopenafs.git Ignore old style definition warnings in generated code Older flex can generate functions that trigger the "old-style-definition" warning. Since it's generated code, just ignore it. Change-Id: If475507561498b976a2942bd0084975814ab6a76 Reviewed-on: http://gerrit.openafs.org/2603 Tested-by: BuildBot Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear (cherry picked from commit 850567f17285021d3133a75c1d0d3494e0faabfc) Reviewed-on: http://gerrit.openafs.org/2670 --- diff --git a/src/cf/osconf.m4 b/src/cf/osconf.m4 index a4634daa1..402050880 100644 --- a/src/cf/osconf.m4 +++ b/src/cf/osconf.m4 @@ -1074,6 +1074,12 @@ else CFLAGS_NOUNUSED= fi +if test "x$GCC" = "xyes"; then + CFLAGS_NOOLDSTYLE="-Wno-old-style-definition" +else + CFLAGS_NOOLDSTYLE= +fi + dnl horribly cheating, assuming double / is ok. case $INSTALL in ./* ) @@ -1126,6 +1132,7 @@ AC_SUBST(XCFLAGS) AC_SUBST(CFLAGS_NOERROR) AC_SUBST(CFLAGS_NOSTRICT) AC_SUBST(CFLAGS_NOUNUSED) +AC_SUBST(CFLAGS_NOOLDSTYLE) AC_SUBST(XCFLAGS64) AC_SUBST(XLDFLAGS) AC_SUBST(XLDFLAGS64) diff --git a/src/comerr/Makefile.in b/src/comerr/Makefile.in index 806332d81..a22742d4c 100644 --- a/src/comerr/Makefile.in +++ b/src/comerr/Makefile.in @@ -49,7 +49,7 @@ libcom_err.a: error_msg.o et_name.o com_err.o AFS_component_version_number.o # so we need to add the source directory to the includes to pick up local headers. # error_table.o: error_table.c - $(CC) $(CFLAGS) -I${srcdir} @CFLAGS_NOUNUSED@ -c error_table.c + $(CC) $(CFLAGS) -I${srcdir} @CFLAGS_NOUNUSED@ @CFLAGS_NOOLDSTYLE@ -c error_table.c # # Installation targets