From owner-freebsd-ports-bugs@FreeBSD.ORG Sun Oct 12 08:50:03 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 06F851065687 for ; Sun, 12 Oct 2008 08:50: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 D825E8FC2E for ; Sun, 12 Oct 2008 08:50:02 +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 m9C8o2o1063336 for ; Sun, 12 Oct 2008 08:50:02 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.2/8.14.1/Submit) id m9C8o2lS063335; Sun, 12 Oct 2008 08:50:02 GMT (envelope-from gnats) Resent-Date: Sun, 12 Oct 2008 08:50:02 GMT Resent-Message-Id: <200810120850.m9C8o2lS063335@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Stan Behrens Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 270D91065693 for ; Sun, 12 Oct 2008 08:44:41 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id 15F098FC1E for ; Sun, 12 Oct 2008 08:44:41 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.3/8.14.3) with ESMTP id m9C8ieZ4018004 for ; Sun, 12 Oct 2008 08:44:40 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.3/8.14.3/Submit) id m9C8iec9018003; Sun, 12 Oct 2008 08:44:40 GMT (envelope-from nobody) Message-Id: <200810120844.m9C8iec9018003@www.freebsd.org> Date: Sun, 12 Oct 2008 08:44:40 GMT From: Stan Behrens To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: ports/128028: Ports-Script do not recognize dialog-return-value X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Oct 2008 08:50:03 -0000 >Number: 128028 >Category: ports >Synopsis: Ports-Script do not recognize dialog-return-value >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sun Oct 12 08:50:02 UTC 2008 >Closed-Date: >Last-Modified: >Originator: Stan Behrens >Release: 7.1 Beta >Organization: >Environment: FreeBSD 7.1-BETA FreeBSD 7.1-BETA #0: Sun Sep 7 13:49:18 UTC 2008 root@logan.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC i386 >Description: Hi, a recently portsnap'ed ports-tree does not recognize a -1 return (failure) of dialog, so if your terminal is to small, dialog will die and return 255 (-1) which should then let return make config something other than zero. Bye. >How-To-Repeat: run your favorite terminal-emulator, smaller it and type: cd /usr/ports/ports-mgmt/portupgrade && make config-recursive; echo $? and it will give you: ===> Setting user-specified options for portupgrade-2.4.6,2 and dependencies cd /usr/ports/ports-mgmt/portupgrade && make config; ===> Options unchanged cd /usr/ports/lang/ruby18 && make config; ===> Options unchanged 0 >Fix: THIS IS A BAD PATCH: Because the return-value this ignored too! (Block starts with -@if), unfortunately my make-skill are limited. Patch attached with submission follows: --- /usr/ports/Mk/bsd.port.mk.orig 2008-10-12 10:25:34.000000000 +0000 +++ /usr/ports/Mk/bsd.port.mk 2008-10-12 10:39:20.000000000 +0000 @@ -5891,9 +5891,15 @@ ${SH} -c "${DIALOG} --checklist \"Options for ${PKGNAME:C/-([^-]+)$/ \1/}\" 21 70 15 $${DEFOPTIONS} 2> $${TMPOPTIONSFILE}"; \ status=$$?; \ if [ $${status} -ne 0 ] ; then \ + if [ $${status} -eq 255 ] ; then \ + ${ECHO_MSG} "===> Failed to set Options: "; \ + ${CAT} $${TMPOPTIONSFILE}; \ + exit 1; \ + else \ + ${ECHO_MSG} "===> Options unchanged"; \ + exit 0; \ + fi; \ ${RM} -f $${TMPOPTIONSFILE}; \ - ${ECHO_MSG} "===> Options unchanged"; \ - exit 0; \ fi; \ if [ ! -e ${TMPOPTIONSFILE} ]; then \ ${ECHO_MSG} "===> No user-specified options to save for ${PKGNAME}"; \ >Release-Note: >Audit-Trail: >Unformatted: