Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 10 Oct 2000 09:36:13 +0300
From:      Maxim Sobolev <sobomax@FreeBSD.org>
To:        Satoshi - Ports Wraith - Asami <asami@FreeBSD.org>
Cc:        bmah@FreeBSD.org, Neil Blakey-Milner <nbm@mithrandr.moria.org>, Akinori -Aki- MUSHA <knu@idaemons.org>, freebsd-ports@FreeBSD.org
Subject:   Re: PROPOSAL: Use @comment PLIST variable to track where installed    packages came from [Was: Enhancement of pkg_version's version  comparison   routine]
Message-ID:  <39E2B8DD.C7099DE3@FreeBSD.org>
References:  <86k8by6eis.wl@archon.local.idaemons.org> <20000927002401.A73341@mithrandr.moria.org> <39D9D006.652DC258@FreeBSD.org> <20001003161027.B67542@mithrandr.moria.org> <39D9EE01.7A880665@FreeBSD.org> <200010031657.e93Gvtg10718@bmah-freebsd-0.cisco.com> <39DB17BB.12805565@FreeBSD.org> <200010060426.e964Qvx70814@bmah-freebsd-0.cisco.com> <39DE1A48.C7C8C9CF@FreeBSD.org> <vqc8zrx8nlp.fsf_-_@silvia.hip.berkeley.edu>

next in thread | previous in thread | raw e-mail | index | archive | help
Satoshi - Ports Wraith - Asami wrote:

>  * * From: Maxim Sobolev <sobomax@FreeBSD.org>
>
>  * 2. What is proposed?
>  *
>  * It is proposed to plant into package short information about path  of the underlying
>  * port, from which installed packages was generated, in the Ports Tree. Due to the fact
>
> This is a very good idea.  I've wanted this for years. :)

I like that you like it ;).

>  * 3. How it would work?
>  *
>  * When creating  package, bsd.port.mk will generate MASTERCATEGORY/PORTDIR string and
>  * feed it to pkg_create. Here MASTERCATEGORY is the first category specified in port's
>  * CATEGORIES and it should coincide with name of corresponding parent directory in the
>  * ports tree. It was defined in such way to properly handle ports installed w/o parent
>
> Yes, I think it is correct to make that assumption.  (I believe it is
> documented in the Porter's Handbook as a rule, but if it is not, it
> should be.)

/me goes to read Porter's Handbook ;).

>  * current version of the package in the Ports Collection. All other packages (for
>  * example old packages w/o origin, third party packages etc.) will be handled using
>  * ports/INDEX.
>
> Sounds good.  Well, I don't think third party packages will be
> "handled" all that well using ports/INDEX since they aren't in there
> (unless the user edited the file manually to put it in :), but I
> assume you are saying it will just fall back to the old method of
> using INDEX if the port directory is found, which is of course fine.

Correct.

> Same goes for ports that have been repo-copied, but of course this
> can't be helped.

Unfortunately :(

>  * With this message I'm attaching appropriate patches for pkg_* tools and bsd.port.mk.
>
> I'm not capable of reviewing patches to pkg_* tools but on the
> bsd.port.mk patch:
>
>  * +SED?=               /usr/bin/sed
>  * +BASENAME?=  /usr/bin/basename
>
> I should just move the whole damn section up here.

Yes, it would be fine. Also it would be nice to add /usr/bin/find and /usr/bin/xargs into this section.
Alternative I would propose to create share/mk/bsd.commands.mk, so not only ports, but all others
make(1) users would benefit from it.

>  * +
>  * +.if ${OSVERSION} > 500012
>
> Don't worry about the OSVERSION check, I'll make an upgrade kit and
> bump BSDPORTMKVERSION to make sure people will have the newest pkg_*
> tools.

Ok, I added it just for completeness sake ;).

>  * +_PKGCATEGORY!=              ${ECHO} ${CATEGORIES} | ${SED} -E 's|^ *||g ; s| .*$$||'
>  * +_PORTDIRNAME!=              ${BASENAME} ${.CURDIR}
>
> I wish we could do these substitutions without having to invoke
> separate processes though.  Will, aren't there ways to do this in
> make?

Yes, it should be possible when current Will's efforts to bring :C/// into make(1) is finished. I do not
see any way to avoid ${BASENAME}, though.

-Maxim




To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




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