chiark / gitweb /
builds nicely in new style
authorianmdlvl <ianmdlvl>
Sun, 29 Jun 2003 13:44:25 +0000 (13:44 +0000)
committerianmdlvl <ianmdlvl>
Sun, 29 Jun 2003 13:44:25 +0000 (13:44 +0000)
backup/Makefile
cprogs/Makefile
debian/changelog
debian/control
debian/rules
scripts/Makefile
settings.make [new file with mode: 0644]

index 084c6fbe0fdd80b92a1d7d334157ce103e862cec..91f76640fbadd683ddd3488093fc32890822d38c 100644 (file)
 # with this program; if not, write to the Free Software Foundation, Inc.,
 # 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 
-SYSTEM_GROUP=  root
+us=    chiark-backup
 
-prefix=/usr/local
-etcdir=/etc
-varlib=/var/lib
-
-confdir=$(etcdir)/chiark-backup
-bindir=$(prefix)/bin
-sharedir=$(prefix)/share/chiark-backup
-txtdocdir=$(prefix)/share/doc/chiark-backup
-exampledir=$(txtdocdir)/examples
-vardir=$(varlib)/chiark-backup
-mandir=${prefix}/man
-man1dir=${mandir}/man1
-
-INSTALL=               install -c
-INSTALL_SHARE=         $(INSTALL) -m 644 -o root -g $(SYSTEM_GROUP)
-INSTALL_SCRIPT=                $(INSTALL) -m 755 -o root -g $(SYSTEM_GROUP)
-INSTALL_PROGRAM=       $(INSTALL_SCRIPT) -s
-INSTALL_DIRECTORY=     $(INSTALL) -m 2755 -o root -g $(SYSTEM_GROUP) -d
+include ../settings.make
 
 BINSCRIPTS=    checkallused loaded driver takedown whatsthis labeltape
 SHARESCRIPTS=  bringup full increm
index fb2d9fb42c326b1ea7e2e4380c4fdf9b1645f856..141dbc0b107e78417ac63faf17c546afb3859852 100644 (file)
 # with this program; if not, write to the Free Software Foundation, Inc.,
 # 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 
-CC=            gcc
-CFLAGS=                $(WARNINGS) $(OPTIMISE) $(DEBUG)
-CPPFLAGS=      -DRWBUFFER_SIZE_MB=$(RWBUFFER_SIZE_MB)
+include ../settings.make
 
-WARNINGS=      -Wall -Wwrite-strings -Wmissing-prototypes \
-               -Wstrict-prototypes -Wpointer-arith
-OPTIMISE=      -O2
-DEBUG=         -g
 RWBUFFER_SIZE_MB=16
 
-SYSTEM_GROUP=  root
-
-prefix=/usr/local
-
-bindir=$(prefix)/bin
-sbindir=$(prefix)/sbin
-mandir=${prefix}/man
-man1dir=${mandir}/man1
-man8dir=${mandir}/man8
-
-INSTALL=               install -c
-INSTALL_PROGRAM=       $(INSTALL_SCRIPT) -s
-
 PROGRAMS=      readbuffer writebuffer
 DAEMONS=       trivsoundd
 MAN1PAGES=     readbuffer.1 writebuffer.1
index 7b6b77207a75a42c224191df45ae76f9bceff05b..bde8d4511394be0932487767a206bc3b8477ea34 100644 (file)
@@ -1,8 +1,13 @@
 chiark-utils (3.0.3.99.3) unstable; urgency=low
 
-  * initial work on trivsoundd
-
- --
+  * trivsoundd is in the source tree but not shipped in the .debs,
+    and largely untested.  readbuffer/writebuffer are in new cprogs
+    directory.
+  * sync-accounts and chiark-named-conf merged into single
+    chiark-scripts package.
+  * Makefile commonality moved into settings.make.
+
+ -- Ian Jackson <ian@davenant.greenend.org.uk>  Sun, 29 Jun 2003 14:12:56 +0100
 
 chiark-utils (3.0.3.99.2) unstable; urgency=low
 
index 8fa9b97c1fb41cc85f92a883b13332c2e7625e7f..e7074fdfa6082604894d98603624c446152f0b38 100644 (file)
@@ -16,18 +16,22 @@ Description: backup system for small systems and networks
   * Hard failures when individual systems fail, to encourage fixing !
  If you have a larger site you may wish to look at Amanda.
 
-Package: chiark-named-conf
+Package: chiark-scripts
+Conflicts: chiark-named-conf, sync-accounts
+Replaces: chiark-named-conf, sync-accounts
 Architecture: all
-Description: chiark-named-conf: checks nameserver configuration
- chiark-named-conf is a tool for managing nameserver configurations
+Description: chiark system administration scripts
+ This package contains a number of small administration scripts used
+ by chiark.greenend.org.uk and other systems belonging to the Sinister
+ Greenend Organisation.  Featuring:
+ .
+ chiark-named-conf: a tool for managing nameserver configurations
  and checking for suspected DNS problems.  Its main functions are to
  check that delegations are appropriate and working, that secondary
  zones are slaved from the right places, and to generate a
  configuration for BIND, from its own input file.
-
-Package: sync-accounts
-Architecture: all
-Description: sync-accounts: simple but flexible account info synchroniser
+ .
+ sync-accounts: a simple but flexible account info synchroniser.
  sync-accounts is a tool for copying un*x account data from remote
  systems and installing it locally.  It is flexible and reasonably
  straightforward, but lacks integration with other distributed
index b1c92b6b0705c22deefb644b8378d6198cb7695f..235a31d3d03d733fb178db534c3a98da4fc00f45 100755 (executable)
@@ -1,8 +1,9 @@
 #!/usr/bin/make -f
 
-subdirs=       backup
+subdirs_build= cprogs
+subdirs_nobuild=backup sync-accounts scripts
 package=       chiark-utils
-packages_indep=        chiark-backup sync-accounts chiark-named-conf
+packages_indep=        chiark-backup chiark-scripts
 packages_arch= chiark-rwbuffer
 packages=      $(packages_indep) $(packages_arch)
 
@@ -12,13 +13,13 @@ t=  $d/tmp
 
 build:
        $(checkdir)
-       set -e; for s in $(subdirs); do $(MAKE) -C $$s all; done
+       set -e; for s in $(subdirs_build); do $(MAKE) -C $$s all; done
        touch build
 
 clean:
        $(checkdir)
        rm -f build
-       set -e; for s in $(subdirs); do \
+       set -e; for s in $(subdirs_build); do \
                $(MAKE) -C $$s -i distclean || \
                $(MAKE) -C $$s -f Makefile.in distclean; \
        done
@@ -28,6 +29,19 @@ binary-prep:
        $(checkdir)
        rm -rf debian/tmp*
        #
+       set -e; for s in $(subdirs_build) $(subdirs_nobuild); do \
+               $(MAKE) -C $$s install install-docs install-examples \
+                       prefix=$t/$$s/usr \
+                       etcdir=$t/$$s/etc \
+                       varlib=$t/$$s/var/lib \
+                       mandir=$t/$$s/usr/share/man; \
+       done
+       #
+       cp -a debian/tmp/sync-accounts/* debian/tmp/scripts/.
+       rm -r debian/tmp/sync-accounts
+       mv debian/tmp/scripts debian/tmp/chiark-scripts
+       mv debian/tmp/backup debian/tmp/chiark-backup
+       #
        set -e; for p in $(packages); do \
                install -d $t/$$p/DEBIAN $t/$$p/usr/share/doc/$$p; \
                cp debian/copyright debian/changelog \
@@ -37,36 +51,18 @@ binary-prep:
                gzip -9v $t/$$p/usr/share/doc/$$p/changelog; \
                done
        #
-       $(MAKE) -C backup install install-docs install-examples \
-               prefix=$t/chiark-backup/usr \
-               etcdir=$t/chiark-backup/etc \
-               varlib=$t/chiark-backup/var/lib \
-               mandir=$t/chiark-backup/usr/share/man
-       #
-       $(MAKE) -C sync-accounts install install-docs install-examples \
-               prefix=$t/sync-accounts/usr \
-               etcdir=$t/sync-accounts/etc \
-               varlib=$t/sync-accounts/var/lib \
-               mandir=$t/sync-accounts/usr/share/man
-       #
-       $(MAKE) -C scripts install install-docs install-examples \
-               prefix=$t/chiark-named-conf/usr \
-               etcdir=$t/chiark-named-conf/etc \
-               varlib=$t/chiark-named-conf/var/lib \
-               mandir=$t/chiark-named-conf/usr/share/man
-       #
        install -d $t/chiark-rwbuffer/usr/bin
        install -d $t/chiark-rwbuffer/usr/share/man/man1
-       cd $t/chiark-backup/usr/bin && \
+       cd $t/cprogs/usr/bin && \
                mv readbuffer writebuffer $t/chiark-rwbuffer/usr/bin
-       cd $t/chiark-backup/usr/share/man/man1 && \
+       cd $t/cprogs/usr/share/man/man1 && \
                mv readbuffer.1 writebuffer.1 $t/chiark-rwbuffer/usr/share/man/man1
        gzip -9f $t/*/usr/share/man/man*/*
 
 binary-hook-chiark-backup:
 binary-hook-chiark-rwbuffer:
 binary-hook-sync-accounts:
-binary-hook-chiark-named-conf:
+binary-hook-chiark-scripts:
 
 binary-one:
        set -e; for f in preinst postinst prerm postrm conffiles; do \
@@ -91,7 +87,7 @@ binary-arch:  checkroot build binary-prep
                do debian/rules binary-one p=$$p; done
 
 define checkdir
-       test -f backup/writebuffer.c
+       test -f cprogs/writebuffer.c
 endef
 
 # Below here is fairly generic really
index 4a71bee698fdbb864d86dc604064bd82c0cba312..30a48bbbb1886998a707b14b6f2e75795ad6231c 100644 (file)
 # with this program; if not, write to the Free Software Foundation, Inc.,
 # 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 
-SYSTEM_GROUP=  root
-
-INSTALL=               install -c
-INSTALL_SHARE=         $(INSTALL) -m 644 -o root -g $(SYSTEM_GROUP)
-INSTALL_SCRIPT=                $(INSTALL) -m 755 -o root -g $(SYSTEM_GROUP)
-INSTALL_DIRECTORY=     $(INSTALL) -m 2755 -o root -g $(SYSTEM_GROUP) -d
-
-prefix=/usr/local
-bindir=$(prefix)/bin
-mandir=${prefix}/man
-man8dir=${mandir}/man8
+include ../settings.make
 
 SCRIPTS=       named-conf
 MANPAGES8=     named-conf
diff --git a/settings.make b/settings.make
new file mode 100644 (file)
index 0000000..37e41ab
--- /dev/null
@@ -0,0 +1,52 @@
+# Makefile
+# common make settings
+#
+# This file is part of chiark-utils, a collection of useful utilities
+#
+# This file is:
+#  Copyright (C) 1997-1998,2000-2001 Ian Jackson <ian@chiark.greenend.org.uk>
+#
+# This is free software; you can redistribute it and/or modify it under the
+# terms of the GNU General Public License as published by the Free Software
+# Foundation; either version 2, or (at your option) any later version.
+#
+# This is distributed in the hope that it will be useful, but WITHOUT ANY
+# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+# FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
+# details.
+#
+# You should have received a copy of the GNU General Public License along
+# with this program; if not, write to the Free Software Foundation, Inc.,
+# 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+
+CC=            gcc
+CFLAGS=                $(WARNINGS) $(OPTIMISE) $(DEBUG)
+CPPFLAGS=      -DRWBUFFER_SIZE_MB=$(RWBUFFER_SIZE_MB)
+
+WARNINGS=      -Wall -Wwrite-strings -Wmissing-prototypes \
+               -Wstrict-prototypes -Wpointer-arith
+OPTIMISE=      -O2
+DEBUG=         -g
+
+SYSTEM_GROUP=  root
+
+prefix=/usr/local
+etcdir=/etc
+varlib=/var/lib
+
+confdir=$(etcdir)/$(us)
+bindir=$(prefix)/bin
+sbindir=$(prefix)/sbin
+sharedir=$(prefix)/share/$(us)
+txtdocdir=$(prefix)/share/doc/$(us)
+exampledir=$(txtdocdir)/examples
+vardir=$(varlib)/$(us)
+mandir=${prefix}/man
+man1dir=${mandir}/man1
+man8dir=${mandir}/man8
+
+INSTALL=               install -c
+INSTALL_SHARE=         $(INSTALL) -m 644 -o root -g $(SYSTEM_GROUP)
+INSTALL_SCRIPT=                $(INSTALL) -m 755 -o root -g $(SYSTEM_GROUP)
+INSTALL_PROGRAM=       $(INSTALL_SCRIPT) -s
+INSTALL_DIRECTORY=     $(INSTALL) -m 2755 -o root -g $(SYSTEM_GROUP) -d