[nycbug-talk] pkg_add and precompiled repositories

mlists at bizintegrators.com mlists
Fri Aug 13 20:45:36 EDT 2004


On Fri, Aug 13, 2004 at 08:22:04PM -0400, George Georgalis wrote:
> On Fri, Aug 13, 2004 at 07:41:34PM -0400, mlists at bizintegrators.com wrote:
> >On Fri, Aug 13, 2004 at 03:40:38PM -0400, George Georgalis wrote:
> >> I was looking at my 2Gb mirror of OpenBSD/packages/i386/ and the pkg_add
> >> man and wondering about a better way.
> >> 
> >> Apparently you can specify a URL with the pkg_add command or use the
> >> environmental PKG_PATH to specify local directories (delimited by
> >> double colon) to search for the package, but is there no convention to
> >> specify a URL as a repository???
> >
> >export PKG_PATH=ftp://ftp.openbsd.org/pub/OpenBSD/3.5/packages/i386/
> >pkg_add ${PKG_PATH}package-x.y.z.tgz
> 
> In that case I would just program a function or alias (new_pkg_add) that
> takes $1 (package-x.y.z.tgz) to do the magic "check-n-use PKG_PATH or
> execute a pkg_add $PKG_URL/$1"

You can do directly: pkg_add http://server/package

I'm not sure this will pull dependencies, haven't used it in a while.

> 
> it just seems like a kluge. I'm surprised it's not already worked out
> that a (or several) URL can be contained in PKG_PATH. 

It can, like you saw in the man page, separated by column.

Again, not sure about dependencies, but perhaps you can just set the
PKG_PATH to an URL and then do pkg_add <package> and it will pull them
all from http.

> If you build on
> that, to determine the most current version available, too, you've just
> improved on apt-get + apt/sources.list functionality... "pkg_add xfree86"

There is usually only one / latest version available in packages
directory on OpenBSD FTP site.







More information about the talk mailing list