Bug 77194 - net/quagga reveals some bugs if installing from a binary package
Summary: net/quagga reveals some bugs if installing from a binary package
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Yar Tikhiy
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-02-07 08:10 UTC by Yar Tikhiy
Modified: 2005-03-09 11:50 UTC (History)
1 user (show)

See Also:


Attachments
quagga.patch (4.23 KB, patch)
2005-02-07 09:55 UTC, Boris Kovalenko
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Yar Tikhiy 2005-02-07 08:10:22 UTC
	The quagga port contains some bugs that are revealed if installing
	from a binary package:

	1. It sets "quagga" user homedir to /etc/quagga
	2. It emits a poorly formatted message: Added group "quagga\.
	3. It runs ldconfig against %D/lib after setting prefix to /etc/rc.d

Fix: 

A possible fix should affect pkg-install and pkg-plist.
How-To-Repeat: 
rt2# pkg_add quagga-0.98.2.tgz
ldconfig: warning: /etc/rc.d/lib: No such file or directory
Added group "quagga\.
Added user "quagga".

rt2# ls -ld /etc/quagga /usr/local/etc/quagga
ls: /usr/local/etc/quagga: No such file or directory
drwxr-xr-x  2 quagga  quagga  512 Feb  6 22:54 /etc/quagga

rt2# pkg_delete quagga-0.98.2
pkg_delete: file '/usr/local/etc/quagga' doesn't really exist
pkg_delete: unable to completely remove directory '/usr/local/etc/quagga'
pkg_delete: couldn't entirely delete package (perhaps the packing list is
incorrectly specified?)
Comment 1 Boris Kovalenko 2005-02-07 09:55:18 UTC
Hello!

	Thanks for the report. Please apply the patch attached.
-- 
With respect,
	Boris Kovalenko.
Comment 2 Yar Tikhiy freebsd_committer freebsd_triage 2005-02-07 10:14:21 UTC
Responsible Changed
From-To: freebsd-ports-bugs->yar

Taking this one.
Comment 3 Yar Tikhiy 2005-02-07 10:54:51 UTC
On Mon, Feb 07, 2005 at 02:55:18PM +0500, Boris Kovalenko wrote:
> Hello!
> 
> 	Thanks for the report. Please apply the patch attached.

Thanks, applied and committed.

However, I think that the cwd trick should be eliminated eventually.
Are you on the freebsd-ports list?  I'd appreciate if you raised
this issue on the list.

Ideally, a package should not depend on the build-time PREFIX setting
since it can be changed later via the -p option to pkg_add.  Perhaps
we need something like @pushwd and @popwd in order to be able to
restore the prefix setting for the rest of a packing list for
bsd.port.mk to append @exec's to it safely.

Therefore I leave this PR open for now.

-- 
Yar
Comment 4 Yar Tikhiy 2005-02-07 11:14:15 UTC
On Mon, Feb 07, 2005 at 01:54:51PM +0300, Yar Tikhiy wrote:
> On Mon, Feb 07, 2005 at 02:55:18PM +0500, Boris Kovalenko wrote:
> > Hello!
> > 
> > 	Thanks for the report. Please apply the patch attached.
> 
> Thanks, applied and committed.
> 
> However, I think that the cwd trick should be eliminated eventually.
> Are you on the freebsd-ports list?  I'd appreciate if you raised
> this issue on the list.
> 
> Ideally, a package should not depend on the build-time PREFIX setting
> since it can be changed later via the -p option to pkg_add.  Perhaps
> we need something like @pushwd and @popwd in order to be able to
> restore the prefix setting for the rest of a packing list for
> bsd.port.mk to append @exec's to it safely.

Just for the record: the bug described in ports/59070 looks similar
to this one, and the fix committed doesn't look quite correct, too,
since it breaks "pkg_add -p /foo" in the same way if a packing list
makes use of @cwd.

-- 
Yar
Comment 5 Yar Tikhiy freebsd_committer freebsd_triage 2005-03-09 11:44:30 UTC
State Changed
From-To: open->closed

Superseded by PR 77212 and PR 78614.