|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v2] scripts: introduce a script for build test
Wei Liu writes ("Re: [PATCH v2] scripts: introduce a script for build test"):
> On Tue, Oct 24, 2017 at 02:38:39PM +0100, Ian Jackson wrote:
> > Anthony PERARD writes ("Re: [PATCH v2] scripts: introduce a script for
> > build test"):
> > > That feels wrong. How do I run the same exact command at the default
> > > one, but with -j8 instead of -j4?
> >
> > .../build-test sh -ec make -j4 distclean && ./configure && make -j4
> >
> > But I think Anthony has a point. The clean should 1. be git-clean,
> > not make distclean 2. be run anyway.
>
> I don't think we should call git-clean unconditionally -- imagine
> someone knew for sure they only needed to build part of the tools or the
> hypervisor.
If you are worried about this you should check that there are no
uncommitted files before starting.
I have a visceral loathing of clean targets. They are often flaky,
and ours are no exception.
> > > > +echo "Restoring original HEAD"
> > > > +git checkout $ORIG_BRANCH
> > >
> > > Also, what a developper should do when the build fail? She can't modify
> > > the current code, because changes are going to be losts. Maybe we could
> > > trap failures, restore original HEAD and point out which commit fails to
> > > build.
> >
> > IWBNI it would at least print the branch to checkout. Tools like "git
> > bisect" record the information in .git and allow "git bisect reset".
>
> Not sure I follow. Do you want the script to trap SIGCHLD, test the
> return value and act accordingly?
I don't mean you should trap SIGCHLD.
But you should probably trap '' and use it to print a helpful message
containing ORIG_BRANCH. On success you would disable the trap before
exiting.
Alternatively you could defuse `set -e' around the invocation of the
build command, and handle $? explicitly.
Ian.
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |