From owner-freebsd-ports-bugs@FreeBSD.ORG Mon Mar 3 10:30:04 2008 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 71743106566C for ; Mon, 3 Mar 2008 10:30:03 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 58B958FC14 for ; Mon, 3 Mar 2008 10:30:03 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.2/8.14.2) with ESMTP id m23AU3AN018752 for ; Mon, 3 Mar 2008 10:30:03 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.2/8.14.1/Submit) id m23AU3eh018740; Mon, 3 Mar 2008 10:30:03 GMT (envelope-from gnats) Date: Mon, 3 Mar 2008 10:30:03 GMT Message-Id: <200803031030.m23AU3eh018740@freefall.freebsd.org> To: freebsd-ports-bugs@FreeBSD.org From: Justin Head Cc: Subject: Re: ports/121050: New port: sysutils/heartbeat2 Linux High-Availability Daemon X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Justin Head List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Mar 2008 10:30:04 -0000 The following reply was made to PR ports/121050; it has been noted by GNATS. From: Justin Head To: bug-followup@FreeBSD.org, ports@encarnate.com Cc: Subject: Re: ports/121050: New port: sysutils/heartbeat2 Linux High-Availability Daemon Date: Mon, 03 Mar 2008 04:24:41 -0600 Found a nasty bug that would remove your active cluster config if you deinstalled and then reinstalled. This fixes it plus a small plist change. --- diffs begins here --- # diff -ruN Makefile.orig Makefile --- Makefile.orig 2007-12-26 22:42:39.000000000 -0600 +++ Makefile 2008-03-03 04:01:08.000000000 -0600 @@ -46,6 +46,7 @@ --disable-dopd SUB_FILES= pkg-install pkg-message +SUB_LIST= BATCH=${BATCH} PKGDEINSTALL= ${PKGINSTALL} @@ -58,6 +59,10 @@ .include +.if !defined(BATCH) +BATCH=NO +.endif + .if defined(WITH_MGMT) BUILD_DEPENDS+= swig:${PORTSDIR}/devel/swig11 RUN_DEPENDS+= py-gtk2:${PORTSDIR}/x11-toolkits/py-gtk2 @@ -91,7 +96,7 @@ .endif pre-install: - @LOCALBASE=${LOCALBASE} ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL + @${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL post-install: @if [ ! -f ${PREFIX}/etc/ha.d/authkeys ]; then \ @@ -132,6 +137,6 @@ @${CAT} ${PKGMESSAGE} post-deinstall: - @LOCALBASE=${LOCALBASE} ${SH} ${PKGINSTALL} ${PKGNAME} DEINSTALL + @${SH} ${PKGINSTALL} ${PKGNAME} DEINSTALL .include # diff -ruN files/pkg-install.in.orig files/pkg-install.in --- files/pkg-install.in.orig 2007-12-09 04:57:21.000000000 -0600 +++ files/pkg-install.in 2008-03-03 04:10:46.000000000 -0600 @@ -5,7 +5,7 @@ UID=275 GID=${UID} -LOCALBASE=${LOCALBASE:-%%LOCALBASE%%} +BATCH=${BATCH:-%%BATCH%%} case $2 in @@ -96,15 +96,35 @@ # Cleanup /var environment echo -n "Cleaning up /var environment... " - test -d /var/run/heartbeat && \ - rm -r /var/run/heartbeat - test -d /var/lib/heartbeat && \ - rm -r /var/lib/heartbeat - test -f /var/lock/subsys/heartbeat && \ - rm /var/lock/subsys/heartbeat - test -f /var/run/heartbeat.pid && \ - rm /var/run/heartbeat.pid - echo "DONE" + + if [ "$BATCH" = "NO" ]; then + echo "" + default="n" + read -p " Remove runtime files (cluster config)? [yn]: " answer + + case "$answer" in + [Yy]*) answer=y ;; + [Nn]*) answer=n ;; + *) answer=n ;; + esac + + if [ "$answer" = "y" ]; then + echo -n " Removing runtime files... " + test -d /var/run/heartbeat && \ + rm -r /var/run/heartbeat + test -d /var/lib/heartbeat && \ + rm -r /var/lib/heartbeat + test -f /var/lock/subsys/heartbeat && \ + rm /var/lock/subsys/heartbeat + test -f /var/run/heartbeat.pid && \ + rm /var/run/heartbeat.pid + echo "DONE" + else + echo "Preserving runtime files... DONE" + fi + else + echo "NA" + fi echo -e "\n\n" # diff -ruN pkg-plist.orig pkg-plist --- pkg-plist.orig 2007-12-26 22:23:53.000000000 -0600 +++ pkg-plist 2008-03-03 04:08:53.000000000 -0600 @@ -444,6 +444,9 @@ lib/stonith/plugins/stonith2/apcmaster.a lib/stonith/plugins/stonith2/apcmaster.la lib/stonith/plugins/stonith2/apcmaster.so +lib/stonith/plugins/stonith2/apcmastersnmp.a +lib/stonith/plugins/stonith2/apcmastersnmp.la +lib/stonith/plugins/stonith2/apcmastersnmp.so lib/stonith/plugins/stonith2/apcsmart.a lib/stonith/plugins/stonith2/apcsmart.la lib/stonith/plugins/stonith2/apcsmart.so @@ -453,6 +456,9 @@ lib/stonith/plugins/stonith2/cyclades.a lib/stonith/plugins/stonith2/cyclades.la lib/stonith/plugins/stonith2/cyclades.so +lib/stonith/plugins/stonith2/drac3.a +lib/stonith/plugins/stonith2/drac3.la +lib/stonith/plugins/stonith2/drac3.so lib/stonith/plugins/stonith2/external.a lib/stonith/plugins/stonith2/external.la lib/stonith/plugins/stonith2/external.so