sb2 - crosscompiling environment
sb2 [options] [command] [arguments] [...]
sb2 Runs command in scratchbox2. If no command is given, a bash shell
in scratchbox2 environment is started.
-v Display version number.
Enable logging. Following values for logging LEVEL are
available: error, warning, notice, info, debug, noise, noise2.
-d Use debug mode: log all redirections (logging LEVEL=debug) to
log file under directory $HOME/sb2_logs .
-h Print help.
Define TARGET to use. Use sb2-config -d TARGET to set a default.
-e Use emulation mode, avoid executing any host binaries except
Use mapping mode MODE given in argument. Following MODE values
are supported: devel, emulate, install, simple, tools.
Read mapping rules from FILE.
Use redirection rules from the DIRECTORY given in argument.
Emulate bugs of the scratchbox 1 (BUGLIST consists of letters:
'x' enables exec permission checking bug emulation).
-r Disable creating reverse mapping rules: functions like getcwd()
and realpath() will always return the real path.
Set options for the selected mapping mode. OPTIONS is a mode-
-R Execute commands in fakeroot environment.
Create a persistent session: Write session information to FILE
Join a persistent session assossiated with FILE.
Delete a persistent session assosiated with FILE. Warning: this
does not check if the session is still in use!
-c When creating a session, also create a private copy of
target_root (rootstrap). Note that this can be really slow,
depending on the size of the orig.target_root.
Use DIRECTORY as tools_root (override the value which was
specified to sb2-init when the target specification was created).
There are quite many environment variables being used. Since sb2 is
still very volatile, the best documentation is in the source of sb2
sb2 -eR make install
sb2 -R -m emulate make install
To configure sb2, do something like this:
[fetch a rootfs from somewhere and extract it here]
sb2-init -c /abs/path/to/qemu-arm TARGET /path/to/cross-compiler/bin/arm-linux-gcc
To change default scratchbox2 target:
sb2-config -d another_target
gcc(1), ld(1), fakeroot(1), No known bugs at this time.
2.0 11 September 2007 sb2(1)