From 0143eb25577dad73304f676e5f392328b7b08d9b Mon Sep 17 00:00:00 2001
From: Henrik Uhrenholt <henrik.uhrenholt.gpl@gmail.com>
Date: Mon, 7 Feb 2011 23:01:05 -0800
Subject: [PATCH] Added splint info.

* Added splint URL
* Added AC_REQUIRE([AX_ADD_AM_MACRO_STATIC])
* Added support for running splint on LTLIBRARIES
---
 m4/ax_prog_splint.m4 |   11 +++++++----
 1 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/m4/ax_prog_splint.m4 b/m4/ax_prog_splint.m4
index f14dfae..f4bcf49 100644
--- a/m4/ax_prog_splint.m4
+++ b/m4/ax_prog_splint.m4
@@ -8,8 +8,9 @@
 #
 # DESCRIPTION
 #
-#   Check for program splint. This macro should be use together with
-#   automake.
+#   Check for program splint, the static C code checking tool. 
+#   The splint URL is given by http://www.splint.org.
+#   This macro should be use together with automake. 
 #
 #   Enables following environment variables:
 #
@@ -44,6 +45,7 @@
 
 AC_DEFUN([AX_PROG_SPLINT],
 [
+AC_REQUIRE([AX_ADD_AM_MACRO_STATIC])
 AC_ARG_VAR([SPLINT], [splint executable])
 AC_ARG_VAR([SPLINTFLAGS], [splint flags])
 if test "x$SPLINT" = "x"; then
@@ -73,11 +75,12 @@ endef
 
 SPLINT_BIN=\$(subst /,_,\$(PROGRAMS:\$(EXEEXT)=))
 SPLINT_LIB=\$(subst /,_,\$(LIBRARIES:.a=_a))
-SPLINTFILES=\$(addsuffix _splint.log,\$(SPLINT_LIB) \$(SPLINT_BIN))
+SPLINT_LTLIB=\$(subst /,_,\$(LTLIBRARIES:.la=_la))
+SPLINTFILES=\$(addsuffix _splint.log,\$(SPLINT_LIB) \$(SPLINT_BIN) \$(SPLINT_LTLIB))
 
 splint-check: all \$(SPLINTFILES)
 
-\$(foreach bin, \$(SPLINT_BIN) \$(SPLINT_LIB),\$(eval \$(call splint_rules,\$(bin))))
+\$(foreach bin, \$(SPLINT_BIN) \$(SPLINT_LIB) \$(SPLINT_LTLIB),\$(eval \$(call splint_rules,\$(bin))))
 
 
 
-- 
1.7.0.4

