sdiff is gone, but we still need it

This commit is contained in:
naddy 2003-07-23 19:12:18 +00:00
parent a184708e4f
commit b89dc0cf04
2 changed files with 42 additions and 5 deletions

View File

@ -1,8 +1,9 @@
# $OpenBSD: Makefile,v 1.7 2003/05/12 21:54:32 naddy Exp $
# $OpenBSD: Makefile,v 1.8 2003/07/23 19:12:18 naddy Exp $
COMMENT= "aids with merging configuration files during an upgrade"
DISTNAME= mergemaster-1.46
PKGNAME= ${DISTNAME}p0
CATEGORIES= sysutils
MAINTAINER= Christian Weisgerber <naddy@openbsd.org>
@ -15,12 +16,16 @@ PERMIT_DISTFILES_FTP= Yes
MASTER_SITES= http://grappa.unix-ag.uni-kl.de/~naddy/
# requires sdiff(1)
RUN_DEPENDS= ::textproc/gdiff
NO_BUILD= Yes
NO_REGRESS= Yes
WRKDIST= ${WRKDIR}/mergemaster
do-install:
@perl -pi -e 's:/etc(/mergemaster\.rc):${SYSCONFDIR}$$1:g' \
@perl -pi -e 's:\@SYSCONFDIR@:${SYSCONFDIR}:g;' \
-e 's:\@LOCALBASE@:${LOCALBASE}:g;' \
${WRKSRC}/mergemaster.sh ${WRKSRC}/mergemaster.8
${INSTALL_SCRIPT} ${WRKSRC}/mergemaster.sh ${PREFIX}/sbin/mergemaster
${INSTALL_MAN} ${WRKSRC}/mergemaster.8 ${PREFIX}/man/man8

View File

@ -1,6 +1,38 @@
$OpenBSD: patch-mergemaster_sh,v 1.6 2003/05/17 19:39:31 naddy Exp $
--- mergemaster.sh.orig Sat May 10 16:06:02 2003
+++ mergemaster.sh Sat May 17 13:22:34 2003
$OpenBSD: patch-mergemaster_sh,v 1.7 2003/07/23 19:12:18 naddy Exp $
--- mergemaster.sh.orig Sun May 11 00:06:02 2003
+++ mergemaster.sh Wed Jul 23 02:40:22 2003
@@ -10,7 +10,7 @@
# $FreeBSD: mergemaster.sh,v 1.46 2003/05/03 06:35:19 dougb Exp $
-PATH=/bin:/usr/bin:/usr/sbin
+PATH=/bin:/usr/bin:/usr/sbin:@LOCALBASE@/bin
display_usage () {
VERSION_NUMBER=`grep "[$]FreeBSD:" $0 | cut -d ' ' -f 4`
@@ -59,7 +59,7 @@ merge_loop () {
while [ "${MERGE_AGAIN}" = "yes" ]; do
# Prime file.merged so we don't blat the owner/group id's
cp -p "${COMPFILE}" "${COMPFILE}.merged"
- sdiff -o "${COMPFILE}.merged" --text --suppress-common-lines \
+ gsdiff -o "${COMPFILE}.merged" --text --suppress-common-lines \
--width=${SCREEN_WIDTH:-80} "${DESTDIR}${COMPFILE#.}" "${COMPFILE}"
INSTALL_MERGED=V
while [ "${INSTALL_MERGED}" = "v" -o "${INSTALL_MERGED}" = "V" ]; do
@@ -224,10 +224,10 @@ press_to_continue () {
#
TEMPROOT='/var/tmp/temproot'
-# Read /etc/mergemaster.rc first so the one in $HOME can override
+# Read @SYSCONFDIR@/mergemaster.rc first so the one in $HOME can override
#
-if [ -r /etc/mergemaster.rc ]; then
- . /etc/mergemaster.rc
+if [ -r @SYSCONFDIR@/mergemaster.rc ]; then
+ . @SYSCONFDIR@/mergemaster.rc
fi
# Read .mergemasterrc before command line so CLI can override
@@ -404,7 +404,7 @@ fi
# Define what CVS $Id tag to look for to aid portability.