diff -ruN flexbackup.submitted/Makefile flexbackup/Makefile --- flexbackup.submitted/Makefile 2008-07-25 14:14:14.000000000 -0400 +++ flexbackup/Makefile 2008-07-25 13:34:44.000000000 -0400 @@ -15,13 +15,12 @@ MAINTAINER= mva@sysfault.org COMMENT= Perl-based flexible backup system that can use dump/afio/cpio/tar/star -MAKE_ARGS= PERLPATH=${PERL} CONFDIR=${PREFIX} \ - CONFFILE=${PREFIX}/etc/flexbackup.conf -CONFDIR= ${PREFIX} +MAKE_ARGS= PERLPATH=${PERL} CONFFILE=${PREFIX}/etc/flexbackup.conf USE_PERL5= yes -PKGMESSAGE= ${WRKDIR}/pkg-message +SUB_FILES+= pkg-message +PLIST_SUB+= ECHO_MSG=${ECHO_MSG} OPTIONS= AFIO "Enable afio support" Off \ BUFFER "Enable buffer support" Off \ @@ -69,22 +68,22 @@ @${REINPLACE_CMD} -e 's|%%TAR_CMD%%|'${TAR_CMD}'|g' \ ${WRKSRC}/flexbackup.conf -post-configure: - @${SED} -e 's|%%PREFIX%%|${PREFIX}|g' -e 's|%%CONFDIR%%|${CONFDIR}|g' \ - ${.CURDIR}/pkg-message > ${PKGMESSAGE} - do-install: - ${INSTALL_SCRIPT} ${WRKSRC}/fb.install ${PREFIX}/bin/flexbackup - ${INSTALL_DATA} ${WRKSRC}/flexbackup.conf ${PREFIX}/etc/flexbackup.conf.sample - ${INSTALL_MAN} ${WRKSRC}/flexbackup.1 ${MAN1PREFIX}/man/man1 - ${INSTALL_MAN} ${WRKSRC}/flexbackup.conf.5 ${MAN5PREFIX}/man/man5 + @${INSTALL_SCRIPT} ${WRKSRC}/fb.install ${PREFIX}/bin/flexbackup + @${INSTALL_DATA} ${WRKSRC}/flexbackup.conf ${PREFIX}/etc/flexbackup.conf.sample + @if [ ! -f ${PREFIX}/etc/flexbackup.conf ]; then \ + ${INSTALL_DATA} ${WRKSRC}/flexbackup.conf ${PREFIX}/etc; \ + else \ + ${ECHO_MSG} "====> Customized ${PREFIX}/etc/flexbackup.conf has not been overwritten"; \ + fi + @${INSTALL_MAN} ${WRKSRC}/flexbackup.1 ${MAN1PREFIX}/man/man1 + @${INSTALL_MAN} ${WRKSRC}/flexbackup.conf.5 ${MAN5PREFIX}/man/man5 + +DOCLIST= CHANGES CREDITS README TODO faq.html post-install: .if !defined(NOPORTDOCS) - @${MKDIR} ${DOCSDIR} -.for docfile in CHANGES CREDITS README TODO faq.html - ${INSTALL_DATA} ${WRKSRC}/${docfile} ${DOCSDIR} -.endfor + @cd ${WRKSRC} && ${COPYTREE_SHARE} "${DOCLIST}" ${DOCSDIR} .endif @${CAT} ${PKGMESSAGE} diff -ruN flexbackup.submitted/files/pkg-message.in flexbackup/files/pkg-message.in --- flexbackup.submitted/files/pkg-message.in 1969-12-31 19:00:00.000000000 -0500 +++ flexbackup/files/pkg-message.in 2008-07-25 13:40:17.000000000 -0400 @@ -0,0 +1,29 @@ +--------------- Flexbackup Configuration Information --------------- + +Flexbackup needs to have its configuration file placed in +%%PREFIX%%/etc. A template copy of this configuration file +has been installed into + + %%PREFIX%%/etc/flexbackup.conf.sample + +Please copy this file to + + %%PREFIX%%/etc/flexbackup.conf + +if it hasn't been created automatically. Edit this file +appropriately on all machines where you will run flexbackup. + +NOTE: The flexbackup.conf file will not be removed or overwritten + by future package removals or upgrades once you have + customized it. + +*************************************************************** +** Changes have occurred in this file up to and including ** +** version 1.2.0! ** +*************************************************************** + +Also see %%PREFIX%%/share/doc/flexbackup/README +for more information on how to use flexbackup. Man pages have +also been written and included in this version of the port! + +-------------------------------------------------------------------- diff -ruN flexbackup.submitted/pkg-message flexbackup/pkg-message --- flexbackup.submitted/pkg-message 2003-10-27 10:04:42.000000000 -0500 +++ flexbackup/pkg-message 1969-12-31 19:00:00.000000000 -0500 @@ -1,23 +0,0 @@ ---------------------- Flexbackup Configuration Information -------------------- - -Flexbackup needs to have its configuration file placed in /etc. A template -copy of this configuration file has been installed into - - %%PREFIX%%/etc/flexbackup.conf.sample - -Please copy this file as - - %%CONFDIR%%/etc/flexbackup.conf - -(on all machines where you will run flexbackup) and edit appropriately for your -site configuration. - - **************************************************************************** - ** Changes have occurred in this file up to and including version 1.2.0! ** - **************************************************************************** - -Also see %%PREFIX%%/share/doc/flexbackup/README -for more information on how to use flexbackup. Man pages have also been written -and included in this version of the port! - -------------------------------------------------------------------------------- diff -ruN flexbackup.submitted/pkg-plist flexbackup/pkg-plist --- flexbackup.submitted/pkg-plist 2003-09-05 04:29:48.000000000 -0400 +++ flexbackup/pkg-plist 2008-07-25 13:29:26.000000000 -0400 @@ -1,5 +1,7 @@ bin/flexbackup +@unexec if cmp -s %D/etc/flexbackup.conf.sample %D/etc/flexbackup.conf; then rm -f %D/etc/flexbackup.conf; else %%ECHO_MSG%% "===> Customized %D/etc/flexbackup.conf has not been removed"; fi etc/flexbackup.conf.sample +@exec if [ ! -f %D/etc/flexbackup.conf ]; then cp -p %D/%F %B/flexbackup.conf; else %%ECHO_MSG%% "===> Customized %D/etc/flexbackup.conf has not been overwritten"; fi %%PORTDOCS%%%%DOCSDIR%%/CHANGES %%PORTDOCS%%%%DOCSDIR%%/CREDITS %%PORTDOCS%%%%DOCSDIR%%/README