[PATCH] newvers.sh

M. Warner Losh imp at bsdimp.com
Mon Mar 15 14:51:32 UTC 2010


In message: <20100315142806.GA5786 at dragon.NUXI.org>
            "David O'Brien" <obrien at FreeBSD.org> writes:
: On Sat, Mar 13, 2010 at 09:13:03PM -0700, M. Warner Losh wrote:
: > In message: <20100312171206.GA31761 at dragon.NUXI.org>
: >             "David O'Brien" <obrien at freebsd.org> writes:
: > : * Simplify SRCDIR calculation by directly finding the kernel sources
: > :   based directly on one of them.
: > : Reviewed by: dhw
: > :   This change does not increase the kernel build time.  It also continues
: > :   to restrict the revision to just the kernel sources, and not the whole
: > :   tree.
: > : Timing tests by: dhw
: > 
: > <patch omitted>
: > 
: > I have a better simplification, I think, that works for me for each of
: > the tests that I've done (both traditional and buildkernel builds).
: 
: I also have other simplifications.  But want to do this in stages,
: least there be some corner case or misunderstanding by someone.

Normally this is a sensible process.  However, my patches change how
we guess where sys is, and as such, I think we should go directly
there and work out the corner cases and such there.

: > Can you confirm this works for you and also comment on the change
: > itself?  It is a bigger change, but results in a simpler (I think)
: > newvers.sh.
: > Comments?
: 
: I would prefer to do this in stages so things aren't misunderstood.
: This patch is one of the key parts that shows I am not making the
: 'svnversion' run take longer, and that it does not cover more of
: the tree than before.

That's exactly what my patch does by passing in SYSDIR directly.  Why
guess and then replace it with a different guess.  Why not go directly
to the best guess immediately?  We know it is always right, because we
know it is what the kernel is using to build itself.  And we know
that's the directory we want to use for the svn command.

Warner


More information about the freebsd-current mailing list