Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 21 Oct 2012 16:23:04 GMT
From:      Gerald Pfeifer <gerald@pfeifer.com>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/172935: ports-mgmt/pkg: regression: registering packages can only be done as root
Message-ID:  <201210211623.q9LGN4He037396@freefall.freebsd.org>
Resent-Message-ID: <201210211630.q9LGU0ZJ037513@freefall.freebsd.org>

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

>Number:         172935
>Category:       ports
>Synopsis:       ports-mgmt/pkg: regression: registering packages can only be done as root
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Oct 21 16:30:00 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator:     Gerald Pfeifer
>Release:        FreeBSD 10.0-CURRENT
>Organization:
>Environment:
	ref10-i386.freebsd.org
>Description:
	https://github.com/pkgng/pkgng/commit/6c805f9fac79c9f9827420f4a58fef7265ce9281
	introduced a severe regression for anyone (like me) using the
	FreeBSD Ports Collection also as non-root:

	if (geteuid() != 0) {
	  warnx("registering packages can only be done as root");
	  return (EX_NOPERM);
	}
>How-To-Repeat:
	export PREFIX=${HOME}/somewhere
	export LOCALBASE=${PREFIX}
	export PKG_DBDIR=${PREFIX}/dbpkg
	export SHAREMODE=644
	export BINOWN=`whoami`
	export BINGRP=`whoami`
	export MANOWN=`whoami`
	export MANGRP=`whoami`
	export SHAREOWN=`whoami`
	export SHAREGRP=`whoami`
	make INSTALL_AS_USER=1 BATCH=1 FORCE_PKG_REGISTER=1 install

	This has been working for many, many years and been the base
	of nearly all of FreeBSD ports development and testing.
>Fix:
	Disable this test again, or at least if INSTALL_AS_USER as set
	in the environment.

	(Disabling this test everything seems fine to me as a user.)
>Release-Note:
>Audit-Trail:
>Unformatted:



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