rpm/librsync/Makefile.am

230 lines
5.8 KiB
Makefile

## Process this file with automake to produce Makefile.in
# Copyright (C) 2000, 2001 by Martin Pool <mbp@samba.org>
# Id: Makefile.am,v 1.111 2001/08/08 05:43:07 mbp Exp
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public License
# as published by the Free Software Foundation; either version 2.1 of
# the License, 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
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this program; if not, write to the Free Software
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
# Thus spake the master programmer:
#
# ``When the program is being tested, it
# is too late to make design changes.''
SUBDIRS = popt
lib_LTLIBRARIES = librsync.la
librsync_la_SOURCES = \
base64.c \
buf.c buf.h \
checksum.c checksum.h \
command.c command.h \
delta.c \
emit.c emit.h \
fileutil.c fileutil.h \
hex.c \
job.c job.h \
mdfour.c \
mksum.c \
msg.c \
netint.c netint.h \
patch.c \
protocol.h \
prototab.c prototab.h \
readsums.c \
rsync.h \
scoop.c \
search.c search.h \
stats.c \
stream.c stream.h \
sumset.c sumset.h \
trace.c trace.h \
tube.c \
types.h \
util.c util.h \
version.c \
whole.c whole.h
man_MANS = rdiff.1 librsync.3
# See libversions.txt and the libtool manual for an explanation of the
# library versioning
librsync_la_LDFLAGS = -version-info 1:1:0
# TODO: If we ever care enough, build a second library containing only
# the code necessary to be a client, and not stuff for encoding. At
# the moment it doesn't seem worth the additional compilation time to
# do both, and I don't know if anyone will care if they're just shared
# libraries anyhow.
# NB: tests should exit with code 77 if they can't be run but haven't
# failed.
# Generally these tests should be ordered so that more basic tests
# are run first.
TESTS_ENVIRONMENT = $(SH) $(srcdir)/driver.sh
test_scripts = signature.test mutate.test sources.test \
isprefix.test delta.test mksum.test triple.test changes.test
# These are extra documents to be included in the source tarball.
extra_docs = README.CVS libversions.txt
# These ones are not tests, but are useful in watching the code run
# through.
try_scripts =
TESTS = $(test_scripts)
noinst_SCRIPTS = \
$(test_scripts) \
driver.sh \
mkprototab.pl \
mutate.pl \
$(try_scripts)
test_data = changes.input \
changes.input/01.in \
changes.input/02.in \
changes.input/03.in \
changes.input/04.in \
delta.input \
delta.input/01.delta \
delta.input/01.expect \
delta.input/02.delta \
delta.input/02.expect \
delta.input/03.delta \
delta.input/03.expect \
mdfour.input \
mdfour.input/01.expect \
mdfour.input/01.data \
mksum.input \
mksum.input/COPYING.sig \
triple.input \
triple.input/copying.in \
triple.input/half.in \
triple.input/hello.in \
triple.input/zero.in \
signature.input/01.in \
signature.input/01.sig \
dot
CLEANFILES = tmp-test-*.d/* tmp-try-*.d/*
# Autogenerated by a script
prototab.c prototab.h: $(srcdir)/mkprototab.pl
perl $(srcdir)/mkprototab.pl prototab.c prototab.h
EXTRA_DIST = $(noinst_SCRIPTS) $(test_data) $(extra_docs) $(man_MANS) \
librsync.spec
include_HEADERS = rsync.h
# This is the default for any programs that don't specify a
# preference.
LDADD = librsync.la $(LIBOBJS)
# Eventually we might want to install some of these into system
# directories, but they're pretty obscure and it's hard to imagine any
# end users wanting to run them. So for the time being they are not
# installed.
bin_PROGRAMS = rdiff
rdiff_SOURCES = rdiff.c isprefix.c isprefix.h rsync.h trace.h
rdiff_LDADD = @BUILD_POPT@ librsync.la
rdiff_DEPENDENCIES = @BUILD_POPT@ librsync.la
check_PROGRAMS = isprefix.driver
isprefix_driver_SOURCES = isprefix.driver.c \
isprefix.c isprefix.h
isprefix_driver_LDADD = $(LIBOBJS)
popt/libpopt.a:
(cd popt && $(MAKE) $(AM_MAKEFLAGS) libpopt.a)
.PHONY: check_programs
check_programs: $(check_PROGRAMS)
# Doxygen API documentation
sites=front.linuxcare.com.au:/var/www/projects/rproxy \
rproxy.sourceforge.net:/home/groups/rproxy/htdocs \
rproxy.samba.org:/space/httpd/rproxy/htdocs
.PHONY: do-doxy upload-doxy
html/index.html latex/refman.pdf latex/refman.ps.gz do-doxy:
doxygen
(cd latex && make refman.ps refman.pdf && gzip -9vf refman.ps)
upload-doxy: html/index.html latex/refman.pdf latex/refman.ps.gz
for i in $(sites); do \
rsync -avz --delete --exclude '*~' \
html/ latex/refman.pdf latex/refman.ps.gz \
./rproxy-small-logo.png $$i/doxygen/librsync; \
done
converted_men = man_librsync_3.html man_librsync_3.ps \
man_rdiff_1.html man_rdiff_1.ps
man_%_1.ps: %.1
groff -mandoc -Tps $< >$@
man_%_3.ps: %.3
groff -mandoc -Tps $< >$@
man_%_1.html: %.1
groff -mandoc -Thtml $< >$@
man_%_3.html: %.3
groff -mandoc -Thtml $< >$@
man_%_1.txt: %.1
groff -mandoc -Tlatin1 $< >$@
man_%_3.txt: %.3
groff -mandoc -Tlatin1 $< >$@
upload-men: $(converted_men)
for i in $(sites); do \
rsync -avz --delete $(converted_men) $(man_MANS) $$i/man; \
done
upload-news: NEWS
for i in $(sites); do \
rsync -avz --delete $(srcdir)/NEWS $$i/librsync-NEWS; \
done
# Cater to people who prefer the name 'make test'
.PHONY: test
test: check;
# test commands for maintainer use:
/tmp/food:
find /usr/include -type f -exec cat {} \; >$@
/tmp/doof: /tmp/food
tr '[a-zA-Z0123456789]' '[A-Za-z9876543210]' </tmp/food >$@
/tmp/fodo: /tmp/food
tr 'z' 'Z' </tmp/food >$@