tmpdir: Split out new file of common utilities.
[checkpath] / Makefile.am
index 42e907d..b23bcbc 100644 (file)
 
 bin_PROGRAMS            =
 lib_LTLIBRARIES                 =
+noinst_LIBRARIES        =
 include_HEADERS                 =
 dist_man_MANS           =
 
 CLEANFILES              =
 EXTRA_DIST              =
+LDADD                   =
+
+###--------------------------------------------------------------------------
+### Programs.
+
+## Common stuff.
+noinst_LIBRARIES       += libutils.a
+libutils_a_SOURCES      =
+LDADD                  += libutils.a
+
+libutils_a_SOURCES     += utils.c
+libutils_a_SOURCES     += utils.h
+
+## chkpath
+bin_PROGRAMS           += chkpath
+dist_man_MANS          += chkpath.1
+
+## tmpdir
+bin_PROGRAMS           += tmpdir
+dist_man_MANS          += tmpdir.1
 
 ###--------------------------------------------------------------------------
 ### Library.
@@ -40,6 +61,7 @@ libcheckpath_la_SOURCES        =
 libcheckpath_la_LDFLAGS         = -version-info $(LIBTOOL_VERSION_INFO)
 libcheckpath_la_LIBADD  = $(mLib_LIBS)
 dist_man_MANS          += checkpath.3
+LDADD                  += libcheckpath.la
 
 libcheckpath_la_SOURCES        += checkpath.c
 include_HEADERS                += checkpath.h
@@ -58,19 +80,6 @@ checkpath.pc: checkpath.pc.in Makefile
        mv $@.new $@
 
 ###--------------------------------------------------------------------------
-### Programs.
-
-LDADD                   = libcheckpath.la $(mLib_LIBS)
-
-## chkpath
-bin_PROGRAMS           += chkpath
-dist_man_MANS          += chkpath.1
-
-## tmpdir
-bin_PROGRAMS           += tmpdir
-dist_man_MANS          += tmpdir.1
-
-###--------------------------------------------------------------------------
 ### Other finishing touches.
 
 ## Version stamp.
@@ -80,6 +89,9 @@ dist-hook::
 ## Build tools.
 EXTRA_DIST             += config/confsubst
 
+## External libraries.
+LDADD                  += $(mLib_LIBS)
+
 ###--------------------------------------------------------------------------
 ### Debian.