* [PATCH] xen/makefile: Allow XEN_CHANGESET to be set externally
@ 2013-05-17 13:21 Andrew Cooper
2013-05-17 14:32 ` Olaf Hering
0 siblings, 1 reply; 4+ messages in thread
From: Andrew Cooper @ 2013-05-17 13:21 UTC (permalink / raw)
To: xen-devel; +Cc: Keir Fraser, Jan Beulich
Build systems based on tarballs rather than source code trees, such as
rpms/debs are unable to obtain changeset infomation.
Allow XEN_CHANGESET to be optionally specified in the environment.
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
---
Changes from v1:
* Rebase on top of "Use {git, hg, svn} commit id if available for xen_changeset"
diff -r 2369a9d759f0 -r 396ebb07e2d0 xen/Makefile
--- a/xen/Makefile
+++ b/xen/Makefile
@@ -13,6 +13,7 @@ export BASEDIR := $(CURDIR)
export XEN_ROOT := $(BASEDIR)/..
EFI_MOUNTPOINT ?= /boot/efi
+XEN_CHANGESET ?= $(shell tools/scmversion $(XEN_ROOT) || echo "unavailable")
.PHONY: default
default: build
@@ -126,7 +127,7 @@ include/xen/compile.h: include/xen/compi
-e 's/@@version@@/$(XEN_VERSION)/g' \
-e 's/@@subversion@@/$(XEN_SUBVERSION)/g' \
-e 's/@@extraversion@@/$(XEN_EXTRAVERSION)/g' \
- -e 's!@@changeset@@!$(shell tools/scmversion $(XEN_ROOT) || echo "unavailable")!g' \
+ -e 's!@@changeset@@!$(XEN_CHANGESET)!g' \
< include/xen/compile.h.in > $@.new
@grep \" .banner >> $@.new
@grep -v \" .banner
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [PATCH] xen/makefile: Allow XEN_CHANGESET to be set externally
2013-05-17 13:21 [PATCH] xen/makefile: Allow XEN_CHANGESET to be set externally Andrew Cooper
@ 2013-05-17 14:32 ` Olaf Hering
2013-05-17 14:41 ` Andrew Cooper
0 siblings, 1 reply; 4+ messages in thread
From: Olaf Hering @ 2013-05-17 14:32 UTC (permalink / raw)
To: Andrew Cooper; +Cc: Keir Fraser, Jan Beulich, xen-devel
On Fri, May 17, Andrew Cooper wrote:
> Build systems based on tarballs rather than source code trees, such as
> rpms/debs are unable to obtain changeset infomation.
>
> Allow XEN_CHANGESET to be optionally specified in the environment.
Isnt that already possible with 'echo "$XEN_CHANGESET" > .scmversion'?
Olaf
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] xen/makefile: Allow XEN_CHANGESET to be set externally
2013-05-17 14:32 ` Olaf Hering
@ 2013-05-17 14:41 ` Andrew Cooper
2013-05-17 17:04 ` Ian Campbell
0 siblings, 1 reply; 4+ messages in thread
From: Andrew Cooper @ 2013-05-17 14:41 UTC (permalink / raw)
To: Olaf Hering; +Cc: Keir (Xen.org), Jan Beulich, xen-devel@lists.xen.org
On 17/05/2013 15:32, Olaf Hering wrote:
> On Fri, May 17, Andrew Cooper wrote:
>
>> Build systems based on tarballs rather than source code trees, such as
>> rpms/debs are unable to obtain changeset infomation.
>>
>> Allow XEN_CHANGESET to be optionally specified in the environment.
> Isnt that already possible with 'echo "$XEN_CHANGESET" > .scmversion'?
>
> Olaf
No - that results in the literal string "$XEN_CHANGESET"
I have however identified a bug with the way in which
xen/tools/scmversion deals with git. Patch on the way.
~Andrew
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] xen/makefile: Allow XEN_CHANGESET to be set externally
2013-05-17 14:41 ` Andrew Cooper
@ 2013-05-17 17:04 ` Ian Campbell
0 siblings, 0 replies; 4+ messages in thread
From: Ian Campbell @ 2013-05-17 17:04 UTC (permalink / raw)
To: Andrew Cooper
Cc: Olaf Hering, Keir (Xen.org), Jan Beulich, xen-devel@lists.xen.org
On Fri, 2013-05-17 at 15:41 +0100, Andrew Cooper wrote:
> On 17/05/2013 15:32, Olaf Hering wrote:
> > On Fri, May 17, Andrew Cooper wrote:
> >
> >> Build systems based on tarballs rather than source code trees, such as
> >> rpms/debs are unable to obtain changeset infomation.
> >>
> >> Allow XEN_CHANGESET to be optionally specified in the environment.
> > Isnt that already possible with 'echo "$XEN_CHANGESET" > .scmversion'?
> >
> > Olaf
>
> No - that results in the literal string "$XEN_CHANGESET"
No, because your shell would expand it. In any case Olaf's point was
obviously that you could write whatever string you would like to that
file and it would have exactly the same effect as overriding
XEN_CHANGESET when calling make. I expect it's also a little less prone
to forgetting to pass it to make on every call.
Ian.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-05-17 17:04 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-05-17 13:21 [PATCH] xen/makefile: Allow XEN_CHANGESET to be set externally Andrew Cooper
2013-05-17 14:32 ` Olaf Hering
2013-05-17 14:41 ` Andrew Cooper
2013-05-17 17:04 ` Ian Campbell
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.