* Silent failure when missing bc
@ 2013-05-02 14:44 Ian Kumlien
2013-05-02 16:12 ` H. Peter Anvin
2013-05-02 20:25 ` Sam Ravnborg
0 siblings, 2 replies; 5+ messages in thread
From: Ian Kumlien @ 2013-05-02 14:44 UTC (permalink / raw)
To: linux-kbuild; +Cc: hpa, mmarek
Hi,
A dependency on bc was added at some point during the 3.9 development.
My machines runs a git forest which contains both stable and Torvalds
mainline. So any kernel version is only a:
git fetch --all && git checkout <tag> away
When switching from v3.8.5 to v3.9-rc7 i ran in to a odd thing.
It seemed to build fine, make install and modules_install was all fine
as well but rebooting revealed that 3.8.5 had been installed again
instead.
Doing make clean and rebuilding revealed that I was missing bc ;)
I have tried to find exactly where it's run since then, i have found the
cmd_bc section but not found what triggers it... Due to lack of time and
energy, I hearby report this bug!
This is about as far as i got:
kernel/Makefile:135:quiet_cmd_bc = BC $@
kernel/Makefile:136: cmd_bc = bc -q $(filter-out FORCE,$^) > $@
Is there any detaled information and or instructions on kbuild btw?
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Silent failure when missing bc
2013-05-02 14:44 Silent failure when missing bc Ian Kumlien
@ 2013-05-02 16:12 ` H. Peter Anvin
2013-05-02 18:28 ` Ian Kumlien
2013-05-02 20:25 ` Sam Ravnborg
1 sibling, 1 reply; 5+ messages in thread
From: H. Peter Anvin @ 2013-05-02 16:12 UTC (permalink / raw)
To: Ian Kumlien; +Cc: linux-kbuild, mmarek
On 05/02/2013 07:44 AM, Ian Kumlien wrote:
> Hi,
>
> A dependency on bc was added at some point during the 3.9 development.
>
> My machines runs a git forest which contains both stable and Torvalds
> mainline. So any kernel version is only a:
> git fetch --all && git checkout <tag> away
>
> When switching from v3.8.5 to v3.9-rc7 i ran in to a odd thing.
>
> It seemed to build fine, make install and modules_install was all fine
> as well but rebooting revealed that 3.8.5 had been installed again
> instead.
>
Are you *sure* that the build didn't stop and you just didn't notice it?
That is what the above sounds like. Keep in mind that in a parallel
build there can be quite a few lines of output after the *** failure line...
> Doing make clean and rebuilding revealed that I was missing bc ;)
>
> I have tried to find exactly where it's run since then, i have found the
> cmd_bc section but not found what triggers it... Due to lack of time and
> energy, I hearby report this bug!
>
> This is about as far as i got:
> kernel/Makefile:135:quiet_cmd_bc = BC $@
> kernel/Makefile:136: cmd_bc = bc -q $(filter-out FORCE,$^) > $@
>
> Is there any detaled information and or instructions on kbuild btw?
>
The disconcerting thing here, of course, is if the build would have
looked like it completed without the file actually being generated. It
should have failed either to generate the file, or it should have
produced an empty header which would have caused a failure further down
the line...
-hpa
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Silent failure when missing bc
2013-05-02 16:12 ` H. Peter Anvin
@ 2013-05-02 18:28 ` Ian Kumlien
2013-05-02 19:28 ` H. Peter Anvin
0 siblings, 1 reply; 5+ messages in thread
From: Ian Kumlien @ 2013-05-02 18:28 UTC (permalink / raw)
To: H. Peter Anvin; +Cc: linux-kbuild, mmarek
On Thu, May 02, 2013 at 09:12:32AM -0700, H. Peter Anvin wrote:
> On 05/02/2013 07:44 AM, Ian Kumlien wrote:
> > Hi,
> >
> > A dependency on bc was added at some point during the 3.9 development.
> >
> > My machines runs a git forest which contains both stable and Torvalds
> > mainline. So any kernel version is only a:
> > git fetch --all && git checkout <tag> away
> >
> > When switching from v3.8.5 to v3.9-rc7 i ran in to a odd thing.
> >
> > It seemed to build fine, make install and modules_install was all fine
> > as well but rebooting revealed that 3.8.5 had been installed again
> > instead.
>
> Are you *sure* that the build didn't stop and you just didn't notice it?
> That is what the above sounds like. Keep in mind that in a parallel
> build there can be quite a few lines of output after the *** failure line...
Damn it, i didn't see it in the 30+ line window, but yes there is a
error message.
Must have been more tired than i thought...
> > Doing make clean and rebuilding revealed that I was missing bc ;)
> >
> > I have tried to find exactly where it's run since then, i have found the
> > cmd_bc section but not found what triggers it... Due to lack of time and
> > energy, I hearby report this bug!
> >
> > This is about as far as i got:
> > kernel/Makefile:135:quiet_cmd_bc = BC $@
> > kernel/Makefile:136: cmd_bc = bc -q $(filter-out FORCE,$^) > $@
> >
> > Is there any detaled information and or instructions on kbuild btw?
>
> The disconcerting thing here, of course, is if the build would have
> looked like it completed without the file actually being generated. It
> should have failed either to generate the file, or it should have
> produced an empty header which would have caused a failure further down
> the line...
Imho it should have had bc as a dependency and failed to run that step.
Ie instead of "/bin/sh: bc: command not found"
Do we know which tools we need? could we add them as "make
dependencies"?
> -hpa
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Silent failure when missing bc
2013-05-02 18:28 ` Ian Kumlien
@ 2013-05-02 19:28 ` H. Peter Anvin
0 siblings, 0 replies; 5+ messages in thread
From: H. Peter Anvin @ 2013-05-02 19:28 UTC (permalink / raw)
To: Ian Kumlien; +Cc: linux-kbuild, mmarek
Sorry, that is not how it works with external tools. The point still holds: the job should have failed and make would have stopped.
Ian Kumlien <pomac@vapor.com> wrote:
>On Thu, May 02, 2013 at 09:12:32AM -0700, H. Peter Anvin wrote:
>> On 05/02/2013 07:44 AM, Ian Kumlien wrote:
>> > Hi,
>> >
>> > A dependency on bc was added at some point during the 3.9
>development.
>> >
>> > My machines runs a git forest which contains both stable and
>Torvalds
>> > mainline. So any kernel version is only a:
>> > git fetch --all && git checkout <tag> away
>> >
>> > When switching from v3.8.5 to v3.9-rc7 i ran in to a odd thing.
>> >
>> > It seemed to build fine, make install and modules_install was all
>fine
>> > as well but rebooting revealed that 3.8.5 had been installed again
>> > instead.
>>
>> Are you *sure* that the build didn't stop and you just didn't notice
>it?
>> That is what the above sounds like. Keep in mind that in a parallel
>> build there can be quite a few lines of output after the *** failure
>line...
>
>Damn it, i didn't see it in the 30+ line window, but yes there is a
>error message.
>
>Must have been more tired than i thought...
>
>> > Doing make clean and rebuilding revealed that I was missing bc ;)
>> >
>> > I have tried to find exactly where it's run since then, i have
>found the
>> > cmd_bc section but not found what triggers it... Due to lack of
>time and
>> > energy, I hearby report this bug!
>> >
>> > This is about as far as i got:
>> > kernel/Makefile:135:quiet_cmd_bc = BC $@
>> > kernel/Makefile:136: cmd_bc = bc -q $(filter-out FORCE,$^) >
>$@
>> >
>> > Is there any detaled information and or instructions on kbuild btw?
>>
>> The disconcerting thing here, of course, is if the build would have
>> looked like it completed without the file actually being generated.
>It
>> should have failed either to generate the file, or it should have
>> produced an empty header which would have caused a failure further
>down
>> the line...
>
>Imho it should have had bc as a dependency and failed to run that step.
>
>Ie instead of "/bin/sh: bc: command not found"
>
>Do we know which tools we need? could we add them as "make
>dependencies"?
>
>> -hpa
>>
--
Sent from my mobile phone. Please excuse brevity and lack of formatting.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Silent failure when missing bc
2013-05-02 14:44 Silent failure when missing bc Ian Kumlien
2013-05-02 16:12 ` H. Peter Anvin
@ 2013-05-02 20:25 ` Sam Ravnborg
1 sibling, 0 replies; 5+ messages in thread
From: Sam Ravnborg @ 2013-05-02 20:25 UTC (permalink / raw)
To: Ian Kumlien; +Cc: linux-kbuild, hpa, mmarek
On Thu, May 02, 2013 at 04:44:03PM +0200, Ian Kumlien wrote:
> Hi,
>
> A dependency on bc was added at some point during the 3.9 development.
>
> My machines runs a git forest which contains both stable and Torvalds
> mainline. So any kernel version is only a:
> git fetch --all && git checkout <tag> away
>
> When switching from v3.8.5 to v3.9-rc7 i ran in to a odd thing.
>
> It seemed to build fine, make install and modules_install was all fine
> as well but rebooting revealed that 3.8.5 had been installed again
> instead.
>
> Doing make clean and rebuilding revealed that I was missing bc ;)
>
> I have tried to find exactly where it's run since then, i have found the
> cmd_bc section but not found what triggers it... Due to lack of time and
> energy, I hearby report this bug!
>
> This is about as far as i got:
> kernel/Makefile:135:quiet_cmd_bc = BC $@
> kernel/Makefile:136: cmd_bc = bc -q $(filter-out FORCE,$^) > $@
Could you try this patch. Untested but I think it required to catch this bug.
diff --git a/kernel/Makefile b/kernel/Makefile
index d1574d4..18a9083 100644
--- a/kernel/Makefile
+++ b/kernel/Makefile
@@ -134,7 +134,7 @@ $(obj)/hz.bc: $(objtree)/include/config/hz.h FORCE
$(call if_changed,hzfile)
quiet_cmd_bc = BC $@
- cmd_bc = bc -q $(filter-out FORCE,$^) > $@
+ cmd_bc = bc -q $(filter-out FORCE,$^) > $@ || (rm -f $@; false)
targets += timeconst.h
$(obj)/timeconst.h: $(obj)/hz.bc $(src)/timeconst.bc FORCE
>
> Is there any detaled information and or instructions on kbuild btw?
There is some docs in Documentation/kbuild/* - but I dunno if this is
what you are after.
Sam
^ permalink raw reply related [flat|nested] 5+ messages in thread
end of thread, other threads:[~2013-05-02 20:26 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-05-02 14:44 Silent failure when missing bc Ian Kumlien
2013-05-02 16:12 ` H. Peter Anvin
2013-05-02 18:28 ` Ian Kumlien
2013-05-02 19:28 ` H. Peter Anvin
2013-05-02 20:25 ` Sam Ravnborg
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox