On Mon, 12 Oct 2015, Felix Fietkau wrote:
If someone checks out the source and compiles a new copy (with local
modifications), reporting a SVN version is as misleading as a git hash.
It may not always be accurate, but the SVN version is actually useful in
most cases, even when modifications are present.
I know that various projects I work with have the build process embed the date
in the package versions, so it should be straightforward to put it into some
file in the resulting firmware image. Such a process can also check if it's
running on the 'official' tree or in someone else's repo (check repo
owner/e-mail) and add the initials of the person compiling it.
What I don't understand is how the script should check if something is
the official tree, e.g. in the simple case of somebody having forked the
OpenWrt mirror on github, cloned it locally, added and pushed a few
commits and then made a build.
git config --get user.name
git config --get user.email
if they are set to the name of the official buildbot, no nothing. If they are
set to anything else, take some data (initials or something) and make that part
of the version number.
It's not checking if it's an unmodified tree, just if it's being built on the
OpenWRT infrastructure.
If someone is building an unmodified tree, the git hash will work for
identifying what tree it is. And someone else posted a process for trackign
divergence from the upstream tree if they are modifying it first.
I still have doubts about that process. And why should the version info
be treated differently if things are built on the official infrastructure?
just in the interests of keeping it short.
With git all repos are technically equal. It's project convention as to which
one is the upstream master. If you have such a convention, why not use it to
make the tags that everyone has to deal with shorter then when you are dealing
with someone building a branch that needs more description anyway?
shrug, it's a nice-to-do, not a requirement.
David Lang
_______________________________________________
openwrt-devel mailing list
[email protected]
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel