GNUmakefile.in 665 Bytes
Newer Older
1 2 3
#
# Insert Copyright Here.
#
4 5 6 7
SRCDIR		= @srcdir@
TESTBED_SRCDIR	= @top_srcdir@
OBJDIR		= ..
SUBDIR		= tmcd
8

9
include $(OBJDIR)/Makeconf
10

11
all:	tmcd tmcc
12

13
include $(TESTBED_SRCDIR)/GNUmakerules
14 15

tmcd: tmcd.c
16
	$(CC) $(CFLAGS) -DTBDBNAME='"$(TBDBNAME)"' -g -o tmcd tmcd.c \
17 18 19 20 21 22 23 24 25 26 27
		-I/usr/local/include \
		$(LFLAGS) -L/usr/local/lib/mysql -lmysqlclient

tmcc: tmcc.c
	$(CC) $(CFLAGS) -g -o tmcc tmcc.c $(LFLAGS)

tmcc.c:	decls.h
tmcd.c:	decls.h

install:	all

28 29
install:	$(INSTALL_SBINDIR)/tmcd \
		$(INSTALL_SBINDIR)/tmcd.restart
30 31 32 33 34 35 36

$(INSTALL_BINDIR)/tmcd/%: %
	@echo "Installing $<"
	-mkdir -p $(INSTALL_BINDIR)/tmcd
	$(INSTALL_PROGRAM) $< $@

clean: 
37
	rm -f *.o core tmcd tmcc