From: Justin Erenkrantz Date: Fri, 30 Sep 2005 13:01:39 +0000 (+0000) Subject: Use rsync to install manual and htdocs to speed up installation times. X-Git-Tag: 2.3.0~2928 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c2a9a985f8c19afe928e1b00160c3f5224956c25;p=thirdparty%2Fapache%2Fhttpd.git Use rsync to install manual and htdocs to speed up installation times. * Makefile.in: Update install-man and install-htdocs to use rsync if available, otherwise fail back to current cp -rp and rm -rf .svn/ strategy. * configure.in: Look for rsync. * acinclude.m4: Include RSYNC in exported config_vars.mk (Incorporates suggestions on rsync flags from colm.) Reviewed by: colm, trawick (concept), niq (concept) git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@292718 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/Makefile.in b/Makefile.in index 4e04dd05680..6cfe9639adf 100644 --- a/Makefile.in +++ b/Makefile.in @@ -122,8 +122,12 @@ install-htdocs: else \ echo Installing HTML documents ; \ $(MKINSTALLDIRS) $(DESTDIR)$(htdocsdir) ; \ - test -d $(htdocs-srcdir) && (cd $(htdocs-srcdir) && cp -rp * $(DESTDIR)$(htdocsdir)) ; \ - cd $(DESTDIR)$(htdocsdir) && find . -name ".svn" -type d -print | xargs rm -rf 2>/dev/null || true; \ + if test -d $(htdocs-srcdir) && test "x$(RSYNC)" != "x" && test -x $(RSYNC) ; then \ + $(RSYNC) --exclude .svn -rlpt --numeric-ids $(htdocs-srcdir)/ $(DESTDIR)$(htdocsdir)/; \ + else \ + test -d $(htdocs-srcdir) && (cd $(htdocs-srcdir) && cp -rp * $(DESTDIR)$(htdocsdir)) ; \ + cd $(DESTDIR)$(htdocsdir) && find . -name ".svn" -type d -print | xargs rm -rf 2>/dev/null || true; \ + fi; \ fi install-error: @@ -201,8 +205,12 @@ install-man: @test -d $(DESTDIR)$(manualdir) || $(MKINSTALLDIRS) $(DESTDIR)$(manualdir) @cp -p $(top_srcdir)/docs/man/*.1 $(DESTDIR)$(mandir)/man1 @cp -p $(top_srcdir)/docs/man/*.8 $(DESTDIR)$(mandir)/man8 - @(cd $(top_srcdir)/docs/manual && cp -rp * $(DESTDIR)$(manualdir)) - @(cd $(DESTDIR)$(manualdir) && find . -name ".svn" -type d -print | xargs rm -rf 2>/dev/null ) || true + @if test "x$(RSYNC)" != "x" && test -x $(RSYNC) ; then \ + $(RSYNC) --exclude .svn -rlpt --numeric-ids $(top_srcdir)/docs/manual/ $(DESTDIR)$(manualdir)/; \ + else \ + cd $(top_srcdir)/docs/manual && cp -rp * $(DESTDIR)$(manualdir); \ + cd $(DESTDIR)$(manualdir) && find . -name ".svn" -type d -print | xargs rm -rf 2>/dev/null; \ + fi install-suexec: @if test -f $(builddir)/support/suexec; then \ diff --git a/acinclude.m4 b/acinclude.m4 index 34ae6726313..0998bf9f6bd 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -75,6 +75,7 @@ AC_DEFUN(APACHE_GEN_CONFIG_VARS,[ APACHE_SUBST(EXTRA_INCLUDES) APACHE_SUBST(LIBTOOL) APACHE_SUBST(SHELL) + APACHE_SUBST(RSYNC) APACHE_SUBST(MODULE_DIRS) APACHE_SUBST(MODULE_CLEANDIRS) APACHE_SUBST(PORT) diff --git a/configure.in b/configure.in index 18008727ab4..902bb133176 100644 --- a/configure.in +++ b/configure.in @@ -297,6 +297,7 @@ dnl ## Check for programs AC_PATH_PROG(RM, rm) AC_PATH_PROG(PKGCONFIG, pkg-config) +AC_PATH_PROG(RSYNC, rsync) AC_PROG_AWK AC_PROG_LN_S AC_CHECK_TOOL(RANLIB, ranlib, true)