tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: pkg_add functions and renovation



On Tue, 22 Apr 2008, Joerg Sonnenberger wrote:
> (1) pkg_add -R is currently enabling -I as well (no register -> don't
> run install scripts). The problem is here that I would have to create
> and remove a temporary directory as I can't run it in the normal pkgdb
> directory. I am not sure if anyone is even using -R, so I am not sure
> if this is a relevant regression.

I am not sure, but I can imagine people wanting to use "don't register"
as part of a bootstrap process.  Regardless of whether people use it or
not, I think it's wrong for "don't register" to imply "don't run install
scripts".

> (3) pkg_add -s is somewhat challenging

The existing verification code probably needs a rewrite anyway.  I
once looked at teaching it to read a list in a format a lot like the
"distinfo" files in pkgsrc, with a single distinfo file containing
information about many packages, and found that not enough information
was passed down to the places that would need it.

> (4) @chmod is missing right now as parsing the permissions is
> non-trivial. What should it support -- the full syntax of chmod?

Yes, I think so.  You can parse the strings like this:

        new_mode = gemode(setmode("u+w,go-w"), old_mode)

where old_mode is derived from stat() on the existing file.

--apb (Alan Barrett)


Home | Main Index | Thread Index | Old Index