Abuild: Difference between revisions

From coreboot
Jump to navigation Jump to search
(Created page with 'abuild is a great tool to check whether your tree compiles for one or all targets. If you invoke abuild with no parameters, it will build all boards automatically. The resulting...')
 
m (abuild --help)
(5 intermediate revisions by 2 users not shown)
Line 1: Line 1:
abuild is a great tool to check whether your tree compiles for one or all targets.
'''abuild''' is a great tool to check whether your coreboot tree compiles for one or all targets.


If you invoke abuild with no parameters, it will build all boards automatically. The resulting images and logs will end up in the coreboot-builds/ subdirectory of the current directory.
== Basic usage ==


To build the thomson ip1000 target, run
If you invoke abuild with no parameters, it will build all boards automatically. The resulting images and logs will end up in the '''coreboot-builds/''' directory.
cd util/abuild; abuild -t thomson/ip1000
The build log will be in util/abuild/coreboot-builds/thomson_ip1000/make.log


As an alternative, you can build in the top level directory.
For example, to build the Thomson IP1000 target, run:
util/abuild/abuild -t thomson/ip1000 $PWD


You can also specify a payload directory with -p
$ '''util/abuild/abuild -t thomson/ip1000'''


mkdir payloads
The build log will be in '''coreboot-builds/thomson_ip1000/make.log'''.
cp /somewhere/filo.elf payloads
then add a file payloads/payload.sh which prints the name of the payload
to use (and takes the mainboard as a parameter)
such as
echo "`dirname $0`/build/filo.elf"


then you can build a fully working image with payload by specifying:
You can also specify a payload directory with '''-p''':


  util/abuild/abuild -t thomson/ip1000 -p ./payloads $PWD
  $ '''mkdir payloads'''
$ '''cp /somewhere/filo.elf payloads'''


Specify -c max or -c 2 if you have an SMP system, to speed compilation up.
Then add a file '''payloads/payload.sh''' which prints the name of the payload to use (and takes the mainboard as a parameter) such as:
 
$ '''echo "`dirname $0`/build/filo.elf"'''
 
Then you can build a fully working image with payload by specifying:
 
$ '''util/abuild/abuild -t thomson/ip1000 -p ./payloads'''
 
== Options ==
 
$ '''util/abuild/abuild --help'''
coreboot autobuild v0.9 (January 29th, 2010)
[...]
Usage: util/abuild/abuild [-v] [-a] [-b] [-r] [-t <vendor/board>] [-p <dir>] [lbroot]
        util/abuild/abuild [-V|--version]
        util/abuild/abuild [-h|--help]
Options:
    [-v|--verbose]                print more messages
    [-a|--all]                    build previously succeeded ports as well
    [-b|--broken]                attempt to build ports that are known broken
    [-r|--remove]                remove output dir after build
    [-t|--target <vendor/board>]  attempt to build target vendor/board only
    [-p|--payloads <dir>]        use payloads in <dir> to build images
    [-V|--version]                print version number and exit
    [-h|--help]                  print this help and exit
    [-x|--xml]                    write xml log file
                                  (defaults to abuild.xml)
    [-T|--test]                  submit image(s) to automated test system
    [-c|--cpus <numcpus>]        build on <numcpus> at the same time
    [-s|--silent]                omit compiler calls in logs
    [-ns|--nostackprotect]        use gcc -fno-stack-protector option
    [-sb|--scan-build]            use clang's static analyzer
    [-y|--ccache]                use ccache
    [-C|--config]                configure-only mode
    [-l|--loglevel <num>]        set loglevel
    [-u|--update]                update existing image
    [-P|--prefix <name>]          file name prefix in CBFS
    [lbroot]                      absolute path to coreboot sources
                                  (defaults to .)

Revision as of 20:01, 24 September 2010

abuild is a great tool to check whether your coreboot tree compiles for one or all targets.

Basic usage

If you invoke abuild with no parameters, it will build all boards automatically. The resulting images and logs will end up in the coreboot-builds/ directory.

For example, to build the Thomson IP1000 target, run:

$ util/abuild/abuild -t thomson/ip1000

The build log will be in coreboot-builds/thomson_ip1000/make.log.

You can also specify a payload directory with -p:

$ mkdir payloads
$ cp /somewhere/filo.elf payloads

Then add a file payloads/payload.sh which prints the name of the payload to use (and takes the mainboard as a parameter) such as:

$ echo "`dirname $0`/build/filo.elf"

Then you can build a fully working image with payload by specifying:

$ util/abuild/abuild -t thomson/ip1000 -p ./payloads

Options

$ util/abuild/abuild --help
coreboot autobuild v0.9 (January 29th, 2010)
[...]
Usage: util/abuild/abuild [-v] [-a] [-b] [-r] [-t <vendor/board>] [-p <dir>] [lbroot]
       util/abuild/abuild [-V|--version]
       util/abuild/abuild [-h|--help]

Options:
   [-v|--verbose]                print more messages
   [-a|--all]                    build previously succeeded ports as well
   [-b|--broken]                 attempt to build ports that are known broken
   [-r|--remove]                 remove output dir after build
   [-t|--target <vendor/board>]  attempt to build target vendor/board only
   [-p|--payloads <dir>]         use payloads in <dir> to build images
   [-V|--version]                print version number and exit
   [-h|--help]                   print this help and exit
   [-x|--xml]                    write xml log file 
                                 (defaults to abuild.xml)
   [-T|--test]                   submit image(s) to automated test system
   [-c|--cpus <numcpus>]         build on <numcpus> at the same time
   [-s|--silent]                 omit compiler calls in logs
   [-ns|--nostackprotect]        use gcc -fno-stack-protector option
   [-sb|--scan-build]            use clang's static analyzer
   [-y|--ccache]                 use ccache
   [-C|--config]                 configure-only mode
   [-l|--loglevel <num>]         set loglevel
   [-u|--update]                 update existing image
   [-P|--prefix <name>]          file name prefix in CBFS
   [lbroot]                      absolute path to coreboot sources
                                 (defaults to .)