summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile.am11
-rw-r--r--configure.ac3
2 files changed, 13 insertions, 1 deletions
diff --git a/Makefile.am b/Makefile.am
index ce7a262..9a09d88 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -21,7 +21,8 @@
bin_PROGRAMS = mkfontscale
-AM_CFLAGS = @MKFONTSCALE_CFLAGS@ @X11_CFLAGS@ -D_BSD_SOURCE $(CWARNFLAGS)
+AM_CPPFLAGS = @MKFONTSCALE_CFLAGS@ @X11_CFLAGS@ -D_BSD_SOURCE
+AM_CFLAGS = $(CWARNFLAGS)
mkfontscale_LDADD = @MKFONTSCALE_LIBS@
mkfontscale_SOURCES = \
@@ -73,3 +74,11 @@ ChangeLog:
$(CHANGELOG_CMD)
dist-hook: ChangeLog
+
+if LINT
+ALL_LINT_FLAGS=$(LINT_FLAGS) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
+ $(AM_CPPFLAGS) $(CPPFLAGS)
+
+lint:
+ $(LINT) $(ALL_LINT_FLAGS) $(mkfontscale_SOURCES)
+endif LINT
diff --git a/configure.ac b/configure.ac
index 18d73ae..fc39388 100644
--- a/configure.ac
+++ b/configure.ac
@@ -56,6 +56,9 @@ AC_SUBST(MKFONTSCALE_LIBS)
PKG_CHECK_MODULES(X11, xproto)
AC_SUBST(X11_CFLAGS)
+dnl Allow checking code with lint, sparse, etc.
+XORG_WITH_LINT
+
XORG_MANPAGE_SECTIONS
XORG_RELEASE_VERSION
XORG_CHANGELOG