ports/103177: fix-port mail/vpopmail & mail/vpopmail-devel

Oliver Lehmann oliver at FreeBSD.org
Tue Sep 12 05:40:13 UTC 2006


>Number:         103177
>Category:       ports
>Synopsis:       fix-port mail/vpopmail & mail/vpopmail-devel
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          update
>Submitter-Id:   current-users
>Arrival-Date:   Tue Sep 12 05:40:12 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     Oliver Lehmann
>Release:        FreeBSD 6.1-STABLE amd64
>Organization:
>Environment:
System: FreeBSD kartoffel.salatschuessel.net 6.1-STABLE FreeBSD 6.1-STABLE #0: Fri Jul 7 18:40:18 CEST 2006 olivleh1 at kartoffel.salatschuessel.net:/usr/obj/amd64-athlon64-6.1/usr/src/sys/KARTOFFEL amd64


>Description:
	while adding vpopmail or vpopmail-devel as a package, PKG_PREFIX
	gets defined as ${PREFIX} - not as ${PREFIX} like it is defined
	in the Makefile. This ends up in creating users with /usr/local
	as home dir prefix, not /usr/local/vpopmail. This leads to a
	wrong home dir, and uninstallable other vpopmail-dendant appli-
	cations like vqadmin or courier-authlib-vchkpw because this
	applications are expecting lib_deps and inc_deps in ~vpopmail/etc.
>How-To-Repeat:
>Fix:


--- vpopmail.patch begins here ---
Index: vpopmail/Makefile
===================================================================
RCS file: /home/pcvs/ports/mail/vpopmail/Makefile,v
retrieving revision 1.65
diff -u -r1.65 Makefile
--- vpopmail/Makefile	17 Jul 2006 05:51:32 -0000	1.65
+++ vpopmail/Makefile	12 Sep 2006 05:34:43 -0000
@@ -296,7 +296,7 @@
 #
 
 pre-configure:
-	@PKG_PREFIX=${PREFIX}/vpopmail ${PERL5} ${PKGINSTALL}
+	@PKG_PREFIX=${PREFIX} ${PERL5} ${PKGINSTALL}
 .if defined(WITH_PGSQL)
 .if defined(WITH_PGSQL_DB)
 	${REINPLACE_CMD} -E -e "s/(#define DB.*)vpopmail(.*)/\1${WITH_PGSQL_DB}\2/" ${WRKSRC}/vpgsql.h
Index: vpopmail/pkg-install
===================================================================
RCS file: /home/pcvs/ports/mail/vpopmail/pkg-install,v
retrieving revision 1.2
diff -u -r1.2 pkg-install
--- vpopmail/pkg-install	4 Jul 2001 15:34:48 -0000	1.2
+++ vpopmail/pkg-install	12 Sep 2006 05:34:43 -0000
@@ -50,7 +50,7 @@
 	do checkrpw;  # May exit
 
 	$x = "-u $uids{'alias'}";
-	$result = system ("/usr/sbin/pw useradd alias -g qnofiles -d \"$ENV{PKG_PREFIX}/alias\" -s /nonexistent $x");
+	$result = system ("/usr/sbin/pw useradd alias -g qnofiles -d \"$ENV{PKG_PREFIX}/vpopmail/alias\" -s /nonexistent $x");
 	if ($result) {
 		die "Failed to add user alias as uid $uids{'alias'}\n";
 	}
@@ -61,7 +61,7 @@
 		do checkrpw;  # May exit
 
 		$x = "-u $uids{$user}";
-		$result = system ("/usr/sbin/pw useradd $user -g $users{$user} -d \"$ENV{PKG_PREFIX}\" -s /nonexistent $x");
+		$result = system ("/usr/sbin/pw useradd $user -g $users{$user} -d \"$ENV{PKG_PREFIX}/vpopmail\" -s /nonexistent $x");
 		if ($result) {
 			die "Failed to add user $user as uid $uids{$user}\n";
 		}
Index: vpopmail-devel/Makefile
===================================================================
RCS file: /home/pcvs/ports/mail/vpopmail-devel/Makefile,v
retrieving revision 1.51
diff -u -r1.51 Makefile
--- vpopmail-devel/Makefile	10 May 2006 22:37:04 -0000	1.51
+++ vpopmail-devel/Makefile	12 Sep 2006 05:34:44 -0000
@@ -269,7 +269,7 @@
 #
 
 pre-configure:
-	@PKG_PREFIX=${PREFIX}/vpopmail ${PERL5} ${PKGINSTALL}
+	@PKG_PREFIX=${PREFIX} ${PERL5} ${PKGINSTALL}
 .if defined(WITH_PGSQL)
 .if defined(WITH_PGSQL_DB)
 	${REINPLACE_CMD} -E -e "s/(#define DB.*)vpopmail(.*)/\1${WITH_PGSQL_DB}\2/" ${WRKSRC}/vpgsql.h
Index: vpopmail-devel/pkg-install
===================================================================
RCS file: /home/pcvs/ports/mail/vpopmail-devel/pkg-install,v
retrieving revision 1.2
diff -u -r1.2 pkg-install
--- vpopmail-devel/pkg-install	4 Jul 2001 15:34:48 -0000	1.2
+++ vpopmail-devel/pkg-install	12 Sep 2006 05:34:44 -0000
@@ -50,7 +50,7 @@
 	do checkrpw;  # May exit
 
 	$x = "-u $uids{'alias'}";
-	$result = system ("/usr/sbin/pw useradd alias -g qnofiles -d \"$ENV{PKG_PREFIX}/alias\" -s /nonexistent $x");
+	$result = system ("/usr/sbin/pw useradd alias -g qnofiles -d \"$ENV{PKG_PREFIX}/vpopmail/alias\" -s /nonexistent $x");
 	if ($result) {
 		die "Failed to add user alias as uid $uids{'alias'}\n";
 	}
@@ -61,7 +61,7 @@
 		do checkrpw;  # May exit
 
 		$x = "-u $uids{$user}";
-		$result = system ("/usr/sbin/pw useradd $user -g $users{$user} -d \"$ENV{PKG_PREFIX}\" -s /nonexistent $x");
+		$result = system ("/usr/sbin/pw useradd $user -g $users{$user} -d \"$ENV{PKG_PREFIX}/vpopmail\" -s /nonexistent $x");
 		if ($result) {
 			die "Failed to add user $user as uid $uids{$user}\n";
 		}
--- vpopmail.patch ends here ---


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



More information about the freebsd-ports-bugs mailing list