--- /dev/null
+# adnsMakefile - top-level Makefile
+#
+# This file is part of adns, which is Copyright (C) 1997, 1998 Ian Jackson
+#
+# This program 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 program 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.
+
+SUBDIRS= src dynamic client regress
+
+all:
+ set -e; for d in $(SUBDIRS); do $(MAKE) -C $$d all; done
+
+check: all
+ $(MAKE) -C regress check
+
+install:
+ set -e; for d in $(SUBDIRS); do $(MAKE) -C $$d install; done
+
+clean:
+ set -e; for d in $(SUBDIRS); do $(MAKE) -C $$d clean; done
+
+distclean:
+ set -e; for d in $(SUBDIRS); do $(MAKE) -C $$d distclean; done
--- /dev/null
+# adnsMakefile - top-level Makefile
+#
+# This file is part of adns, which is Copyright (C) 1997, 1998 Ian Jackson
+#
+# This program 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 program 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.
+
+SUBDIRS= src dynamic client regress
+
+all:
+ set -e; for d in $(SUBDIRS); do $(MAKE) -C $$d all; done
+
+check: all
+ $(MAKE) -C regress check
+
+install:
+ set -e; for d in $(SUBDIRS); do $(MAKE) -C $$d install; done
+
+clean:
+ set -e; for d in $(SUBDIRS); do $(MAKE) -C $$d clean; done
+
+distclean:
+ set -e; for d in $(SUBDIRS); do $(MAKE) -C $$d distclean; done
--- /dev/null
+# client/Makefile - client program(s) Makefile
+#
+# This file is part of adns, which is Copyright (C) 1997, 1998 Ian Jackson
+#
+# This program 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 program 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.
+
+DIRCFLAGS= -I../src
+TARGETS= adnstest
+
+include ../settings.make
+
+install: $(TARGETS)
+ $(INSTALL_BIN) $(TARGETS) $(bin_dir)
+
+adnstest: adnstest.o ../dynamic/$(LIBFILE)
--- /dev/null
+# client/Makefile - client program(s) Makefile
+#
+# This file is part of adns, which is Copyright (C) 1997, 1998 Ian Jackson
+#
+# This program 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 program 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.
+
+DIRCFLAGS= -I../src
+TARGETS= adnstest
+
+include ../settings.make
+
+install: $(TARGETS)
+ $(INSTALL_BIN) $(TARGETS) $(bin_dir)
+
+adnstest: adnstest.o ../dynamic/$(LIBFILE)
--- /dev/null
+libadns.so.*
--- /dev/null
+# dynamic/Makefile - dynamic library Makefile
+#
+# This file is part of adns, which is Copyright (C) 1997, 1998 Ian Jackson
+#
+# This program 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 program 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.
+
+TARGETS= $(LIBFILE)
+
+include ../settings.make
+include ../src/adns.make
+
+ALLOBJS= $(addsuffix _p.o, $(basename $(LIBOBJS)))
+
+install:
+ $(INSTALL_LIB) $(LIBFILE) $(lib_dir)
+ $(INSTALL_HDR) ../src/adns.h $(include_dir)
+
+$(LIBFILE): $(ALLOBJS)
+ rm -f $@
+ $(CC) -shared -Wxl,soname=libadns.so.$(MAJOR) -o $@ $(ALLOBJS) -lc
+
+%_p.o: ../src/%.c ../src/adns.h ../src/internal.h
+ $(CC) -fpic -I../src -c -o $@ $<
+
+$(LIBOBJS):
--- /dev/null
+# dynamic/Makefile - dynamic library Makefile
+#
+# This file is part of adns, which is Copyright (C) 1997, 1998 Ian Jackson
+#
+# This program 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 program 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.
+
+TARGETS= $(LIBFILE)
+
+include ../settings.make
+include ../src/adns.make
+
+ALLOBJS= $(addsuffix _p.o, $(basename $(LIBOBJS)))
+
+install:
+ $(INSTALL_LIB) $(LIBFILE) $(lib_dir)
+ $(INSTALL_HDR) ../src/adns.h $(include_dir)
+
+$(LIBFILE): $(ALLOBJS)
+ rm -f $@
+ $(CC) -shared -Wxl,soname=libadns.so.$(MAJOR) -o $@ $(ALLOBJS) -lc
+
+%_p.o: ../src/%.c ../src/adns.h ../src/internal.h
+ $(CC) -fpic -I../src -c -o $@ $<
+
+$(LIBOBJS):
-dtest
harness.h
hcommon.c
hrecord
hrecord.c
hplayback
hplayback.c
+case-*.*-o
--- /dev/null
+# regress/Makefile - regression test Makefile
+#
+# This file is part of adns, which is Copyright (C) 1997, 1998 Ian Jackson
+#
+# This program 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 program 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.
+
+DIRCFLAGS= -I../src
+
+HCPPFLAGS:= $(foreach F, \
+ gettimeofday select \
+ socket fcntl connect close \
+ sendto recvfrom read write writev \
+, -D$F=H$F)
+
+HARNLOBJS= $(addsuffix _d.o, $(basename $(LIBOBJS)))
+ALLOBJS= $(HARNLOBJS) dtest.o hrecord.o hplayback.o hcommon.o
+AUTOCSRCS= harness.h hrecord.c hplayback.c hcommon.c
+
+TARGETS= hplayback hrecord
+
+include ../settings.make
+include ../src/adns.make
+
+.PRECIOUS: $(AUTOCSRCS)
+
+check: $(TARGETS)
+ ./checkall
+
+hrecord: ../client/adnstest.o hrecord.o hcommon.o $(HARNLOBJS)
+hplayback: ../client/adnstest.o hplayback.o hcommon.o $(HARNLOBJS)
+
+%_d.o: ../src/%.c
+ $(CC) $(HCPPFLAGS) -c -g -o $@ $<
+
+$(ALLOBJS): ../src/adns.h ../src/internal.h harness.h
+
+%:: %.m4 hmacros.i4 hsyscalls.i4
+ m4 -P $< >$@-a.new
+ sed -e 's/hm_comma/,/g; s/hm_squote/'\''/g; /^[ ]*$$/d' <$@-a.new >$@-b.new
+ @mv -f $@-b.new $@; rm -f $@-a.new
--- /dev/null
+# regress/Makefile - regression test Makefile
+#
+# This file is part of adns, which is Copyright (C) 1997, 1998 Ian Jackson
+#
+# This program 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 program 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.
+
+DIRCFLAGS= -I../src
+
+HCPPFLAGS:= $(foreach F, \
+ gettimeofday select \
+ socket fcntl connect close \
+ sendto recvfrom read write writev \
+, -D$F=H$F)
+
+HARNLOBJS= $(addsuffix _d.o, $(basename $(LIBOBJS)))
+ALLOBJS= $(HARNLOBJS) dtest.o hrecord.o hplayback.o hcommon.o
+AUTOCSRCS= harness.h hrecord.c hplayback.c hcommon.c
+
+TARGETS= hplayback hrecord
+
+include ../settings.make
+include ../src/adns.make
+
+.PRECIOUS: $(AUTOCSRCS)
+
+check: $(TARGETS)
+ ./checkall
+
+hrecord: ../client/adnstest.o hrecord.o hcommon.o $(HARNLOBJS)
+hplayback: ../client/adnstest.o hplayback.o hcommon.o $(HARNLOBJS)
+
+%_d.o: ../src/%.c
+ $(CC) $(HCPPFLAGS) -c -g -o $@ $<
+
+$(ALLOBJS): ../src/adns.h ../src/internal.h harness.h
+
+%:: %.m4 hmacros.i4 hsyscalls.i4
+ m4 -P $< >$@-a.new
+ sed -e 's/hm_comma/,/g; s/hm_squote/'\''/g; /^[ ]*$$/d' <$@-a.new >$@-b.new
+ @mv -f $@-b.new $@; rm -f $@-a.new
--- /dev/null
+adns debug: using nameserver 172.18.45.6
+chiark.greenend.org.uk type 1 A(-) submitted
+chiark.greenend.org.uk type A(-): OK; nrrs=1; cname=$
+ 195.224.76.132
--- /dev/null
+default
+:1 chiark.greenend.org.uk
+ socket type=SOCK_DGRAM
+ socket=4
+ fcntl fd=4 cmd=F_GETFL
+ fcntl=2
+ fcntl fd=4 cmd=F_SETFL 2050
+ fcntl=0
+ gettimeofday
+ gettimeofday=OK tv=912366196.835269
+ sendto fd=4 addr=172.18.45.6:53
+ 311f0100 00010000 00000000 06636869 61726b08 67726565 6e656e64 036f7267
+ 02756b00 00010001.
+ sendto=40
+ gettimeofday
+ gettimeofday=OK tv=+0.001166
+ select max=5 rfds=[4] wfds=[] efds=[] to=1.998834
+ select=1 rfds=[4] wfds=[] efds=[]
+ gettimeofday
+ gettimeofday=OK tv=+0.007822
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=OK addr=172.18.45.6:53
+ 311f8580 00010001 00020002 06636869 61726b08 67726565 6e656e64 036f7267
+ 02756b00 00010001 c00c0001 00010001 51800004 c3e04c84 08677265 656e656e
+ 64036f72 6702756b 00000200 01000151 80001103 6e73300a 72656c61 74697669
+ 7479c038 c0380002 00010001 51800006 036e7331 c057c053 00010001 00015180
+ 0004ac12 2d06c070 00010001 00015180 0004ac12 2d41.
+ recvfrom fd=4 buflen=512 *addrlen=16
+ recvfrom=EAGAIN
+ close fd=4
+ close=OK
--- /dev/null
+#!/bin/sh
+
+allok=true
+
+for f in case-*.sys
+do
+ case="`echo \"$f\" | sed -e 's/^case-//; s/\.sys$//'`"
+ if ./r1test $case
+ then
+ :
+ else
+ echo
+ allok=false
+ echo
+ fi
+done
+
+if $allok
+then
+ echo "
+all tests passed."
+ exit 0
+fi
+
+echo >&2 '
+AT LEAST ONE TEST FAILED
+'
+
+exit 1
--- /dev/null
+nameserver 172.18.45.6
+sortlist 127.0.0.1/32 172.18.45.0/28 172.18.45.0/24
# usage: m1test <name> <initfile> <queryargs>
set -e
-tcn="$1"
-initfile="$2"
+case="case-$1"; shift
+initfile="$1"; shift
queryargs="$*"
-test -d ../testcases || cd testcases
-initstring="`cat $initfile.init`"
+initstring="`cat init-$initfile.text`"
-exec >$tcn.log
-echo "$initfile"
-echo "$queryargs"
+echo "$initfile" >"$case.sys"
+echo "$queryargs" >>"$case.sys"
-H../hrecord "/$initstring" $queryargs
+echo running "hrecord /... $queryargs"
+set +e
+ADNS_TEST_OUT_FD=3 3>>"$case.sys" >"$case.stdout" 2>"$case.stderr" </dev/null \
+ ./hrecord "/$initstring" $queryargs
+rc=$?
+set -e
+
+egrep . -- "$case.stderr" "$case.stdout"
+echo "exit status: $rc"
+exit $rc
# usage: r1test <testcasename>
set -e
-tcn="$1"
-test -d ../testcases || cd testcases
+case="case-$1"
-exec <$tcn.log
+exec <"$case.sys"
read initfile
read queryargs
-initstring="`cat $initfile.init`"
-../hplayback "/$initstring" $queryargs
+
+initstring="`cat init-$initfile.text`"
+
+set +e
+ADNS_TEST_REPORT_FD=3 3>>"$case.report-o" >"$case.stdout-o" 2>"$case.stderr-o" \
+ ./hplayback "/$initstring" $queryargs
+rc=$?
+set -e
+
+if test $rc != 0
+then
+ egrep . -- "$case.report-o" "$case.stdout-o" "$case.stderr-o"
+ echo >&2 "FAILED $case - EXIT STATUS $rc"
+ exit 2
+fi
+
+for part in stdout stderr
+do
+ if diff -- "$case.$part" "$case.$part-o"
+ then
+ :
+ else
+ echo >&2 "FAILED $case - WRONG OUTPUT"
+ exit 2
+ fi
+done
+
+echo -n " $case "
+
+exit 0
--- /dev/null
+# settings.make - main configuration settings for Makefiles
+#
+# This file is part of adns, which is Copyright (C) 1997, 1998 Ian Jackson
+#
+# This program 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 program 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.
+
+MAJOR= 1
+MINOR= 0
+LIBFILE= libadns.so.$(MAJOR).$(MINOR)
+
+CC=gcc $(WARNS) $(WERROR) $(OPTIMISE) $(DEBUG) $(XCFLAGS) $(DIRCFLAGS)
+DEBUG=-g
+OPTIMISE=-O2
+WARNS= -Wall -Wmissing-prototypes -Wwrite-strings -Wstrict-prototypes \
+ -Wcast-qual -Wpointer-arith
+WERROR=-Werror
+
+prefix= /usr/local
+bin_dir= $(prefix)/bin
+lib_dir= $(prefix)/lib
+include_dir= $(prefix)/include
+
+INSTALL= install -o 0 -g 0
+INSTALL_LIB= $(INSTALL) -m 755
+INSTALL_BIN= $(INSTALL) -m 755
+INSTALL_HDR= $(INSTALL) -m 644
+
+all: $(TARGETS)
+
+clean:
+ rm -f *.o
+
+distclean: clean
+ rm -f $(TARGETS) *~ ./#*# core *.orig *.rej
--- /dev/null
+# settings.make - main configuration settings for Makefiles
+#
+# This file is part of adns, which is Copyright (C) 1997, 1998 Ian Jackson
+#
+# This program 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 program 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.
+
+MAJOR= 1
+MINOR= 0
+LIBFILE= libadns.so.$(MAJOR).$(MINOR)
+
+CC=gcc $(WARNS) $(WERROR) $(OPTIMISE) $(DEBUG) $(XCFLAGS) $(DIRCFLAGS)
+DEBUG=-g
+OPTIMISE=-O2
+WARNS= -Wall -Wmissing-prototypes -Wwrite-strings -Wstrict-prototypes \
+ -Wcast-qual -Wpointer-arith
+WERROR=-Werror
+
+prefix= /usr/local
+bin_dir= $(prefix)/bin
+lib_dir= $(prefix)/lib
+include_dir= $(prefix)/include
+
+INSTALL= install -o 0 -g 0
+INSTALL_LIB= $(INSTALL) -m 755
+INSTALL_BIN= $(INSTALL) -m 755
+INSTALL_HDR= $(INSTALL) -m 644
+
+all: $(TARGETS)
+
+clean:
+ rm -f *.o
+
+distclean: clean
+ rm -f $(TARGETS) *~ ./#*# core *.orig *.rej
+# src/Makefile - library main Makefile
+#
# This file is part of adns, which is Copyright (C) 1997, 1998 Ian Jackson
#
# This program is free software; you can redistribute it and/or modify
# 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 $(WARNS) $(WERROR) $(OPTIMISE) $(DEBUG) $(XCFLAGS)
-DEBUG=-g
-OPTIMISE=-O2
-WARNS= -Wall -Wmissing-prototypes -Wwrite-strings -Wstrict-prototypes \
- -Wcast-qual -Wpointer-arith
-WERROR=-Werror
+TARGETS= libadns.a
-HCPPFLAGS:= $(foreach F, \
- gettimeofday select \
- socket fcntl connect close \
- sendto recvfrom read write writev \
-, -D$F=H$F)
+include ../settings.make
+include adns.make
-LIBOBJS= types.o event.o query.o reply.o general.o setup.o transmit.o parse.o
-HARNLOBJS= $(addsuffix _d.o, $(basename $(LIBOBJS)))
-ALLOBJS= $(LIBOBJS) $(HARNLOBJS) dtest.o hrecord.o hplayback.o hcommon.o
-AUTOCSRCS= harness.h hrecord.c hcommon.c
+install:
-TARGETS= dtest hplayback hrecord
+ALLOBJS= $(LIBOBJS)
-all: $(TARGETS)
+libadns.a: $(LIBOBJS)
+ rm -f $@
+ $(AR) cqsv $@ $(LIBOBJS)
-hrecord: dtest.o hrecord.o hcommon.o $(HARNLOBJS)
-hplayback: dtest.o hplayback.o hcommon.o $(HARNLOBJS)
-
-dtest: dtest.o $(LIBOBJS)
-
-%_d.o: %.c
- $(CC) $(HCPPFLAGS) -c -g -o $@ $<
-
-%:: %.m4 hmacros.i4 hsyscalls.i4
- m4 -P $< >$@-a.new
- sed -e 's/hm_comma/,/g; s/hm_squote/'\''/g; /^[ ]*$$/d' <$@-a.new >$@-b.new
- @mv -f $@-b.new $@; rm -f $@-a.new
-
-.PRECIOUS: $(AUTOCSRCS)
-
-clean:
- rm -f *.o
-
-realclean: clean
- rm -f $(TARGETS) *~ ./#*# core *.orig *.rej
-
-hrecord.o hcommon.o: adns.h internal.h harness.h
-$(HARNLOBJS): adns.h internal.h
-$(LIBOBJS): adns.h internal.h
-dtest.o: adns.h
+$(LIBOBJS): adns.h internal.h
+# src/Makefile - library main Makefile
+#
# This file is part of adns, which is Copyright (C) 1997, 1998 Ian Jackson
#
# This program is free software; you can redistribute it and/or modify
# 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 $(WARNS) $(WERROR) $(OPTIMISE) $(DEBUG) $(XCFLAGS)
-DEBUG=-g
-OPTIMISE=-O2
-WARNS= -Wall -Wmissing-prototypes -Wwrite-strings -Wstrict-prototypes \
- -Wcast-qual -Wpointer-arith
-WERROR=-Werror
+TARGETS= libadns.a
-HCPPFLAGS:= $(foreach F, \
- gettimeofday select \
- socket fcntl connect close \
- sendto recvfrom read write writev \
-, -D$F=H$F)
+include ../settings.make
+include adns.make
-LIBOBJS= types.o event.o query.o reply.o general.o setup.o transmit.o parse.o
-HARNLOBJS= $(addsuffix _d.o, $(basename $(LIBOBJS)))
-ALLOBJS= $(LIBOBJS) $(HARNLOBJS) dtest.o hrecord.o hplayback.o hcommon.o
-AUTOCSRCS= harness.h hrecord.c hcommon.c
+install:
-TARGETS= dtest hplayback hrecord
+ALLOBJS= $(LIBOBJS)
-all: $(TARGETS)
+libadns.a: $(LIBOBJS)
+ rm -f $@
+ $(AR) cqsv $@ $(LIBOBJS)
-hrecord: dtest.o hrecord.o hcommon.o $(HARNLOBJS)
-hplayback: dtest.o hplayback.o hcommon.o $(HARNLOBJS)
-
-dtest: dtest.o $(LIBOBJS)
-
-%_d.o: %.c
- $(CC) $(HCPPFLAGS) -c -g -o $@ $<
-
-%:: %.m4 hmacros.i4 hsyscalls.i4
- m4 -P $< >$@-a.new
- sed -e 's/hm_comma/,/g; s/hm_squote/'\''/g; /^[ ]*$$/d' <$@-a.new >$@-b.new
- @mv -f $@-b.new $@; rm -f $@-a.new
-
-.PRECIOUS: $(AUTOCSRCS)
-
-clean:
- rm -f *.o
-
-realclean: clean
- rm -f $(TARGETS) *~ ./#*# core *.orig *.rej
-
-hrecord.o hcommon.o: adns.h internal.h harness.h
-$(HARNLOBJS): adns.h internal.h
-$(LIBOBJS): adns.h internal.h
-dtest.o: adns.h
+$(LIBOBJS): adns.h internal.h
--- /dev/null
+# src/adns.make - library definitions, including list of object files
+#
+# This file is part of adns, which is Copyright (C) 1997, 1998 Ian Jackson
+#
+# This program 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 program 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.
+
+LIBOBJS= types.o event.o query.o reply.o general.o setup.o transmit.o parse.o