Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 21 Apr 2006 21:06:08 +0300
From:      "\"Panagiotis Astithas\" <Panagiotis Astithas" <past@ebs.gr>
To:        "FreeBSD gnats submit" <FreeBSD-gnats-submit@FreeBSD.org>
Subject:   ports/96149: [patch] Make sysutils/bpm handle OPTIONS
Message-ID:  <1145642768.8599@ajax.ebs.gr>
Resent-Message-ID: <200604211810.k3LIAKr6083092@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         96149
>Category:       ports
>Synopsis:       [patch] Make sysutils/bpm handle OPTIONS
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Apr 21 18:10:20 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     Panagiotis Astithas
>Release:        FreeBSD 6.1-PRERELEASE i386
>Organization:
EBS Ltd. 
>Environment:


System: FreeBSD 6.1-PRERELEASE #0: Sat Apr  8 17:05:00 EEST 2006
    past@ajax.ebs.gr:/usr/obj/usr/src/sys/AJAX



>Description:


sysutils/bpm cannot handle ports with OPTIONS, since it launches a dialog process in a shell invisible to the user. This makes the operation appear like halted. This patch is probably the simplest solution to the OPTIONS handling problem. Using gdialog (from x11/zenity) we get a popup window with the specified options, although without correct initial values. Nevertheless, this way the user has a chance to build or upgrade a port without the process hanging in the background, waiting for user input, making bpm usable for every use case I've come across. 


>How-To-Repeat:


Try to use bpm to build/update a port that has OPTIONS in the Makefile.


>Fix:


--- bpm.patch begins here ---
diff -ruN /usr/ports/sysutils/bpm/Makefile myports/bpm/Makefile
--- /usr/ports/sysutils/bpm/Makefile	Fri Dec 30 08:06:54 2005
+++ myports/bpm/Makefile	Sun Apr  2 14:13:23 2006
@@ -7,7 +7,7 @@
 
 PORTNAME=	bpm
 PORTVERSION=	0.4.1b
-PORTREVISION=	9
+PORTREVISION=	10
 CATEGORIES=	sysutils
 MASTER_SITES=	http://www.meowfishies.com/code/bpm/
 EXTRACT_SUFX=	.tgz
@@ -16,6 +16,7 @@
 COMMENT=	A graphical BSD ports collection manager
 
 RUN_DEPENDS=	portupgrade:${PORTSDIR}/sysutils/portupgrade
+RUN_DEPENDS=	gdialog:${PORTSDIR}/x11/zenity
 
 USE_X_PREFIX=	yes
 USE_GNOME=	gtk20 desktopfileutils
diff -ruN /usr/ports/sysutils/bpm/files/patch-src::install.c myports/bpm/files/patch-src::install.c
--- /usr/ports/sysutils/bpm/files/patch-src::install.c	Thu Jan  1 02:00:00 1970
+++ myports/bpm/files/patch-src::install.c	Sun Apr  2 14:14:18 2006
@@ -0,0 +1,19 @@
+--- src/install.c.orig	Sun Apr  2 14:09:25 2006
++++ src/install.c	Sun Apr  2 14:12:03 2006
+@@ -958,6 +958,8 @@
+ 	av[ac++] = "SU_CMD=" SU_CMD;
+ 	av[ac++] = "-M";
+ 	av[ac++] = "FETCH_CMD=" FETCH_CMD;
++	av[ac++] = "-M";
++	av[ac++] = "DIALOG=gdialog";
+ 	av[ac++] = "-s";
+ 	av[ac++] = "-S";
+ 	av[ac++] = SU_CMD " '%s'";
+@@ -971,6 +973,7 @@
+ 	av[ac++] = "make";
+ 	av[ac++] = "SU_CMD=" SU_CMD;
+ 	av[ac++] = "FETCH_CMD=" FETCH_CMD;
++	av[ac++] = "DIALOG=gdialog";
+ 
+ 	if (iadp->ia_action == INSTACT_PACKAGE)
+ 	{
--- bpm.patch ends here ---



>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1145642768.8599>