From owner-freebsd-ports-bugs@FreeBSD.ORG Tue Nov 29 12:30:39 2005 Return-Path: X-Original-To: freebsd-ports-bugs@hub.freebsd.org Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 861E816A43B for ; Tue, 29 Nov 2005 12:30:39 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id D51F443F3E for ; Tue, 29 Nov 2005 12:20:03 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id jATCK3Ot026818 for ; Tue, 29 Nov 2005 12:20:03 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.3/8.13.1/Submit) id jATCK3Vt026817; Tue, 29 Nov 2005 12:20:03 GMT (envelope-from gnats) Resent-Date: Tue, 29 Nov 2005 12:20:03 GMT Resent-Message-Id: <200511291220.jATCK3Vt026817@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, "Michael C. Shultz" Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4A51B16A41F for ; Tue, 29 Nov 2005 12:12:22 +0000 (GMT) (envelope-from ringworm01@gmail.com) Received: from vms042pub.verizon.net (vms042pub.verizon.net [206.46.252.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id 51DBA43D4C for ; Tue, 29 Nov 2005 12:12:21 +0000 (GMT) (envelope-from ringworm01@gmail.com) Received: from ringworm.mechee.com ([71.102.14.129]) by vms042.mailsrvcs.net (Sun Java System Messaging Server 6.2-4.02 (built Sep 9 2005)) with ESMTPA id <0IQP000FQTWIUD20@vms042.mailsrvcs.net> for FreeBSD-gnats-submit@freebsd.org; Tue, 29 Nov 2005 06:12:20 -0600 (CST) Received: by ringworm.mechee.com (Postfix, from userid 1001) id 9D7B2130C2B; Tue, 29 Nov 2005 04:12:18 -0800 (PST) Message-Id: <20051129121218.9D7B2130C2B@ringworm.mechee.com> Date: Tue, 29 Nov 2005 04:12:18 -0800 (PST) From: "Michael C. Shultz" To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: Subject: ports/89716: [MAINTAINER] update sysutils/portmanager X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: "Michael C. Shultz" List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 29 Nov 2005 12:30:39 -0000 >Number: 89716 >Category: ports >Synopsis: [MAINTAINER] update sysutils/portmanager >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: maintainer-update >Submitter-Id: current-users >Arrival-Date: Tue Nov 29 12:20:03 GMT 2005 >Closed-Date: >Last-Modified: >Originator: Michael C. Shultz >Release: FreeBSD 5.4-STABLE i386 >Organization: >Environment: System: FreeBSD ringworm.mechee.com 5.4-STABLE FreeBSD 5.4-STABLE #0: Fri Nov 25 15:08:09 PST 2005 root@ringworm.mechee.com:/usr5/obj/usr5/src/sys/RINGWORM5 i386 >Description: update sysutils/portmanager to 0.3.9_5 1. Fixes when adding a new port with portmanager, +CONTENTS files being corupted. 2. Improved logging of conflicting ports >How-To-Repeat: N/A >Fix: --- portmanager-0.3.9_5.diff begins here --- diff -ruN portmanager/Makefile portmanager-0.3.9_5/Makefile --- portmanager/Makefile Sun Nov 27 23:19:25 2005 +++ portmanager-0.3.9_5/Makefile Tue Nov 29 04:05:22 2005 @@ -7,7 +7,7 @@ PORTNAME= portmanager PORTVERSION= 0.3.9 -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES= sysutils MASTER_SITES= http://portmanager.sunsite.dk/distfiles/ \ ${MASTER_SITE_SOURCEFORGE} diff -ruN portmanager/files/patch-0.3.9_5 portmanager-0.3.9_5/files/patch-0.3.9_5 --- portmanager/files/patch-0.3.9_5 Wed Dec 31 16:00:00 1969 +++ portmanager-0.3.9_5/files/patch-0.3.9_5 Tue Nov 29 04:05:05 2005 @@ -0,0 +1,232 @@ +diff -ruN ../0.3.9_4/libMGPM/src/MGPMrController.c ./libMGPM/src/MGPMrController.c +--- ../0.3.9_4/libMGPM/src/MGPMrController.c Sun Nov 27 21:47:15 2005 ++++ ./libMGPM/src/MGPMrController.c Tue Nov 29 03:03:01 2005 +@@ -163,7 +163,7 @@ + /* + * Need to check configDb for ignored ports and add them to ignoreDb here + */ +- MGPMrReadConfigure( property ); ++ MGPMrReadConfigure( property, " " ); + + while( fflush( stdout ) ); + if( property->buildDependsAreLeaves ) +@@ -180,7 +180,7 @@ + { + if( property->resume == 0 ) /* skip this if portmanager has upgraded/rebuilt its self */ + { +- MGPMrReadConfigure( property ); ++ MGPMrReadConfigure( property, " " ); + if( ( errorCode = MGPMrCreateAllUpdateStatusDb( property ) ) ) + { + fprintf( stdout, "%s %s error: %s returned errorCode %d\n", id, PACKAGE_VERSION, +@@ -241,7 +241,7 @@ + property->pmMode = 1; /* fake like we are in single port update */ + if( property->resume == 0 ) + { +- MGPMrReadConfigure( property ); ++ MGPMrReadConfigure( property, " " ); + if( ( errorCode = MGPMrCreateAllUpdateStatusDb( property ) ) ) + { + fprintf( stdout, "%s %s error: %s returned errorCode %d\n", id, PACKAGE_VERSION, +@@ -284,7 +284,7 @@ + */ + if( property->resume == 0 ) /* skip this if --resume */ + { +- MGPMrReadConfigure( property ); ++ MGPMrReadConfigure( property, " " ); + if( ( errorCode = MGPMrSinglePortCreateStatusDb( property, path ) ) ) + { + fprintf( stdout, "%s %s error: %s returned errorCode %d\n", id, PACKAGE_VERSION, "MGPMrSinglePortCreateStatusDb", errorCode ); +@@ -296,7 +296,7 @@ + } + while( 1 ) + { +- MGPMrReadConfigure( property ); ++ MGPMrReadConfigure( property, " " ); + if( ( errorCode = MGPMrStatus( property ) ) ) + { + fprintf( stdout, "%s %s error: %s returned errorCode %d\n", id, PACKAGE_VERSION, "MGPMrStatus", errorCode ); +@@ -492,7 +492,7 @@ + property->pmMode = 1; /* fake like we are in single port update */ + if( property->resume == 0 ) /* skip this if portmanager has upgraded/rebuilt its self */ + { +- MGPMrReadConfigure( property ); ++ MGPMrReadConfigure( property, " " ); + if( ( errorCode = MGPMrCreateAllUpdateStatusDb( property ) ) ) + { + fprintf( stdout, "%s %s error: %s returned errorCode %d\n", id, PACKAGE_VERSION, +@@ -502,7 +502,7 @@ + } + while( 1 ) + { +- MGPMrReadConfigure( property ); ++ MGPMrReadConfigure( property, " " ); + if( ( errorCode = MGPMrStatus( property ) ) ) + { + fprintf( stdout, "%s %s error: %s returned errorCode %d\n", id, PACKAGE_VERSION, "MGPMrStatus", errorCode ); +diff -ruN ../0.3.9_4/libMGPM/src/MGPMrPackageDepends.c ./libMGPM/src/MGPMrPackageDepends.c +--- ../0.3.9_4/libMGPM/src/MGPMrPackageDepends.c Sun Nov 27 21:47:15 2005 ++++ ./libMGPM/src/MGPMrPackageDepends.c Tue Nov 29 03:25:59 2005 +@@ -58,7 +58,7 @@ + + pkgDb = MGdbCreate( pkgDbFileName, "fieldPortName", "fieldPortDir", NULL ); + +- MGPMrReadConfigure( property ); ++ MGPMrReadConfigure( property, path ); + + if( ( errorCode = MGPMrSinglePortCreateStatusDb( property, path ) ) ) + { +@@ -101,11 +101,21 @@ + * Gaurentee that we get the name from /var/db/pkg/{port name} + */ + MGdbGoTop( property->installedPortsDb ); +- strcpy( portName, MGdbSeek( property->installedPortsDb, +- property->fieldInstalledPortsDbPortDir, +- portDir, +- property->fieldInstalledPortsDbPortName, +- exact ) ); ++ if( MGdbSeek( property->installedPortsDb, ++ property->fieldInstalledPortsDbPortDir, ++ portDir, ++ property->fieldInstalledPortsDbPortName, ++ exact ) ) ++ { ++ strcpy( portName, MGdbGet( property->installedPortsDb, ++ MGdbGetRecno( property->installedPortsDb ) - 1, ++ property->fieldInstalledPortsDbPortName ) ); ++ } ++ else ++ { ++ continue; ++ } ++ + /* + * Below is to prevent dupes instead of just fprinting portName & portDir + */ +diff -ruN ../0.3.9_4/libMGPM/src/MGPMrReadConfigure.c ./libMGPM/src/MGPMrReadConfigure.c +--- ../0.3.9_4/libMGPM/src/MGPMrReadConfigure.c Sun Nov 27 21:47:15 2005 ++++ ./libMGPM/src/MGPMrReadConfigure.c Tue Nov 29 03:26:30 2005 +@@ -56,7 +56,7 @@ + int rReadConfigureMergeRecords( structProperty* property, char* configDbFileName ); + int rReadConfigureParse( structProperty* property, char* configDbFileName, int flags ); + +-int MGPMrReadConfigure( structProperty* property ) ++int MGPMrReadConfigure( structProperty* property, char* newPortDir ) + { + FILE* fHandle = NULL; + FILE* pHandle = NULL; +@@ -130,6 +130,17 @@ + } + + rReadConfigureAwkConfigure( property, property->configConfFileName, property->configDbFileName ); ++ ++ /* ++ * Create a record for port that isn't installed yet if portmanager ++ * is being used to add a new port ++ */ ++ if( strlen( newPortDir ) > 1 ) ++ { ++ configDb = MGdbOpen( property->configDbFileName ); ++ MGdbAdd( configDb, newPortDir, " ", NULL ); ++ MGdbDestroy( configDb ); ++ } + + /* + * Is ruby installed? +diff -ruN ../0.3.9_4/libMGPM/src/MGPMrStatus.c ./libMGPM/src/MGPMrStatus.c +--- ../0.3.9_4/libMGPM/src/MGPMrStatus.c Sun Nov 27 21:47:15 2005 ++++ ./libMGPM/src/MGPMrStatus.c Mon Nov 28 14:00:00 2005 +@@ -328,13 +328,35 @@ + availablePortsDbPortDirPtr ); + while( fflush( stdout ) ); + +- MGdbAdd( property->oldPortsDb, +- availablePortsDbPortDirPtr, +- availablePortsDbPortNamePtr, +- "MISSING", +- availablePortsDbPortNamePtr, +- availablePortsDbPortDirPtr, +- NULL ); ++ MGdbGoTop( property->availableDependenciesDb ); ++ if( MGdbSeek( property->availableDependenciesDb, ++ property->fieldAvailableDependenciesDbDependencyDir, ++ availablePortsDbPortDirPtr, ++ property->fieldAvailableDependenciesDbDependencyDir, ++ exact ) ) ++ { ++ MGdbAdd( property->oldPortsDb, ++ availablePortsDbPortDirPtr, ++ availablePortsDbPortNamePtr, ++ "MISSING dependency of", ++ MGdbGet( property->availableDependenciesDb, ++ MGdbGetRecno( property->availableDependenciesDb ) - 1, ++ property->fieldAvailableDependenciesDbPortName ), ++ MGdbGet( property->availableDependenciesDb, ++ MGdbGetRecno( property->availableDependenciesDb ) - 1, ++ property->fieldAvailableDependenciesDbPortDir ), ++ NULL ); ++ } ++ else ++ { ++ MGdbAdd( property->oldPortsDb, ++ availablePortsDbPortDirPtr, ++ availablePortsDbPortNamePtr, ++ "MISSING", ++ availablePortsDbPortNamePtr, ++ availablePortsDbPortDirPtr, ++ NULL ); ++ } + } + } + availablePortsDbIDX++; +diff -ruN ../0.3.9_4/libMGPM/src/MGPMrUpdate.c ./libMGPM/src/MGPMrUpdate.c +--- ../0.3.9_4/libMGPM/src/MGPMrUpdate.c Sun Nov 27 21:47:15 2005 ++++ ./libMGPM/src/MGPMrUpdate.c Mon Nov 28 08:50:05 2005 +@@ -652,16 +652,32 @@ + } + case KEY_N: + { +- fprintf( stdout, "\nAdding %s %s to ignore list\n", oldPortName, oldPortDir ); ++ fprintf( stdout, ++ "\nAdding %s %s conflicts with installed port %s added to ignore list\n", ++ oldPortName, oldPortDir, localProperty.installedPortName ); + while( fflush( stdout ) ); ++ MGPMlogAdd( property, ++ oldPortName, ++ oldPortDir, ++ "conflicts with installed port ", ++ localProperty.installedPortName, ++ " added to ignore.db" ); + MGdbAdd( property->ignoreDb, oldPortDir, "conflicts with another port", NULL ); + rCleanUp( property, &localProperty ); + return(0); + } + case KEY_n: + { +- fprintf( stdout, "\nAdding %s %s to ignore list\n", oldPortName, oldPortDir ); ++ fprintf( stdout, ++ "\nAdding %s %s conflicts with installed port %s added to ignore list\n", ++ oldPortName, oldPortDir, localProperty.installedPortName ); + while( fflush( stdout ) ); ++ MGPMlogAdd( property, ++ oldPortName, ++ oldPortDir, ++ "conflicts with installed port ", ++ localProperty.installedPortName, ++ " added to ignore.db" ); + MGdbAdd( property->ignoreDb, oldPortDir, "conflicts with another port", NULL ); + rCleanUp( property, &localProperty ); + return(0); +diff -ruN ../0.3.9_4/libMGPM/src/libMGPM.h ./libMGPM/src/libMGPM.h +--- ../0.3.9_4/libMGPM/src/libMGPM.h Sun Nov 27 21:47:15 2005 ++++ ./libMGPM/src/libMGPM.h Tue Nov 29 02:59:21 2005 +@@ -238,7 +238,7 @@ + int MGPMrMissingDependencies( structProperty* property ); + int MGPMrPackageDepends( structProperty* property , char* path ); + int MGPMrParse( structProperty* property, char* availablePortName, char* availablePortDir, char* dependType, char* buffer, int* counterPtr ); +-int MGPMrReadConfigure( structProperty* property ); ++int MGPMrReadConfigure( structProperty* property, char* newPortDir ); + int MGPMrShowLeaves( structProperty* property ); + int MGPMrShowLeavesDelete( structProperty* property ); + int MGPMrSinglePortCreateStatusDb( structProperty* property, char* path ); +Binary files ../0.3.9_4/portmanager-0.3.10.tar.gz and ./portmanager-0.3.10.tar.gz differ --- portmanager-0.3.9_5.diff ends here --- >Release-Note: >Audit-Trail: >Unformatted: