From 9e8331c95c94003458ec0a9f9a750bee9f25fdbd Mon Sep 17 00:00:00 2001 From: Karl Ramm Date: Thu, 31 Jan 2013 08:02:34 -0500 Subject: Test the low-level code in uloc.c Also, tweak the debian build infrastructure so that we can pass in arbitrary CFLAGS. New program test_server that links with the non-main.c parts of the server. Currently only (as above) tests the low-level bits of uloc.c. --- server/Makefile.in | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) (limited to 'server/Makefile.in') diff --git a/server/Makefile.in b/server/Makefile.in index b2a0600..a23b509 100644 --- a/server/Makefile.in +++ b/server/Makefile.in @@ -36,15 +36,22 @@ LDFLAGS=@LDFLAGS@ LIBS=${LIBZEPHYR} @LIBS@ -lcom_err HESIOD_LIBS=@HESIOD_LIBS@ -OBJS= zsrv_err.o access.o acl_files.o bdump.o class.o client.o common.o \ - dispatch.o kstuff.o main.o server.o subscr.o timer.o uloc.o \ +NMOBJS= zsrv_err.o access.o acl_files.o bdump.o class.o client.o common.o \ + dispatch.o kstuff.o global.o server.o subscr.o timer.o uloc.o \ zstring.o realm.o version.o utf8proc.o -all: zephyrd zephyrd.8 +OBJS= main.o $(NMOBJS) + +TESTOBJS = test_server.o $(NMOBJS) + +all: zephyrd zephyrd.8 test_server zephyrd: ${OBJS} ${LIBZEPHYR} ${LIBTOOL} --mode=link ${CC} ${LDFLAGS} -o $@ ${OBJS} ${LIBS} ${HESIOD_LIBS} +test_server: $(TESTOBJS) + ${LIBTOOL} --mode=link ${CC} ${LDFLAGS} -o $@ ${TESTOBJS} ${LIBS} ${HESIOD_LIBS} + zsrv_err.h: zsrv_err.c zsrv_err.c: zsrv_err.et compile_et ${srcdir}/zsrv_err.et @@ -56,7 +63,8 @@ zephyrd.8: ${srcdir}/zephyrd.8.in Makefile ${editman} ${srcdir}/$@.in > $@.tmp mv $@.tmp $@ -check: +check: test_server + ./test_server # No dependency on zephyrd, to avoid rebuilding version.o. install: zephyrd.8 zephyrd @@ -67,7 +75,7 @@ install: zephyrd.8 zephyrd ${DESTDIR}${sysconfdir}/zephyr clean: - ${LIBTOOL} --mode=clean rm -f zephyrd + ${LIBTOOL} --mode=clean rm -f zephyrd test_server rm -f ${OBJS} zsrv_err.[ch] rm -f zephyrd.8 -- cgit v1.2.3