Date: Sat, 11 Oct 2008 19:00:10 GMT From: Bruce Cran <bruce@cran.org.uk> To: freebsd-bugs@FreeBSD.org Subject: Re: bin/125932: pkg_add(1) doesn't prompt for root credentials and then fails badly Message-ID: <200810111900.m9BJ0Anq047039@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/125932; it has been noted by GNATS. From: Bruce Cran <bruce@cran.org.uk> To: Garrett Cooper <yanefbsd@gmail.com> Cc: bug-followup@freebsd.org, freebsd-bugs@freebsd.org Subject: Re: bin/125932: pkg_add(1) doesn't prompt for root credentials and then fails badly Date: Sat, 11 Oct 2008 19:53:04 +0100 Garrett Cooper wrote: > Here's a proposed patch for the first set of cleanup to pkg_install: > <http://pastebin.com/f1cee71c2>, and some fixing to alleviate the > issue in bin/125932. > > Rather than biting off more than I can chew with the perforce project, > I'm going to work off the changes Anders has made and incrementally > polish pkg_install (like I should have done last year -_-...) > > This patch causes pkg_install to error out at the first sign of > install failure (which could take a while as it's still using tar(1) > to extract archives in add/extract.c), BUT in getFileByURL I've > completely replaced the tar requirement in lib/url.c with > archive(3)'s, quite handy hooks for writing to files. So don't be > alarmed when you see that the file has grown 4 times ;)... > > This patch hasn't gotten much mileage, other than a few failure and > success cases, so if others could please take a look at this and > provide comments I'd much appreciate it. > > Cheers, > -Garrett > > PS Packages might not be dumped in the correct spot -- I just chose > /var/tmp, but if someone could point me to the "industry standard" > location that portupgrade uses for instance, I'd be more than happy to > point there. > Which release is the patch against? It doesn't apply cleanly to HEAD sources and I don't think it works on 7.1-PRERELEASE either - I can't see a version of pkg_install/Makefile from 2008-09-08 in cvsweb. It looks like the ports infrastructure and portmaster put packages in /usr/ports/packages. From portmaster(8): "The directory pointed to by the PACKAGES variable (by default /usr/ports/packages) will be used to store new and backup packages. When using 'make package' for the -g option, the ports infrastructure will store packages in /usr/ports/packages/All, aka PKGREPOSITORY. When using the -b option, portmaster stores its backup packages in /usr/ports/packages/portmaster-backup so that you can create both a backup package of the newly installed port even if they have the same version." -- Bruce Cran
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200810111900.m9BJ0Anq047039>