sema: New program for hacking with semaphores.
[misc] / Makefile.am
index aaae6f4..2521b3d 100644 (file)
@@ -1,6 +1,6 @@
 ### -*-makefile-*-
 ###
-### Build script for nsict-utils
+### Build script for distorted-utils
 ###
 ### (c) 2008 Mark Wooding
 ###
@@ -58,7 +58,7 @@ dist_man_MANS         += getpass.1
 ## xtitle
 bin_PROGRAMS           += xtitle
 xtitle_SOURCES          = xtitle.c
-## !UNDOCUMENTED
+dist_man_MANS          += xtitle.1
 
 ## pause
 if HAVE_MLIB
@@ -68,6 +68,14 @@ pause_LDADD           = $(mLib_LIBS) $(MATH_LIBS)
 dist_man_MANS          += pause.1
 endif
 
+## mtimeout
+if HAVE_MLIB
+bin_PROGRAMS           += mtimeout
+mtimeout_SOURCES        = mtimeout.c
+mtimeout_LDADD          = $(mLib_LIBS) $(MATH_LIBS)
+dist_man_MANS          += mtimeout.1
+endif
+
 ## stamp
 if HAVE_MLIB
 bin_PROGRAMS           += stamp
@@ -84,6 +92,16 @@ locking_LDADD                 = $(mLib_LIBS)
 dist_man_MANS          += locking.1
 endif
 
+## prlimit
+if HAVE_PRLIMIT
+if HAVE_MLIB
+bin_PROGRAMS           += prlimit
+prlimit_SOURCES                 = prlimit.c
+prlimit_LDADD           = $(mLib_LIBS)
+dist_man_MANS          += prlimit.1
+endif
+endif
+
 ## gorp
 if HAVE_CATACOMB
 bin_PROGRAMS           += gorp
@@ -92,12 +110,15 @@ gorp_LDADD          = $(catacomb_LIBS)
 dist_man_MANS          += gorp.1
 endif
 
-## qmail-checkspam
-if HAVE_LIBSPAMC
-sbin_PROGRAMS          += qmail-checkspam
-qmail_checkspam_SOURCES         = qmail-checkspam.c
-qmail_checkspam_LDADD   = -lspamc
-dist_man_MANS          += qmail-checkspam.8
+## sema
+if HAVE_MLIB
+bin_PROGRAMS           += sema
+sema_SOURCES            = sema.c
+sema_SOURCES           += fence.c fence.h
+sema_SOURCES           += timemax.cc timemax.h
+sema_LDADD              = $(mLib_LIBS)
+sema_LINK               = $(LINK) # don't need C++ libraries here
+dist_man_MANS          += sema.1
 endif
 
 ## cdb tools
@@ -112,11 +133,13 @@ endif
 
 ## x86 model identification
 if X86
+if HAVE_MLIB
 bin_PROGRAMS           += x86-model
 x86_model_SOURCES       = x86-model.c
 x86_model_LDADD                 = $(mLib_LIBS)
 dist_man_MANS          += x86-model.1
 endif
+endif
 
 ###--------------------------------------------------------------------------
 ### Tools in scripts.
@@ -137,7 +160,8 @@ SUBSTITUTIONS = \
        PYTHON=$(PYTHON) \
        PERL=$(PERL) \
        TCLSH=$(TCLSH) \
-       BASH=$(BASH)
+       BASH=$(BASH) \
+       logdir=$(logdir)
 
 EXTRA_DIST             += config/confsubst
 
@@ -154,6 +178,25 @@ dist_man_MANS              += create.1
 dist_bin_SCRIPTS       += z
 dist_man_MANS          += z.1
 
+bin_SCRIPTS            += hush
+man_MANS               += hush.1
+CLEANFILES             += hush hush.1
+EXTRA_DIST             += hush.in hush.1.in
+
+hush: hush.in Makefile
+       $(SUBST) $(srcdir)/hush.in >$@.new $(SUBSTITUTIONS) && \
+               chmod +x $@.new && mv $@.new $@
+
+hush.1: hush.1.in Makefile
+       $(SUBST) $(srcdir)/hush.1.in >$@.new $(SUBSTITUTIONS) && \
+               mv $@.new $@
+
+dist_bin_SCRIPTS       += with-umask
+dist_man_MANS          += with-umask.1
+
+dist_bin_SCRIPTS       += sshsvc-mkauthkeys
+dist_man_MANS          += sshsvc-mkauthkeys.1
+
 ## bash scripts.
 if HAVE_BASH
 
@@ -224,8 +267,8 @@ man_MANS            += shadowfix.8
 CLEANFILES             += shadowfix.8
 
 shadowfix.8: shadowfix.in
-       $(AM_V_GEN)pod2man --section 8 $(srcdir)/shadowfix.in \
-               >$@.new && mv $@.new $@
+       $(AM_V_GEN)pod2man --section 8 $(srcdir)/shadowfix.in >$@.new && \
+               mv $@.new $@
 
 bin_SCRIPTS            += unfwd
 CLEANFILES             += unfwd
@@ -273,6 +316,8 @@ EXTRA_DIST          += debian/rules
 EXTRA_DIST             += debian/copyright
 EXTRA_DIST             += debian/changelog
 EXTRA_DIST             += debian/control
+EXTRA_DIST             += debian/compat
+EXTRA_DIST             += debian/source/format
 
 ## What to install where.
 EXTRA_DIST             += debian/inst