From 6d51ebd6c8d4d5d6ddc42b539be5814e7c468d9c Mon Sep 17 00:00:00 2001 From: Simon Wilkinson Date: Mon, 28 Sep 2009 12:07:58 +0200 Subject: [PATCH] Add support for warning checked builds This patch adds a '--enable-checking' configuration option. When this option is supplied, and gcc is in use, the compiler will treat any warnings as errors. This will hopefully help stop new warnings from creeping into the tree. In order to still be able to build, all of the currently existing warnings are accepted (these are documented in README.WARNINGS). With this set of warning inhibitions, the tree is known to build on 32bit Leopard - other systems may vary. Warning inhibition may be disabled by supplying --enable-checking=all - in this case the tree will definitely not build! If --enabled-checking is not specified, the existing compilation behaviour is maintained, so there is no user-visible change. Gcc 4.2, or later, is required to use the pragma sets contained within this patch. Again, they are not visible unless --enable-checking is given. Reviewed-on: http://gerrit.openafs.org/526 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear --- README.WARNINGS | 104 +++++++++++++++++++++++++++ acinclude.m4 | 6 ++ src/afs/afs_syscall.c | 4 ++ src/afsd/Makefile.in | 3 +- src/afsd/afsd.c | 3 + src/auth/Makefile.in | 1 + src/bozo/Makefile.in | 3 + src/bozo/bosserver.c | 3 + src/bubasics/Makefile.in | 3 + src/bucoord/Makefile.in | 15 ++++ src/bucoord/ubik_db_if.c | 3 + src/budb/Makefile.in | 4 ++ src/butc/Makefile.in | 5 ++ src/cf/osconf.m4 | 14 +++- src/comerr/Makefile.in | 8 +++ src/config/Makefile.config.in | 2 +- src/fsint/Makefile.in | 7 ++ src/fsprobe/Makefile.in | 1 + src/kauth/Makefile.in | 14 +++- src/libadmin/bos/Makefile.in | 5 +- src/libadmin/kas/Makefile.in | 3 +- src/libadmin/samples/Makefile.in | 9 +++ src/libadmin/samples/rxdebug_peers.c | 4 ++ src/libadmin/test/Makefile.in | 3 + src/libadmin/vos/Makefile.in | 2 +- src/libafsauthent/Makefile.in | 2 +- src/libafsrpc/Makefile.in | 10 +-- src/libuafs/Makefile.common.in | 38 +++++----- src/ptserver/Makefile.in | 1 + src/rxkad/Makefile.in | 5 +- src/tviced/Makefile.in | 8 +-- src/ubik/Makefile.in | 7 ++ src/ubik/ubikclient.c | 3 + src/uss/Makefile.in | 6 +- src/viced/Makefile.in | 2 +- src/vlserver/Makefile.in | 2 + src/vol/Makefile.in | 3 + src/volser/Makefile.in | 6 ++ src/volser/vol-dump.c | 3 + src/volser/vsprocs.c | 3 + 40 files changed, 285 insertions(+), 43 deletions(-) create mode 100644 README.WARNINGS diff --git a/README.WARNINGS b/README.WARNINGS new file mode 100644 index 000000000..6dd52eda8 --- /dev/null +++ b/README.WARNINGS @@ -0,0 +1,104 @@ +OpenAFS Warning detection +------------------------- + +There's been a concerted effort over the last few years, by many developers, +to reduce the number of warnings in the OpenAFS tree. In an attempt to +prevent warnings from creeping back in, we now have the ability to break the +build when new warnings appear. + +This is only available for systems with gcc 4.2 or later, and is disabled +unless the --enable-checking option is supplied to configure. Because we +can't remove all of the warnings, we permit file by file (and warning by +warning) disabling of specific warnings. The --enable-checking=all prevents +this, and errors for any file containing a warning. + +Disabling warnings +------------------ + +If warnings are unavoidable in a particular part of the build, they may be +disabled in an number of ways. + +You can disable a single warning type in a particular file by using GCC +pragmas. If a warning can be disabled with a pragma, then the switch to use +will be listed in the error message you receive from the compiler. Pragmas +should be wrapped in IGNORE_SOME_GCC_WARNINGS, so that they aren't used +with non-gcc compilers, and can be disabled if desired. For example: + #ifdef IGNORE_SOME_GCC_WARNINGS + # pragma GCC diagnostic warning "-Wold-style-definition" + #endif + +If a pragma isn't available for your particular warning, you will need to +disable all warnings for the file in question. You can do this by supplying +the autoconf macro @CFLAGS_NOERROR@ in the build options for the file. For +example: + lex.yy.o : lex.yy.c y.tab.c + ${CC} -c ${CFLAGS} @CFLAGS_NOERROR@ lex.yy.c + +If you add a new warning inhibition, please also add it to the list below. + +Inhibited warnings +------------------ + +afs/afs_syscall.c : old-style + : strict-proto + : all (ukernel) : syscall pointer issues +afsd/afsd.c : deprecated : daemon() marked as deprecated on Darwin + : all : call_syscall missing prototype +auth/ktc.c : all (ukernel) : call_syscall doesn't have a prototype +bozo/bosserver.c : deprecated : daemon() marked as deprecated on Darwin +bozo/bosoprocs.c : all : ExtendedCellInfo and des key types +bozo/bos.c : all : DES key types & string consts +bozo/bos_util.c : all : DES key types +bubasics/bumon.ss.c : all : BC_Print collision betwen client & server +bucoord/ubik_db_if.c : strict-proto : Ubik_Call + : all : Public version of volser_prototypes req +bucoord/volstub.c : all : Public version of volser_prototypes req +bucoord/commands.c : all : Ubik_Call + : signed vs unsigned for dates +budb/server.c : all : ExtendedCellInfo +butc/lwps.c : all : Public version of volser_prototypes req +butc/tcmain.c : all : prototypes / signed warnings (XXX) +butc/recoverDb.c : all : pointer target issues (XXX) +butc/tcudbprocs.c : all : ubik_Call +butc/dump.c : all : pointer types (XXX) +comerr/error_table.c : all : Autogenerated file with unused labels +fsint/afsint.xdr.c : all : rxgen opaque vectors problem +fsprobe/fsprobe.c : all : Public version of volser_prototypes req +kauth/kaprocs.c : all : XXX +kauth/kaserver.c : all : ExtendedCellInfo +kauth/krb_udp.c : all : XXX +kauth/admin_tools.c : all : ubik_Call nonsense +kauth/authclient.c : all : ubik_Call nonsense +kauth/kas.c : all : XXX +kauth/klog.c : all : XXX +kauth/ka-forwarder.c : all : XXX +libadmin/bos/afs_bosAdmin.c: all : DES keys, time types, and const +libadmin/kas/afs_kasAdmin.c: all : Ubik_Call nonsense, DES keys +libadmin/samples/rxstat_query_peer.c : all : util_RPCStatsStateGet types +libadmin/samples/rxstat_query_process.c : all : util_RPCStatsStateGet types +libadmin/samples/rxdebug_peers.c : format : struct clock vs unsigned int +libadmin/test/client.c : all : util_RPCStatsStateGet types +ptserver/ptserver.c : all : ExtendedCellInfo +rxkad/rxkad_server.c : all : Des key nonsense +rxkad/ticket.c : all : Des key nonsense +rxkad/ticket5.c : all : Des key nonsense +rxkad/v5der.c : all (pthread) : Des key nonsense +rx/rx.c : all (pthread) : rxkad_global_stats_init not proto'd +rx/xdr_rx.c : all (ukernel) : Prototypes don't match due to AFS_XDR_T + not being used in the xdr header +ubik/utst_int_ss.c : all : Client / Server symbol collisions +ubik/beacon.c : all : Ubik uses signed/unsigned + interchangably for IP addresses, a + fix will require API changes. +ubik/ubikclient.c : strict-protos : ubik_Call +uss/uss_vol.c : all : Public version of volser_prototypes req + Format issues +uss/uss_kauth.c : all : Des keys, ubik_Call +uss/lex.yy.c : all : Unused symbols +viced/fsprobe.c : all : ubik_Call +vlserver/vlserver.c : all : GetExtendedCellInfo +vol/salvager.c : all : consts & undefined variable from header +volser/vos.c : all : ubik_Call_New, signedness and const +volser/vol-dump.c : format : afs_sfsize_t +volser/vsprocs.c : format-extra : The ONERROR macro needs to be rethought + diff --git a/acinclude.m4 b/acinclude.m4 index 0b797814e..973826ef3 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -252,6 +252,12 @@ AC_ARG_ENABLE([warnings], disabled)])], , [enable_warnings="no"]) +AC_ARG_ENABLE([checking], + [AS_HELP_STRING([--enable-checking], + [turn compilation warnings into errors when building with gcc (defaults + to disabled)])], + [enable_checking="$enableval"], + [enable_checking="no"]) AC_ARG_ENABLE([debug-kernel], [AS_HELP_STRING([--enable-debug-kernel], [enable compilation of the kernel module with debugging information diff --git a/src/afs/afs_syscall.c b/src/afs/afs_syscall.c index 5557ed75b..52c2b475f 100644 --- a/src/afs/afs_syscall.c +++ b/src/afs/afs_syscall.c @@ -10,6 +10,10 @@ #include #include "afs/param.h" +#ifdef IGNORE_SOME_GCC_WARNINGS +# pragma GCC diagnostic warning "-Wold-style-definition" +# pragma GCC diagnostic warning "-Wstrict-prototypes" +#endif #include "afs/sysincludes.h" /* Standard vendor system headers */ #include "afsincludes.h" /* Afs-based standard headers */ diff --git a/src/afsd/Makefile.in b/src/afsd/Makefile.in index cdb488aec..bf600006f 100644 --- a/src/afsd/Makefile.in +++ b/src/afsd/Makefile.in @@ -27,7 +27,7 @@ all: afsd vsys AFSLIBS=${TOP_LIBDIR}/libauth.a ${TOP_LIBDIR}/libcmd.a ${TOP_LIBDIR}/libsys.a ${TOP_LIBDIR}/util.a ${TOP_LIBDIR}/librx.a ${TOP_LIBDIR}/liblwp.a ${TOP_LIBDIR}/util.a afsd: afsd.o $(AFSLIBS) $(AFSD_LIBS) - ${CC} ${CFLAGS} -o afsd afsd.o $(NON_SHARED) $(LDFLAGS) $(AFSD_LDFLAGS) $(AFSLIBS) ${XLIBS} ${AFSD_LIBS} + ${CC} ${CFLAGS} -o afsd afsd.o @CFLAGS_NOERROR@ $(NON_SHARED) $(LDFLAGS) $(AFSD_LDFLAGS) $(AFSLIBS) ${XLIBS} ${AFSD_LIBS} vsys: vsys.o ${CC} ${CFLAGS} -o vsys vsys.o ${TOP_LIBDIR}/libsys.a $(LDFLAGS) ${XLIBS} @@ -36,6 +36,7 @@ vsys: vsys.o # Objects # afsd.o: afsd.c AFS_component_version_number.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< vsys.o: vsys.c AFS_component_version_number.c diff --git a/src/afsd/afsd.c b/src/afsd/afsd.c index 5fbdf8d6e..34d83cdb3 100644 --- a/src/afsd/afsd.c +++ b/src/afsd/afsd.c @@ -61,6 +61,9 @@ #include #include +#ifdef IGNORE_SOME_GCC_WARNINGS +# pragma GCC diagnostic warning "-Wdeprecated-declarations" +#endif #define VFS 1 diff --git a/src/auth/Makefile.in b/src/auth/Makefile.in index 9d488cdd3..58f6dd43d 100644 --- a/src/auth/Makefile.in +++ b/src/auth/Makefile.in @@ -7,6 +7,7 @@ srcdir=@srcdir@ include @TOP_OBJDIR@/src/config/Makefile.config + INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ diff --git a/src/bozo/Makefile.in b/src/bozo/Makefile.in index d148c6b86..71767ad46 100644 --- a/src/bozo/Makefile.in +++ b/src/bozo/Makefile.in @@ -89,13 +89,16 @@ cronbnodeops.o: cronbnodeops.c ${INCLS} bnode.o: bnode.c ${INCLS} bosoprocs.o: bosoprocs.c ${INCLS} + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< bos.o: bos.c ${INCLS} AFS_component_version_number.o + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< bos: bos.o $(LIBS) libbos.a ${CC} ${CFLAGS} -o bos bos.o libbos.a $(LIBS) ${XLIBS} bos_util.o: bos_util.c ${INCLS} AFS_component_version_number.o ${TOP_INCDIR}/afs/bnode.h + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< bos_util: bos_util.o $(LIBS) ${CC} ${CFLAGS} -o bos_util bos_util.o $(LIBS) ${XLIBS} diff --git a/src/bozo/bosserver.c b/src/bozo/bosserver.c index 4c5159e46..f6c41bea6 100644 --- a/src/bozo/bosserver.c +++ b/src/bozo/bosserver.c @@ -10,6 +10,9 @@ #include #include +#ifdef IGNORE_SOME_GCC_WARNINGS +# pragma GCC diagnostic warning "-Wdeprecated-declarations" +#endif #include #include diff --git a/src/bubasics/Makefile.in b/src/bubasics/Makefile.in index ab0444f13..e4d21ed51 100644 --- a/src/bubasics/Makefile.in +++ b/src/bubasics/Makefile.in @@ -93,6 +93,9 @@ butx_errs.c: butx_errs.et $(RM) -f butx.h butx_errs.c ${COMPILE_ET} -p ${srcdir} butx_errs -h butx +bumon.ss.o: bumon.ss.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + # # Installation targets # diff --git a/src/bucoord/Makefile.in b/src/bucoord/Makefile.in index 58561eead..ad000c971 100644 --- a/src/bucoord/Makefile.in +++ b/src/bucoord/Makefile.in @@ -68,6 +68,21 @@ bucoord_errs.c bc.h: bucoord_errs.et bc.p.h $(RM) -f bc.h bucoord_errs.c ${COMPILE_ET} -p ${srcdir} bucoord_errs -h bc +# +# Errors +# +ubik_db_if.o: ubik_db_if.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + +volstub.o: volstub.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + +commands.o: commands.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + +regex.o: regex.c + $(CC) $(CFLAGS) -c $< + # # Install targets # diff --git a/src/bucoord/ubik_db_if.c b/src/bucoord/ubik_db_if.c index 655c642ae..0338c2cbe 100644 --- a/src/bucoord/ubik_db_if.c +++ b/src/bucoord/ubik_db_if.c @@ -12,6 +12,9 @@ #include #include +#ifdef IGNORE_SOME_GCC_WARNINGS +# pragma GCC diagnostic warning "-Wstrict-prototypes" +#endif #include #include diff --git a/src/budb/Makefile.in b/src/budb/Makefile.in index 961161652..caf3f9677 100644 --- a/src/budb/Makefile.in +++ b/src/budb/Makefile.in @@ -115,6 +115,10 @@ libbudb.a: budb_errs.o budb.cs.o budb.xdr.o struct_ops.o AFS_component_version_n $(AR) crv $@ budb_errs.o budb.cs.o budb.xdr.o struct_ops.o AFS_component_version_number.o $(RANLIB) $@ +# Errors +server.o: server.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + # # Install targets # diff --git a/src/butc/Makefile.in b/src/butc/Makefile.in index 82f17d33d..bb0f44d4e 100644 --- a/src/butc/Makefile.in +++ b/src/butc/Makefile.in @@ -68,14 +68,19 @@ butc: ${SOBJS} ${LIBS} ${INCLS} ${HACKS} esac tcmain.o: tcmain.c ${INCLS} AFS_component_version_number.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< dbentries.o: dbentries.c ${INCLS} tcprocs.o: tcprocs.c ${INCLS} test.o: test.c ${INCLS} AFS_component_version_number.c lwps.o: lwps.c ${INCLS} + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< list.o: list.c ${INCLS} recoverDb.o: recoverDb.c ${INCLS} + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< tcudbprocs.o: tcudbprocs.c ${INCLS} + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< dump.o: dump.c ${INCLS} + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< tcstatus.o: tcstatus.c ${INCLS} read_tape: read_tape.c diff --git a/src/cf/osconf.m4 b/src/cf/osconf.m4 index 0947a218b..02e9699e6 100644 --- a/src/cf/osconf.m4 +++ b/src/cf/osconf.m4 @@ -1180,10 +1180,19 @@ else NO_STRIP_BIN= fi -if test "x$enable_warnings" = "xyes"; then - if test "x$GCC" = "xyes"; then +CFLAGS_NOERROR= + +if test "x$GCC" = "xyes"; then + if test "x$enable_warnings" = "xyes"; then XCFLAGS="${XCFLAGS} -Wall -Wstrict-prototypes -Wold-style-definition" fi + if test "x$enable_checking" != "xno"; then + XCFLAGS="${XCFLAGS} -Wall -Wstrict-prototypes -Wold-style-definition -Werror -fdiagnostics-show-option" + if test "x$enable_checking" != "xall"; then + CFLAGS_NOERROR="-Wno-error" + AC_DEFINE(IGNORE_SOME_GCC_WARNINGS, 1, [define to disable some gcc warnings in warnings-as-errors mode]) + fi + fi fi dnl horribly cheating, assuming double / is ok. @@ -1235,6 +1244,7 @@ AC_SUBST(SHLIB_SUFFIX) AC_SUBST(TXLIBS) AC_SUBST(VFSCK_CFLAGS) AC_SUBST(XCFLAGS) +AC_SUBST(CFLAGS_NOERROR) AC_SUBST(XCFLAGS64) AC_SUBST(XLDFLAGS) AC_SUBST(XLDFLAGS64) diff --git a/src/comerr/Makefile.in b/src/comerr/Makefile.in index 1159918e0..e43ea5d7d 100644 --- a/src/comerr/Makefile.in +++ b/src/comerr/Makefile.in @@ -42,6 +42,14 @@ libcom_err.a: error_msg.o et_name.o com_err.o AFS_component_version_number.o $(AR) crv $@ error_msg.o et_name.o com_err.o AFS_component_version_number.o $(RANLIB) $@ +# +# Files with errors +# +# The autogenerated file from bison has an unused label + +error_table.o: error_table.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + # # Installation targets # diff --git a/src/config/Makefile.config.in b/src/config/Makefile.config.in index 792ea4481..aafd46a74 100644 --- a/src/config/Makefile.config.in +++ b/src/config/Makefile.config.in @@ -126,7 +126,7 @@ SHELL = /bin/sh COMMON_INCL=-I${TOP_OBJDIR}/src/config -I. -I${srcdir} -I${TOP_INCDIR} -I${TOP_INCDIR}/afs -I${TOP_INCDIR}/rx -I${TOP_OBJDIR} -I${TOP_SRCDIR} -I${TOP_OBJDIR}/src COMMON_CFLAGS=${DBG} ${OPTMZ} ${COMMON_INCL} -CFLAGS=${COMMON_CFLAGS} ${XCFLAGS} ${ARCHFLAGS} +CFLAGS=${COMMON_CFLAGS} ${XCFLAGS} ${ARCHFLAGS} $(CFLAGS_NOERROR) LDFLAGS=${XLDFLAGS} ${ARCHFLAGS} .c.o: diff --git a/src/fsint/Makefile.in b/src/fsint/Makefile.in index 587a7e02c..fa1c197d6 100644 --- a/src/fsint/Makefile.in +++ b/src/fsint/Makefile.in @@ -107,6 +107,13 @@ afsint.h: common.xg afsint.xg afscbint.h: common.xg afscbint.xg ${RXGEN} -A -x -h -o afscbint.h ${srcdir}/afscbint.xg +# Files with warnings +# rpcgen currently handles opaque vectors badly +# - it relies on char a[1]; &a == a; which leads to type errors + +afsint.xdr.o: afsint.xdr.c + $(CC) $(CFLAGS) -c @CFLAGS_NOERROR@ $< + # # Installation targets # diff --git a/src/fsprobe/Makefile.in b/src/fsprobe/Makefile.in index c9e6bd4c9..0550f5c3b 100644 --- a/src/fsprobe/Makefile.in +++ b/src/fsprobe/Makefile.in @@ -46,6 +46,7 @@ libfsprobe.a: fsprobe.o fsprobe_callback.o AFS_component_version_number.o $(RANLIB) $@ fsprobe.o: fsprobe.c ${INCLS} AFS_component_version_number.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< fsprobe_callback.o: fsprobe_callback.c ${INCLS} diff --git a/src/kauth/Makefile.in b/src/kauth/Makefile.in index 8f98dc4b9..7b81fba9c 100644 --- a/src/kauth/Makefile.in +++ b/src/kauth/Makefile.in @@ -88,6 +88,7 @@ kaserver: kautils.o kalocalcell.o kadatabase.o kaprocs.o kalog.o kauth.ss.o kaut ${CC} ${LDFLAGS} -o kaserver kaserver.o kautils.o kalocalcell.o kadatabase.o krb_udp.o kaprocs.o kalog.o kauth.ss.o kauth.xdr.o kaaux.o kaauxdb.o $(LIBS) ${XLIBS} ${TOP_LIBDIR}/libaudit.a kaserver.o: kaserver.c ${INCLS} AFS_component_version_number.o + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< kautils.o: kautils.c ${INCLS} @@ -97,9 +98,13 @@ kadatabase.o: kadatabase.c ${INCLS} ${CC} ${CFLAGS} -c ${srcdir}/kadatabase.c kaprocs.o: kaprocs.c ${INCLS} kaport.h - ${CC} ${CFLAGS} -c ${srcdir}/kaprocs.c + ${CC} ${CFLAGS} @CFLAGS_NOERROR@ -c $< authclient.o: authclient.c ${INCLS} + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + +kaauxdb.o: kaauxdb.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< kaerrors.o: kaerrors.c @@ -158,8 +163,10 @@ token.o: token.c ${INCLS} client.o: client.c ${INCLS} AFS_component_version_number.o kas.o: kas.c ${INCLS} AFS_component_version_number.o + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< admin_tools.o: admin_tools.c ${INCLS} kaport.h + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< kkids.o: kkids.c ${INCLS} @@ -174,6 +181,7 @@ klog: AFS_component_version_number.o kauth.h kautils.h libkauth.a $(LIBS) \ ${CC} ${LDFLAGS} -o klog klog.o libkauth.a ${LIBS} ${XLIBS} klog.o: klog.c kauth.h kautils.h AFS_component_version_number.o + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< klog.krb: kauth.h kautils.h libkauth.krb.a $(KLIBS) klog.o ${CC} ${LDFLAGS} -o klog.krb klog.o libkauth.krb.a ${KLIBS} ${XLIBS} @@ -216,10 +224,14 @@ kdb: kdb.o ${INCLS} ${LIBS} libkauth.a kdb.o: kdb.c AFS_component_version_number.o krb_udp.o: krb_udp.c kaserver.h kautils.h kauth.h prot.h ${TOP_INCDIR}/lwp.h AFS_component_version_number.o + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< krb_udp: krb_udp.o libkauth.a $(KLIBS) ${CC} ${LDFLAGS} -o krb_udp krb_udp.o libkauth.a $(KLIBS) +ka-forwarder.o: ka-forwarder.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + ka-forwarder: ka-forwarder.o ${CC} -o $@ ${CFLAGS} ka-forwarder.o ${LIBS} ${XLIBS} diff --git a/src/libadmin/bos/Makefile.in b/src/libadmin/bos/Makefile.in index 850603f7e..2efb27dea 100644 --- a/src/libadmin/bos/Makefile.in +++ b/src/libadmin/bos/Makefile.in @@ -13,7 +13,7 @@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ CC = ${MT_CC} -CFLAGS=${COMMON_CFLAGS} ${MT_CFLAGS} +CFLAGS=${COMMON_CFLAGS} ${MT_CFLAGS} ${CFLAGS_NOERROR} CCRULE = ${CC} ${CFLAGS} -c $? BOZO = ../../bozo @@ -49,7 +49,8 @@ libbosadmin.a: ${LIBOBJS} $(AR) crv $@ ${LIBOBJS} ${RANLIB} $@ -afs_bosAdmin.o: afs_bosAdmin.h +afs_bosAdmin.o: afs_bosAdmin.c afs_bosAdmin.h + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< bosint.xdr.o: ${BOZO}/bosint.xdr.c ${CCRULE} diff --git a/src/libadmin/kas/Makefile.in b/src/libadmin/kas/Makefile.in index bd438aa3e..2a0f2e43d 100644 --- a/src/libadmin/kas/Makefile.in +++ b/src/libadmin/kas/Makefile.in @@ -52,7 +52,8 @@ libkasadmin.a: ${LIBOBJS} $(AR) crv $@ ${LIBOBJS} ${RANLIB} $@ -afs_kasAdmin.o: afs_kasAdmin.h +afs_kasAdmin.o: afs_kasAdmin.c afs_kasAdmin.h + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< kauth.cs.o: ../../kauth/kauth.cs.c ${CCRULE} diff --git a/src/libadmin/samples/Makefile.in b/src/libadmin/samples/Makefile.in index 93d1174ee..5da0cef49 100644 --- a/src/libadmin/samples/Makefile.in +++ b/src/libadmin/samples/Makefile.in @@ -110,6 +110,15 @@ rxstat_query_peer: rxstat_query_peer.o $(SAMPLELIBS) rxstat_query_process: rxstat_query_process.o $(SAMPLELIBS) $(CC) $(LDFLAGS) -o $@ $@.o $(SAMPLELIBS) $(MT_LIBS) $(XLIBS) +# +# Errors +# +rxstat_query_peer.o: rxstat_query_peer.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + +rxstat_query_process.o: rxstat_query_process.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + ####################################################################### all test tests: $(SAMPLEPROGS) diff --git a/src/libadmin/samples/rxdebug_peers.c b/src/libadmin/samples/rxdebug_peers.c index 0b189755d..16e3d2c38 100644 --- a/src/libadmin/samples/rxdebug_peers.c +++ b/src/libadmin/samples/rxdebug_peers.c @@ -16,6 +16,10 @@ #include #include +#ifdef IGNORE_SOME_GCC_WARNINGS + # pragma GCC diagnostic warning "-Wformat" +#endif + #ifdef AFS_NT40_ENV #include diff --git a/src/libadmin/test/Makefile.in b/src/libadmin/test/Makefile.in index 0cd0345e3..79b450217 100644 --- a/src/libadmin/test/Makefile.in +++ b/src/libadmin/test/Makefile.in @@ -38,6 +38,9 @@ AFSCPOBJS =\ util.o \ vos.o +client.o: client.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + afscp: afscp.o $(AFSCPOBJS) $(AFSCPLIBS) $(CC) $(CFLAGS) -o afscp afscp.o $(AFSCPOBJS) \ -L${TOP_LIBDIR} $(AFSCPLIBS) ${MT_LIBS} $(XLIBS) diff --git a/src/libadmin/vos/Makefile.in b/src/libadmin/vos/Makefile.in index 321aa38e9..b42a99c4d 100644 --- a/src/libadmin/vos/Makefile.in +++ b/src/libadmin/vos/Makefile.in @@ -85,7 +85,7 @@ afscbint.xdr.o: ${FSINT}/afscbint.xdr.c ${CCRULE} afsint.xdr.o: ${FSINT}/afsint.xdr.c - ${CCRULE} + ${CCRULE} @CFLAGS_NOERROR@ clean: $(RM) -f *.o libvosadmin* diff --git a/src/libafsauthent/Makefile.in b/src/libafsauthent/Makefile.in index 6b11521d7..f6f615e88 100644 --- a/src/libafsauthent/Makefile.in +++ b/src/libafsauthent/Makefile.in @@ -152,7 +152,7 @@ client.o: ${KAUTH}/client.c ${CCRULE} authclient.o: ${KAUTH}/authclient.c - ${CCRULE} + ${CCRULE} @CFLAGS_NOERROR@ token.o: ${KAUTH}/token.c ${CCRULE} diff --git a/src/libafsrpc/Makefile.in b/src/libafsrpc/Makefile.in index e8eeeac0a..50c8aa1b6 100644 --- a/src/libafsrpc/Makefile.in +++ b/src/libafsrpc/Makefile.in @@ -158,7 +158,7 @@ rx_pthread.o: ${RX}/rx_pthread.c ${CCRULE} ${RX}/rx_pthread.c rx.o: ${RX}/rx.c - ${CCRULE} ${RX}/rx.c + ${CCRULE} @CFLAGS_NOERROR@ ${RX}/rx.c rx_conncache.o: ${RX}/rx_conncache.c ${CCRULE} ${RX}/rx_conncache.c @@ -193,16 +193,16 @@ rxkad_client.o: ${RXKAD}/rxkad_client.c ${CCRULE} ${RXKAD}/rxkad_client.c rxkad_server.o: ${RXKAD}/rxkad_server.c - ${CCRULE} ${RXKAD}/rxkad_server.c + ${CCRULE} @CFLAGS_NOERROR@ ${RXKAD}/rxkad_server.c rxkad_common.o: ${RXKAD}/rxkad_common.c ${CCRULE} ${RXKAD}/rxkad_common.c ticket.o: ${RXKAD}/ticket.c - ${CCRULE} ${RXKAD}/ticket.c + ${CCRULE} @CFLAGS_NOERROR@ ${RXKAD}/ticket.c ticket5.o: ${RXKAD}/ticket5.c - ${CCRULE} ${RXKAD}/ticket5.c + ${CCRULE} @CFLAGS_NOERROR@ ${RXKAD}/ticket5.c crc.o: ${RXKAD}/crc.c ${CCRULE} ${RXKAD}/crc.c @@ -401,7 +401,7 @@ afsint.cs.o: ${TOP_OBJDIR}/src/fsint/afsint.cs.c ${CCRULE} ${TOP_OBJDIR}/src/fsint/afsint.cs.c afsint.xdr.o: ${TOP_OBJDIR}/src/fsint/afsint.xdr.c - ${CCRULE} ${TOP_OBJDIR}/src/fsint/afsint.xdr.c + ${CCRULE} @CFLAGS_NOERROR@ ${TOP_OBJDIR}/src/fsint/afsint.xdr.c afscbint.cs.o: ${TOP_OBJDIR}/src/fsint/afscbint.cs.c ${CCRULE} ${TOP_OBJDIR}/src/fsint/afscbint.cs.c diff --git a/src/libuafs/Makefile.common.in b/src/libuafs/Makefile.common.in index e455766c7..d6f777d12 100644 --- a/src/libuafs/Makefile.common.in +++ b/src/libuafs/Makefile.common.in @@ -736,7 +736,7 @@ $(UOBJ)/rx_packet.o: $(TOP_SRC_RX)/rx_packet.c $(UOBJ)/rx_conncache.o: $(TOP_SRCDIR)/rx/rx_conncache.c $(CRULE1) $(UOBJ)/xdr_rx.o: $(TOP_SRC_RX)/xdr_rx.c - $(CRULE1) + $(CRULE1) @CFLAGS_NOERROR@ $(UOBJ)/xdr_int32.o: $(TOP_SRC_RX)/xdr_int32.c $(CRULE1) $(UOBJ)/xdr_int64.o: $(TOP_SRC_RX)/xdr_int64.c @@ -758,7 +758,7 @@ $(UOBJ)/osi_groups.o: $(TOP_SRC_AFS)/UKERNEL/osi_groups.c $(UOBJ)/Kcallback.ss.o: $(TOP_OBJ_FSINT)/Kcallback.ss.c $(CRULE1) $(UOBJ)/Kvice.xdr.o: $(TOP_OBJ_FSINT)/Kvice.xdr.c - $(CRULE1) + $(CRULE1) @CFLAGS_NOERROR@ $(UOBJ)/Kvice.cs.o: $(TOP_OBJ_FSINT)/Kvice.cs.c $(CRULE1) $(UOBJ)/afsaux.o: $(TOP_SRC_FSINT)/afsaux.c @@ -782,13 +782,13 @@ $(UOBJ)/afs_icl.o: $(TOP_SRC_AFS)/afs_icl.c $(UOBJ)/afs_pioctl.o: $(TOP_SRC_AFS)/afs_pioctl.c $(CRULE1) -DAFS_NONFSTRANS $(UOBJ)/afs_syscall.o: $(TOP_SRC_AFS)/afs_syscall.c - $(CRULE1) -DAFS_NONFSTRANS + $(CRULE1) @CFLAGS_NOERROR@ -DAFS_NONFSTRANS $(UOBJ)/osi_vfsops.o: $(TOP_SRC_AFS)/UKERNEL/osi_vfsops.c $(CRULE1) -DAFS_NONFSTRANS $(UOBJ)/ktc.o: $(TOP_SRCDIR)/auth/ktc.c - $(CRULE1) + $(CRULE1) @CFLAGS_NOERROR@ $(UOBJ)/ticket.o: $(TOP_SRCDIR)/rxkad/ticket.c - $(CRULE1) + $(CRULE1) @CFLAGS_NOERROR@ $(UOBJ)/rxkad_server.o: $(TOP_SRCDIR)/rxkad/rxkad_server.c $(CRULE1) $(UOBJ)/ptint.cs.o: $(TOP_OBJDIR)/src/ptserver/ptint.cs.c @@ -806,7 +806,7 @@ $(UOBJ)/ubik_int.cs.o: $(TOP_OBJDIR)/src/ubik/ubik_int.cs.c $(UOBJ)/ubik_int.xdr.o: $(TOP_OBJDIR)/src/ubik/ubik_int.xdr.c $(CRULE1) $(UOBJ)/authclient.o: $(TOP_SRCDIR)/kauth/authclient.c - $(CRULE1) + $(CRULE1) @CFLAGS_NOERROR@ $(UOBJ)/kalocalcell.o: $(TOP_SRCDIR)/kauth/kalocalcell.c $(CRULE1) $(UOBJ)/client.o: $(TOP_SRCDIR)/kauth/client.c @@ -1001,7 +1001,7 @@ $(WEBOBJ)/rx_packet.o: $(TOP_SRC_RX)/rx_packet.c $(WEBOBJ)/rx_conncache.o: $(TOP_SRCDIR)/rx/rx_conncache.c $(CRULE2) $(WEBOBJ)/xdr_rx.o: $(TOP_SRC_RX)/xdr_rx.c - $(CRULE2) + $(CRULE2) @CFLAGS_NOERROR@ $(WEBOBJ)/afs_usrops.o: $(TOP_SRC_AFS)/UKERNEL/afs_usrops.c $(CRULE2) $(WEBOBJ)/afs_uuid.o: $(TOP_SRCDIR)/util/uuid.c @@ -1019,7 +1019,7 @@ $(WEBOBJ)/osi_groups.o: $(TOP_SRC_AFS)/UKERNEL/osi_groups.c $(WEBOBJ)/Kcallback.ss.o: $(TOP_OBJ_FSINT)/Kcallback.ss.c $(CRULE2) $(WEBOBJ)/Kvice.xdr.o: $(TOP_OBJ_FSINT)/Kvice.xdr.c - $(CRULE2) + $(CRULE2) @CFLAGS_NOERROR@ $(WEBOBJ)/Kvice.cs.o: $(TOP_OBJ_FSINT)/Kvice.cs.c $(CRULE2) $(WEBOBJ)/afsaux.o: $(TOP_SRC_FSINT)/afsaux.c @@ -1043,20 +1043,20 @@ $(WEBOBJ)/afs_icl.o: $(TOP_SRC_AFS)/afs_icl.c $(WEBOBJ)/afs_pioctl.o: $(TOP_SRC_AFS)/afs_pioctl.c $(CRULE2) -DAFS_NONFSTRANS $(WEBOBJ)/afs_syscall.o: $(TOP_SRC_AFS)/afs_syscall.c - $(CRULE2) -DAFS_NONFSTRANS + $(CRULE2) @CFLAGS_NOERROR@ -DAFS_NONFSTRANS $(WEBOBJ)/osi_vfsops.o: $(TOP_SRC_AFS)/UKERNEL/osi_vfsops.c $(CRULE2) -DAFS_NONFSTRANS $(WEBOBJ)/ktc.o: $(TOP_SRCDIR)/auth/ktc.c - $(CRULE2) + $(CRULE2) @CFLAGS_NOERROR@ $(WEBOBJ)/ktc.krb.o: $(TOP_SRCDIR)/auth/ktc.c - $(CRULE2) -DAFS_KERBEROS_ENV -DMAYBE_NO_KTC + $(CRULE2) -DAFS_KERBEROS_ENV -DMAYBE_NO_KTC @CFLAGS_NOERROR@ mv ktc.o ktc.krb.o $(WEBOBJ)/securehash.o: $(TOP_SRCDIR)/afsweb/securehash.c $(CRULE2) $(WEBOBJ)/nsafs.o: $(TOP_SRCDIR)/afsweb/nsafs.c $(CRULE2) $(WEBOBJ)/ticket.o: $(TOP_SRCDIR)/rxkad/ticket.c - $(CRULE2) + $(CRULE2) @CFLAGS_NOERROR@ $(WEBOBJ)/rxkad_server.o: $(TOP_SRCDIR)/rxkad/rxkad_server.c $(CRULE2) $(WEBOBJ)/ptint.cs.o: $(TOP_OBJDIR)/src/ptserver/ptint.cs.c @@ -1074,7 +1074,7 @@ $(WEBOBJ)/ubik_int.cs.o: $(TOP_OBJDIR)/src/ubik/ubik_int.cs.c $(WEBOBJ)/ubik_int.xdr.o: $(TOP_OBJDIR)/src/ubik/ubik_int.xdr.c $(CRULE2) $(WEBOBJ)/authclient.o: $(TOP_SRCDIR)/kauth/authclient.c - $(CRULE2) + $(CRULE2) @CFLAGS_NOERROR@ $(WEBOBJ)/kalocalcell.o: $(TOP_SRCDIR)/kauth/kalocalcell.c $(CRULE2) $(WEBOBJ)/client.o: $(TOP_SRCDIR)/kauth/client.c @@ -1270,7 +1270,7 @@ $(JUAFS)/rx_packet.o: $(TOP_SRC_RX)/rx_packet.c $(JUAFS)/rx_conncache.o: $(TOP_SRCDIR)/rx/rx_conncache.c $(CRULE1) $(JUAFS)/xdr_rx.o: $(TOP_SRC_RX)/xdr_rx.c - $(CRULE1) + $(CRULE1) @CFLAGS_NOERROR@ $(JUAFS)/xdr_int64.o: $(TOP_SRC_RX)/xdr_int64.c $(CRULE1) $(JUAFS)/afs_usrops.o: $(TOP_SRC_AFS)/UKERNEL/afs_usrops.c @@ -1290,7 +1290,7 @@ $(JUAFS)/osi_groups.o: $(TOP_SRC_AFS)/UKERNEL/osi_groups.c $(JUAFS)/Kcallback.ss.o: $(TOP_OBJ_FSINT)/Kcallback.ss.c $(CRULE1) $(JUAFS)/Kvice.xdr.o: $(TOP_OBJ_FSINT)/Kvice.xdr.c - $(CRULE1) + $(CRULE1) @CFLAGS_NOERROR@ $(JUAFS)/Kvice.cs.o: $(TOP_OBJ_FSINT)/Kvice.cs.c $(CRULE1) $(JUAFS)/afsaux.o: $(TOP_SRC_FSINT)/afsaux.c @@ -1312,13 +1312,13 @@ $(JUAFS)/afs_icl.o: $(TOP_SRC_AFS)/afs_icl.c $(JUAFS)/afs_pioctl.o: $(TOP_SRC_AFS)/afs_pioctl.c $(CRULE1) -DAFS_NONFSTRANS $(JUAFS)/afs_syscall.o: $(TOP_SRC_AFS)/afs_syscall.c - $(CRULE1) -DAFS_NONFSTRANS + $(CRULE1) @CFLAGS_NOERROR@ -DAFS_NONFSTRANS $(JUAFS)/osi_vfsops.o: $(TOP_SRC_AFS)/UKERNEL/osi_vfsops.c $(CRULE1) -DAFS_NONFSTRANS $(JUAFS)/ktc.o: $(TOP_SRCDIR)/auth/ktc.c - $(CRULE1) + $(CRULE1) @CFLAGS_NOERROR@ $(JUAFS)/ticket.o: $(TOP_SRCDIR)/rxkad/ticket.c - $(CRULE1) + $(CRULE1) @CFLAGS_NOERROR@ $(JUAFS)/rxkad_server.o: $(TOP_SRCDIR)/rxkad/rxkad_server.c $(CRULE1) $(JUAFS)/ptint.cs.o: $(TOP_OBJDIR)/src/ptserver/ptint.cs.c @@ -1336,7 +1336,7 @@ $(JUAFS)/ubik_int.cs.o: $(TOP_OBJDIR)/src/ubik/ubik_int.cs.c $(JUAFS)/ubik_int.xdr.o: $(TOP_OBJDIR)/src/ubik/ubik_int.xdr.c $(CRULE1) $(JUAFS)/authclient.o: $(TOP_SRCDIR)/kauth/authclient.c - $(CRULE1) + $(CRULE1) @CFLAGS_NOERROR@ $(JUAFS)/kalocalcell.o: $(TOP_SRCDIR)/kauth/kalocalcell.c $(CRULE1) $(JUAFS)/client.o: $(TOP_SRCDIR)/kauth/client.c diff --git a/src/ptserver/Makefile.in b/src/ptserver/Makefile.in index a55177a6e..cbd631f65 100644 --- a/src/ptserver/Makefile.in +++ b/src/ptserver/Makefile.in @@ -94,6 +94,7 @@ ptserver: ptserver.o ptutils.o ptprocs.o ptint.ss.o ptint.xdr.o utils.o $(LIBS) $(CC) ${CFLAGS} -o ptserver ptserver.o ptutils.o ptprocs.o ptint.ss.o ptint.xdr.o utils.o map.o $(LIBS) ${XLIBS} ${TOP_LIBDIR}/libaudit.a ptserver.o: ptserver.c ${INCLS} AFS_component_version_number.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< ptutils.o: ptutils.c ${INCLS} diff --git a/src/rxkad/Makefile.in b/src/rxkad/Makefile.in index 0b000f61a..9ca071b63 100644 --- a/src/rxkad/Makefile.in +++ b/src/rxkad/Makefile.in @@ -62,7 +62,8 @@ librxkad.a: ${OBJS} AFS_component_version_number.o rxkad_client.o: fcrypt.h private_data.h rxkad_client.c ${INCLS} -rxkad_server.o: fcrypt.h private_data.h rxkad_server.c ${INCLS} +rxkad_server.o: rxkad_server.c fcrypt.h private_data.h ${INCLS} + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< rxkad_common.o: fcrypt.h private_data.h rxkad_common.c ${INCLS} @@ -73,8 +74,10 @@ rxkad_errs.c rxkad.h: rxkad_errs.et rxkad.p.h ${COMPILE_ET} -p ${srcdir} rxkad_errs -h rxkad ticket.o: ticket.c lifetimes.h ${INCLS} + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< ticket5.o: ticket5.c v5gen.c v5der.c v5gen-rewrite.h ${INCLS} + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< crc.o: crc.c ${INCLS} diff --git a/src/tviced/Makefile.in b/src/tviced/Makefile.in index b749078ea..4c01394e4 100644 --- a/src/tviced/Makefile.in +++ b/src/tviced/Makefile.in @@ -59,16 +59,16 @@ LIBS=${TOP_LIBDIR}/libafsauthent.a ${TOP_LIBDIR}/libafsrpc.a ${TOP_LIBDIR}/util. all: fileserver state_analyzer rx_pthread.o: ${RX}/rx_pthread.c - ${CCRULE} -DDPF_FSLOG + ${CCRULE} @CFLAGS_NOERROR@ -DDPF_FSLOG viced.o: ${VICED}/viced.c ${CCRULE} afsfileprocs.o: ${VICED}/afsfileprocs.c - ${CCRULE} + ${CCRULE} @CFLAGS_NOERROR@ host.o: ${VICED}/host.c - ${CCRULE} + ${CCRULE} @CFLAGS_NOERROR@ physio.o: ${VICED}/physio.c ${CCRULE} @@ -198,7 +198,7 @@ afsint.ss.o: ${FSINT}/afsint.ss.c ${CCRULE} afsint.xdr.o: ${FSINT}/afsint.xdr.c - ${CCRULE} + ${CCRULE} @CFLAGS_NOERROR@ state_analyzer.o: state_analyzer.c ${CCRULE} diff --git a/src/ubik/Makefile.in b/src/ubik/Makefile.in index 443c4b196..fd7377848 100644 --- a/src/ubik/Makefile.in +++ b/src/ubik/Makefile.in @@ -75,6 +75,8 @@ Kubik_int.h: ubik_int.xg ${RXGEN} -A -x -k -h -o Kubik_int.h ${srcdir}/ubik_int.xg utst_int.ss.o: utst_int.ss.c utst_int.xdr.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + utst_int.cs.o: utst_int.cs.c utst_int.xdr.c utst_int.xdr.o: utst_int.xdr.c utst_int.h @@ -114,7 +116,12 @@ libubik.a: ${LIBOBJS} AFS_component_version_number.o disk.o: disk.c ${INCLS} uinit.o: uinit.c ${INCLS} remote.o: remote.c ${INCLS} + +# beacon.c uses signed and unsigned interchangably for IP addresses. Fixing +# will require changing the Ubik API beacon.o: beacon.c ${INCLS} + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + lock.o: lock.c ${INCLS} recovery.o: recovery.c ${INCLS} ubik.o: ubik.c ${INCLS} diff --git a/src/ubik/ubikclient.c b/src/ubik/ubikclient.c index df48738de..a286b6782 100644 --- a/src/ubik/ubikclient.c +++ b/src/ubik/ubikclient.c @@ -14,6 +14,9 @@ #include #endif +#ifdef IGNORE_SOME_GCC_WARNINGS +# pragma GCC diagnostic warning "-Wstrict-prototypes" +#endif #if defined(UKERNEL) #include "afs/sysincludes.h" diff --git a/src/uss/Makefile.in b/src/uss/Makefile.in index 2fed61022..20fca39ab 100644 --- a/src/uss/Makefile.in +++ b/src/uss/Makefile.in @@ -60,7 +60,7 @@ uss_common.o : uss_common.c ${CC} -c ${CFLAGS} ${srcdir}/uss_common.c uss_vol.o : uss_vol.c - ${CC} -c ${CFLAGS} ${srcdir}/uss_vol.c + ${CC} -c ${CFLAGS} @CFLAGS_NOERROR@ ${srcdir}/uss_vol.c uss_acl.o : uss_acl.c ${CC} -c ${CFLAGS} ${srcdir}/uss_acl.c @@ -69,13 +69,13 @@ uss_ptserver.o : uss_ptserver.c ${CC} -c ${CFLAGS} ${srcdir}/uss_ptserver.c uss_kauth.o : uss_kauth.c - ${CC} -c ${CFLAGS} ${srcdir}/uss_kauth.c + ${CC} -c ${CFLAGS} @CFLAGS_NOERROR@ ${srcdir}/uss_kauth.c uss_fs.o : uss_fs.c ${CC} -c ${CFLAGS} ${srcdir}/uss_fs.c lex.yy.o : lex.yy.c y.tab.c - ${CC} -c ${CFLAGS} lex.yy.c + ${CC} -c ${CFLAGS} @CFLAGS_NOERROR@ lex.yy.c lex.yy.c : lex.l ${LEX} ${srcdir}/lex.l diff --git a/src/viced/Makefile.in b/src/viced/Makefile.in index 81d1ae98d..ad587edc5 100644 --- a/src/viced/Makefile.in +++ b/src/viced/Makefile.in @@ -87,7 +87,7 @@ fileserver: ${objects} ${headers} ${LIBS} esac fsprobe.o: fsprobe.c AFS_component_version_number.c - ${CC} ${CFLAGS} -DINTERPRET_DUMP -c ${srcdir}/fsprobe.c + ${CC} ${CFLAGS} @CFLAGS_NOERROR@ -DINTERPRET_DUMP -c ${srcdir}/fsprobe.c fsprobe: fsprobe.o ${CC} ${CFLAGS} -o fsprobe fsprobe.o ${LIBS} ${XLIBS} diff --git a/src/vlserver/Makefile.in b/src/vlserver/Makefile.in index be4a15fd3..b4c5d708d 100644 --- a/src/vlserver/Makefile.in +++ b/src/vlserver/Makefile.in @@ -126,6 +126,8 @@ vl_errors.o: vl_errors.c vlserver.h vl_errors.c: vl_errors.et vlserver.p.h $(RM) -f vlserver.h vl_errors.c; ${COMPILE_ET} -p ${srcdir} vl_errors -h vlserver +vlserver.o: vlserver.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< system: install install: vlserver cnvldb vldb_check libvldb.a vl_opcodes.h vlserver.h \ diff --git a/src/vol/Makefile.in b/src/vol/Makefile.in index cefd2326b..1afeabd56 100644 --- a/src/vol/Makefile.in +++ b/src/vol/Makefile.in @@ -180,6 +180,9 @@ vol-salvage.o vutil.o: volinodes.h vol-salvage.o salvager.o: vol-salvage.h vol-salvage.o: salvsync.h daemon_com.h +salvager.o: salvager.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + vlib.a: ${VLIBOBJS} AFS_component_version_number.o $(RM) -f $@ $(AR) crv $@ ${VLIBOBJS} AFS_component_version_number.o diff --git a/src/volser/Makefile.in b/src/volser/Makefile.in index 872dd4dc3..a915dc6f3 100644 --- a/src/volser/Makefile.in +++ b/src/volser/Makefile.in @@ -135,6 +135,12 @@ common.o: common.c ${VINCLS} lockprocs.o: lockprocs.c ${VINCLS} ${INTINCLS} ${RINCLS} vol_split.o: vol_split.c ${VINCLS} ${INTINCLS} ${RINCLS} +# +# Errors +# +vos.o: vos.c + $(CC) $(CFLAGS) @CFLAGS_NOERROR@ -c $< + # # Installation targets # diff --git a/src/volser/vol-dump.c b/src/volser/vol-dump.c index 78eab6f12..cb7672890 100644 --- a/src/volser/vol-dump.c +++ b/src/volser/vol-dump.c @@ -17,6 +17,9 @@ #include #include +#ifdef IGNORE_SOME_GCC_WARNINGS +# pragma GCC diagnostic warning "-Wformat" +#endif #include #include diff --git a/src/volser/vsprocs.c b/src/volser/vsprocs.c index 298be88a2..0105608af 100644 --- a/src/volser/vsprocs.c +++ b/src/volser/vsprocs.c @@ -10,6 +10,9 @@ #include #include +#ifdef IGNORE_SOME_GCC_WARNINGS +# pragma GCC diagnostic warning "-Wformat-extra-args" +#endif #include #include -- 2.39.5