On Thursday 16 September 2010 07:52:02 walter harms wrote:
> Harald Becker schrieb:
> >  Hi!
> >
> >> NTL the main problem here is that the missing "od" is detected but the
> >> script is continuing only to fail otherwise.
> >
> > True. That's the topic, I'm not complaining about if od is required or
> > not. Just that the build succeeded and didn't just abort at that point,
> > with a possible command not found message from make/shell. I don't
> > expect any error handling. Just abort and say failure ... and not
> > success ... resulting in confusion, when busybox fails with a
> > segmentation fault when just doing a xxx --help ... which let to hours
> > of searching for what has gone wrong :-(
>
> I just want to clear that there are two problems.
>
> 1. check that every think is there what is need to compile bb

The definition of what you need to compile bb is "compiling bb".  Requirements 
may come, and requirements may go, and keeping an external tool in sync by 
hand is useless impedence matching effort when THE BUILD BREAKS.

Also, you want to keep requirements to a minimum in general.  I can already 
trivially test what busybox actually calls with the record-commands.sh wrapper 
in my aboriginal linux build, which gives me a list of every command line run 
by the build.  Wash that through "awk '{print $1}' | sort -u" and you've got 
the commands needed by the build:

  more/record-commands &&
  more/test.sh build_section i686 busybox &&
  more/report-recorded-commands

For 1.17.2 it says:

  as awk bzip2 cat chmod cp cut dd echo find gcc grep head ld ln ls make mkdir
  mv od rm sed sha1sum sleep sort tail touch uname uniq xargs

(This is not specific to busybox, I can test any package build that way.)

> 2. what to do if something is found missing
>
> my idea is to have a script like
>
> which --version >/dev/null || { echo "i need which" ; exit ; }
> for CMD in od
> do
>  which $CMD || { echo "i need $CMD" ; exit ; }
> done
>
> this can be executed manually and its done. I guess that is what denis had
> in mind.

"Let me plant this acorn, it's small and doesn't take up much space."

Camel's nose.  Tent flap.  Please don't go there.

Rob
-- 
GPLv3: as worthy a successor as The Phantom Menace, as timely as Duke Nukem 
Forever, and as welcome as New Coke.
_______________________________________________
busybox mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/busybox

Reply via email to