--- a/rules.mk
+++ b/rules.mk
@@ -2,6 +2,8 @@
 VPATH = $(srcdir)
 
 CPPFLAGS += -I$(top_srcdir) -I$(top_srcdir)/lib -I$(builddir)
+CFLAGS += -Wall -W -Wunused -Wstrict-prototypes -Wmissing-prototypes \
+	-Wmissing-declarations -Wredundant-decls -Winline
 
 # we need paths to be overridable at build-time
 DEFS += '-DPREFIX="$(prefix)"' '-DPKG_SHARE_DIR="$(pkgdatadir)"' \
