summaryrefslogtreecommitdiffstats
path: root/scripts/setlocalversion
Commit message (Collapse)AuthorAgeFilesLines
* kbuild: fix scripts/setlocalversion with gitNico Schottelius2009-05-011-7/+6
| | | | | | | | | | | | | When using trees like wireless-testing, which have untagged tags, scripts/setlocalversion does not display any git indication for localversion. This patch fixes it: If git is available, but no usable tag is found, it uses -g${head}. It skips the detection of unanottated tags via git name-rev. Signed-off-by: Nico Schottelius <nico@ikn.schottelius.org> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* kbuild: use git svn instead of git-svn in setlocalversionPeter Korsgaard2009-04-111-1/+1
| | | | | | | Use the correct git <subcmd> syntax instead of the deprecated git-<subcmd>. Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* kbuild,setlocalversion: shorten the make time when using svnMike Frysinger2009-02-151-8/+1
| | | | | | | | | Don't bother doing `svn st` as it takes a retarded amount of time when the source is cold Signed-off-by: Mike Frysinger <vapier.adi@gmail.com> Signed-off-by: Bryan Wu <cooloney@kernel.org> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* setlocalversion: add git-svn supportPeter Korsgaard2008-12-031-0/+5
| | | | | | | Print svn revision in addition to git info on git-svn repos. Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* setlocalversion: print correct subversion revisionPeter Korsgaard2008-12-031-1/+1
| | | | | | | | Output svn revision of latest change, instead of repo revision as thats what we're interested in (especially when working on a branch/tag). Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* kbuild: tag with git revision when git describe is missingTrent Piepho2008-10-291-1/+3
| | | | | | | | | | | | | | | | | | setlocalversion used to use an abbreviated git commit sha1 to generate the tag. This was changed in commit d882421f4e08ddf0a94245cdbe516db260aa6f41 "kbuild: change CONFIG_LOCALVERSION_AUTO to use a git-describe-ish format" to use git describe to come up with a tag. Which is nice, but git describe sometimes can't describe the revision. Commit 56b2f0706d82535fd8d85503f2dcc0be40c8e55d ("setlocalversion: do not describe if there is nothing to describe") addressed this, but there is still no tag generated. So, generate a plain abbreviated sha1 tag like setlocalversion used to when git describe comes up short. Signed-off-by: Trent Piepho <tpiepho@freescale.com> CC: Jan Engelhardt <jengelh@medozas.de> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* kbuild: setlocalversion: dont include svn change countMike Frysinger2008-10-291-1/+1
| | | | | | | | The number of pending changes is pretty useless, so encoding it into the version is just annoying by the constant shuffle in corresponding modules. Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* setlocalversion: do not describe if there is nothing to describeSebastian Siewior2008-07-251-1/+3
| | | | | | | | | | | | | | | | | | | | | Jan Engelhardt wrote: > Just a note that when you run git-describe, you should probably quiten it. > > fatal: cannot describe 'bd7364a0fd5a4a2878fe4a224be1b142a4e6698e' > > This happens when tags are not present, which can happen if Linus's tree > is sent upwards again, IOW: > > machine1$ git-clone torvalds/linux-2.6.git > machine1$ git push elsewhere master > > machine2$ git-clone elsewhere:/linux > machine2$ git-describe HEAD > fatal: cannot describe that Signed-off-by: Sebastian Siewior <sebastian@breakpoint.cc> Acked-by: Jan Engelhardt <jengelh@medozas.de> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* kbuild: add svn revision information to setlocalversionBryan Wu2008-02-031-0/+16
| | | | | | | | follow git and mercurial style, include uncommitted changes detect Cc: Frans Pop <elendil@planet.nl> Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* kbuild: fix false positive -dirty tag caused by make-kpkgTheodore Ts'o2008-01-281-1/+2
| | | | | | | | | | | | make-kpkg modifies scripts/package/Makefile and deletes scripts/package/builddeb as part of its build process. Ignore these changes so the tree isn't marked as -dirty, when it is just an artifact of make-kpkg. (make-kpkg clean restores the files to their original state, and these helper scripts won't affect the final compiled kernel in any way.) Signed-off-by: "Theodore Ts'o" <tytso@mit.edu> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* kbuild: fix scripts/setlocalversion to avoid erroneous -dirty tagTheodore Ts'o2008-01-281-0/+1
| | | | | | | | | | | If git's index file is out of date, and some files have been touched such that their timestamp doesn't what is in the index, "git diff-index HEAD" may show that a particular file is dirty, when in fact it really isn't. Running "git update-index" will update the index to avoid these false positives. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* kbuild: change CONFIG_LOCALVERSION_AUTO to use a git-describe-ish formatTheodore Ts'o2008-01-281-1/+1
| | | | | | | | | | Change the automatic local version to have the form -nnnnn-gSHA1SUMID, where 'nnnnn' is the number of commits since the last tag (i.e., 2.6.21-rc7). This makes it much more likely that the package names created for the kernel will look "newer" to a package manager. Signed-off-by: "Theodore Ts'o" <tytso@mit.edu> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* kbuild: support mercurial in setlocalversionAron Griffis2008-01-281-0/+23
| | | | | | | | | This represents mercurial changesets similarly to git. For untagged revisions, append the changeset id. If there are uncommitted changes, append -dirty. For example, -hgc60016ba6237-dirty Signed-off-by: Aron Griffis <aron@hp.com> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* kbuild: append -dirty for updated but uncommited changesUwe Zeisberger2006-06-171-1/+1
| | | | | | | | Compare the working copy with the last commit, instead of the index. Signed-off-by: Uwe Zeisberger <zeisberg@informatik.uni-freiburg.de> Acked-by: Ryan Anderson <ryan@michonline.com> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* kbuild: append git revision for all untagged commitsUwe Zeisberger2006-06-171-1/+1
| | | | | | | | | | | | | | | | | | | adds revision suffix for untagged commits that are reachable from a tag I'm bisecting and don't get the -g...... suffix. The reason is, that git name-rev --tags HEAD returns e.g. HEAD tags/v2.6.17-rc1^0~1067 which is currently good enough for setlocalversion to skip the suffix. This introduces a dependecy to grep -E, which should be fine. Signed-off-by: Uwe Zeisberger <zeisberg@informatik.uni-freiburg.de> Acked-By: Ryan Anderson <ryan@michonline.com> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* kbuild: In setlocalversion change -git_dirty to just -dirtyRyan Anderson2006-01-081-1/+1
| | | | | | | | | When building Debian packages directly from the git tree, the appended "git_dirty" is a problem due to the underscore. In order to cause the least problems, change that just to "dirty". Signed-off-by: Ryan Anderson <ryan@michonline.com> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* kbuild: Use git in scripts/setlocalversionRene Scharfe2006-01-061-51/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently scripts/setlocalversion is a Perl script that tries to figure out the current git commit ID of a repo without using git. It also imports Digest::MD5 without using it and generally is too big for the small task it does. :] And it always reports a git ID, even when the HEAD is tagged -- this is a bug. This patch replaces it with a Bourne Shell script that uses git commands to do the same. I can't come up with a scenario where someone would use a git repo and refuse to install git core at the same time, so I think it's reasonable to assume git is available. The new script also reports uncommitted changes by adding -git_dirty to the version string. Obviously you can't see from that _what_ has been changed from the last commit, so it's more of a reminder that you forgot to commit something. The script is easily extensible: simply add a check for Mercurial (or whatever) below the git check. Note: the script doesn't print a newline char anymore. That's only because it was easier to implement it that way, not a feature (or bug). 'make kernelrelease' doesn't care. Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx> Acked-by: Ryan Anderson <ryan@michonline.com> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
* [PATCH] kbuild: automatically append a short string to the version based ↵Ryan Anderson2005-08-101-0/+56
upon the git commit If CONFIG_AUTO_LOCALVERSION is set, the user is using a git-based tree, and the current HEAD is not referred to by any tags in .git/refs/tags/, append -g and the first 8 characters of the commit to the version string. This makes it easier to use git-bisect, and/or to do a daily build, without trampling on your older, working builds, or accidentally setting up conflicting sets of modules. Signed-off-by: Ryan Anderson <ryan@michonline.com> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
OpenPOWER on IntegriCloud