# Makefile for Amanda tape library. INCLUDES = -I$(top_builddir)/common-src \ -I$(top_srcdir)/common-src lib_LTLIBRARIES = libamtape.la LIB_EXTENSION = la sbin_PROGRAMS= ammt amdd amtapetype libamtape_la_SOURCES = output-file.c \ output-null.c \ output-rait.c \ output-tape.c \ tapeio.c libamtape_la_LDFLAGS = -release $(VERSION) ### # Because libamanda includes routines (e.g. regex) provided by some system # libraries, and because of the way libtool sets up the command line, we # need to list libamanda twice here, first to override the system library # routines, and second to pick up any references in the other libraries. ### LDADD = ../common-src/libamanda.$(LIB_EXTENSION) \ libamtape.$(LIB_EXTENSION) \ ../common-src/libamanda.$(LIB_EXTENSION) # used for testing only TEST_PROGS = amtapeio EXTRA_PROGRAMS = $(TEST_PROGS) CLEANFILES = *.test.c amtapetype_SOURCES = tapetype.c noinst_HEADERS = \ output-file.h \ output-null.h \ output-rait.h \ output-tape.h \ tapeio.h install-exec-hook: @list="$(sbin_PROGRAMS) $(sbin_SCRIPTS)"; \ for p in $$list; do \ pa=$(DESTDIR)$(sbindir)/`echo $$p|sed '$(transform)'`; \ echo chown $(BINARY_OWNER) $$pa; \ chown $(BINARY_OWNER) $$pa; \ echo chgrp $(SETUID_GROUP) $$pa; \ chgrp $(SETUID_GROUP) $$pa; \ done @list="$(libexec_PROGRAMS) $(libexec_SCRIPTS)"; \ for p in $$list; do \ pa=$(DESTDIR)$(libexecdir)/`echo $$p|sed '$(transform)'`; \ echo chown $(BINARY_OWNER) $$pa; \ chown $(BINARY_OWNER) $$pa; \ echo chgrp $(SETUID_GROUP) $$pa; \ chgrp $(SETUID_GROUP) $$pa; \ done amtapeio_SOURCES = amtapeio.test.c amtapeio_LDADD = ../common-src/libamanda.$(LIB_EXTENSION) \ libamtape.$(LIB_EXTENSION) \ ../common-src/libamanda.$(LIB_EXTENSION) amtapeio.test.c: $(srcdir)/tapeio.c echo '#define TEST' >$@ echo '#include "$<"' >>$@ %.test.c: $(srcdir)/%.c echo '#define TEST' >$@ echo '#include "$<"' >>$@ tapetype: @echo "Use amtapetype instead"