summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2014-03-16 22:14:34 +0100
committerWaldemar Brodkorb <wbx@openadk.org>2014-03-16 22:14:34 +0100
commit732db5d2473cb5bf2c7d3e28b67e47cecf6008a8 (patch)
treef6df5d74b1f9ed8dbaa4742779f4ab2bf942622d
parent1133719749afb61faf8974c87e41c14384b03444 (diff)
parentaaa312e56871e89b97704e5ac8c686fe7966c122 (diff)
Merge branch 'master' of git+ssh://openadk.org/git/openadk
-rw-r--r--TODO15
-rw-r--r--docs/Makefile24
-rw-r--r--docs/adding-packages-auto.txt71
-rw-r--r--docs/adding-packages-conclusion.txt13
-rw-r--r--docs/adding-packages-directory.txt57
-rw-r--r--docs/adding-packages-hooks.txt31
-rw-r--r--docs/adding-packages-host.txt92
-rw-r--r--docs/adding-packages-manual.txt83
-rw-r--r--docs/adding-packages.txt25
-rw-r--r--docs/advanced.txt15
-rw-r--r--docs/appendix.txt8
-rw-r--r--docs/ccache-support.txt21
-rw-r--r--docs/common-usage.txt87
-rw-r--r--docs/configure.txt68
-rw-r--r--docs/contribute.txt87
-rw-r--r--docs/customize-busybox-config.txt20
-rw-r--r--docs/customize-kernel-config.txt48
-rw-r--r--docs/customize-libc-config.txt33
-rw-r--r--docs/customize-outside-adk.txt154
-rw-r--r--docs/customize-rootfs.txt23
-rw-r--r--docs/customize-store.txt14
-rw-r--r--docs/customize-toolchain.txt23
-rw-r--r--docs/customize.txt19
-rw-r--r--docs/debugging-openadk.txt29
-rw-r--r--docs/developer-guide.txt13
-rw-r--r--docs/download-location.txt26
-rw-r--r--docs/faq-troubleshooting.txt58
-rw-r--r--docs/getting.txt22
-rw-r--r--docs/going-further.txt9
-rw-r--r--docs/how-openadk-works.txt80
-rw-r--r--docs/images/menuconfig-configured.pngbin0 -> 341555 bytes
-rw-r--r--docs/images/menuconfig.pngbin0 -> 271731 bytes
-rw-r--r--docs/introduction.txt26
-rw-r--r--docs/legal-notice.txt51
-rw-r--r--docs/make-tips.txt99
-rw-r--r--docs/manual.txt33
-rw-r--r--docs/network-configuration.txt182
-rw-r--r--docs/package-make-target.txt52
-rw-r--r--docs/package-reference.txt135
-rw-r--r--docs/patch-policy.txt82
-rw-r--r--docs/prerequisite.txt52
-rw-r--r--docs/qemu.txt1
-rw-r--r--docs/running-openadk.txt178
-rw-r--r--docs/runtime-debugging.txt22
-rw-r--r--docs/starting-up.txt12
-rw-r--r--docs/using-openadk-development.txt62
-rw-r--r--docs/using-openadk-toolchain.txt19
-rw-r--r--docs/using.txt99
-rw-r--r--docs/working-with.txt25
-rw-r--r--docs/writing-rules.txt91
-rw-r--r--mk/build.mk11
-rw-r--r--target/tarch.lst3
52 files changed, 2495 insertions, 8 deletions
diff --git a/TODO b/TODO
index 50d1de6a8..b53457e67 100644
--- a/TODO
+++ b/TODO
@@ -1,9 +1,16 @@
-- more output for initscripts on bootup (fancy OK/FAIL with color?)
+- tzdata split + update
+- getty + serial rework
+- add daemon() function to functions.sh
+- add printing of OK/FAIL (optional verbose bootup)
+- fixup rework libgcc --export-symbols
+- libgcc static?
+- remove 32 bit kernel for 64 bit targets
+- static toolchain support
+- toolchain in /usr , check gcj
+- rework startup, maybe use init.c, start gettys after bootup ready
+- more output for initscripts on bootup
- try Preset Loops per Jiffy for faster bootup via lpj=
- port uuterm
-- move tools to package host infrastructure,
- resolve dependency handling for host tools
-- port uuterm
- hash-style=gnu for non-mips and non-musl
- add fb full screen logo
- port opkg with gpg signing
diff --git a/docs/Makefile b/docs/Makefile
new file mode 100644
index 000000000..1670e0041
--- /dev/null
+++ b/docs/Makefile
@@ -0,0 +1,24 @@
+TOPDIR=$(pwd)
+
+all: pdf text html
+
+pdf:
+ mkdir .pdf pdf
+ cp *.txt .pdf
+ cp images/*.png pdf
+ a2x -v --dblatex-opts "-P latex.output.revhistory=0" -f pdf -d book -L -D pdf .pdf/manual.txt
+
+text:
+ mkdir .text text
+ cp *.txt .text
+ cp images/*.png text
+ a2x -v -f text -d book -L -D text .text/manual.txt
+
+html:
+ mkdir .html html
+ cp *.txt .html
+ cp images/*.png html
+ a2x -v --xsltproc-opts "--stringparam toc.section.depth 2" -f xhtml -d book -L -D html .html/manual.txt
+
+clean:
+ rm -rf pdf .pdf text .text html .html
diff --git a/docs/adding-packages-auto.txt b/docs/adding-packages-auto.txt
new file mode 100644
index 000000000..ac52c395f
--- /dev/null
+++ b/docs/adding-packages-auto.txt
@@ -0,0 +1,71 @@
+// -*- mode:doc; -*-
+// vim: set syntax=asciidoc:
+
+Infrastructure for autotools-based packages
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+[[auto-package-tutorial]]
+
+First, let's see how to write a +Makefile+ file for an autotools-based
+package, with an example:
+
+------------------------
+01: # This file is part of the OpenADK project. OpenADK is copyrighted
+02: # material, please see the LICENCE file in the top-level directory.
+03:
+04: include ${TOPDIR}/rules.mk
+05:
+06: PKG_NAME:= libfoo
+07: PKG_VERSION:= 1.0
+08: PKG_RELEASE:= 1
+09: PKG_MD5SUM:= ba526cd8f4403a5d351a9efaa8608fbc
+10: PKG_DESCR:= foo library
+11: PKG_SECTION:= libs
+12: PKG_BUILDDEP:= openssl
+13: PKG_DEPENDS:= libopenssl
+14: PKG_URL:= http://www.libfoo.org/
+15: PKG_SITES:= http://downloads.libfoo.org/
+16:
+17: include ${TOPDIR}/mk/package.mk
+18:
+19: $(eval $(call PKG_template,LIBFOO,libfoo,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
+20:
+21: libfoo-install:
+22: ${INSTALL_DIR} ${IDIR_LIBFOO}/usr/lib
+23: ${CP} ${WRKINST}/usr/lib/libfoo.so* ${IDIR_LIBFOO}/usr/lib
+24:
+25: include ${TOPDIR}/mk/pkg-bottom.mk
+
+------------------------
+
+The Makefile begins with line 4 with the inclusion of the top level rules.mk
+file. After that the Makefile starts on line 6 to 15 with metadata
+information: the name of the package (+PKG_NAME+), the version of the package
+(+PKG_VERSION+), the release number of the package (+PKG_RELEASE+), which is
+used in OpenADK to mark any package updates, the md5 hash of the source archive
+(+PKG_MD5SUM+), the short one line description for the package (+PKG_DESCR+),
+the package section for the menu configuration system (+PKG_SECTION+), the
+package buildtime dependencies (+PKG_BUILDDEP+), the package runtime
+dependencies (+PKG_DEPENDS+), the package homepage (+PKG_URL+) and finally the
+internet locations at which the tarball can be downloaded from (+PKG_SITES+).
+Normally ${PKG_NAME}-${PKG_VERSION}.tar.gz will be downloaded. You can
+overwrite the default via the +DISTFILES+ variable. You can add more then one
+archive name in +DISTFILES+ via space separated. If you have no source archive
+at all, just use the boolean variable +NO_DISTFILES+ and set it to 1.
+
+On line 17 the +mk/package.mk+ file is included, which contains the PKG_template
+function, which is used in line 19.
+
+On line 21-23 we install the shared library into the package installation
+directory, which is used to create the resulting binary package or tar archive
+for the target.
+
+On line 25 we include +mk/pkg-bottom.mk+, which includes common functions used
+by the package fetching and building process.
+
+With the autotools infrastructure, all the steps required to build
+and install the packages are already defined, and they generally work
+well for most autotools-based packages. However, when required, it is
+still possible to customize what is done in any particular step.
+By adding a post-operation hook (after extract, patch, configure,
+build or install). See xref:hooks[] for details.
diff --git a/docs/adding-packages-conclusion.txt b/docs/adding-packages-conclusion.txt
new file mode 100644
index 000000000..6ec88e999
--- /dev/null
+++ b/docs/adding-packages-conclusion.txt
@@ -0,0 +1,13 @@
+// -*- mode:doc; -*-
+// vim: set syntax=asciidoc:
+
+Conclusion
+~~~~~~~~~~
+
+As you can see, adding a software package to OpenADK is simply a
+matter of writing a Makefile using an existing template and modifying it
+according to the compilation process required by the package.
+
+If you package software that might be useful for other people, don't
+forget to send a patch to the OpenADK developer (see xref:submitting-patches[])!
+
diff --git a/docs/adding-packages-directory.txt b/docs/adding-packages-directory.txt
new file mode 100644
index 000000000..347c39aa6
--- /dev/null
+++ b/docs/adding-packages-directory.txt
@@ -0,0 +1,57 @@
+// -*- mode:doc; -*-
+// vim: set syntax=asciidoc:
+
+New package
+~~~~~~~~~~~
+
+First of all, create a directory and Makefile under the +package+
+directory for your software, for example +libfoo+:
+
+------------
+ $ make newpackage PKG=libfoo VER=0.1
+------------
+
+This will create a sample Makefile for you, with a lot of comments and
+hints. It describes how the package should be downloaded, configured,
+built, installed, etc.
+
+Depending on the package type, the +Makefile+ must be written in a
+different way, using two different infrastructures:
+
+* manual package configuration
+
+* automatic package configuration using autotools
+
+
+[[dependencies-target-toolchain-options]]
+Dependencies on target and toolchain options
+
+Some packages depend on certain options of the toolchain: mainly the
+choice of C library and C++ support. Some packages can only be built on
+certain target architectures or for specific target systems.
+
+These dependencies have to be expressed in the Makefile. The given values
+are space separated and can be negated with ! as a prefix.
+
+* Target architecture
+** variable used PKG_ARCH_DEPENDS
+** allowed values are: arm, mips, .. see target/arch.lst
+
+* Target system
+** variable used PKG_SYSTEM_DEPENDS
+** for allowed values see the output of ./scripts/getsystems
+
+* Target C library
+** variable used PKG_LIBC_DEPENDS
+** allowed values are: uclibc glibc musl
+
+* Host system
+** variable used PKG_HOST_DEPENDS
+** allowed values are: linux darwin cygwin freebsd netbsd openbsd
+
+* C++ support
+** variable used PKG_NEED_CXX
+** Comment string: `C++`
+
+Further formatting details: see xref:writing-rules-mk[the writing
+rules].
diff --git a/docs/adding-packages-hooks.txt b/docs/adding-packages-hooks.txt
new file mode 100644
index 000000000..65786fbfc
--- /dev/null
+++ b/docs/adding-packages-hooks.txt
@@ -0,0 +1,31 @@
+// -*- mode:doc; -*-
+// vim: set syntax=asciidoc:
+
+[[hooks]]
+Hooks available in the various build steps
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+The infrastructure allow packages to specify hooks. These define further
+actions to perform after existing steps. Most hooks aren't really useful for
+manual packages, since the +Makefile+ already has full control over the
+actions performed in each step of the package construction.
+
+The following hook targets are available:
+
+* +post-extract+
+* +post-patch+
+* +pre-configure+
+* +post-configure+
+* +pre-build+
+* +post-build+
+* +pre-install+
+* +post-install+
+
+For example, to make some scripts executable after extraction,
+add following to your +Makefile+:
+
+---------------------
+post-extract:
+ chmod a+x $(WRKBUILD)/build/make/*.sh
+ chmod a+x $(WRKBUILD)/build/make/*.pl
+---------------------
diff --git a/docs/adding-packages-host.txt b/docs/adding-packages-host.txt
new file mode 100644
index 000000000..a858d4563
--- /dev/null
+++ b/docs/adding-packages-host.txt
@@ -0,0 +1,92 @@
+// -*- mode:doc; -*-
+// vim: set syntax=asciidoc:
+
+Infrastructure for host packages
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+[[host-package-tutorial]]
+
+First, let's see how to write a +Makefile+ for an host only package, required
+by another target package to build, with an example:
+
+------------------------
+01: # This file is part of the OpenADK project. OpenADK is copyrighted
+02: # material, please see the LICENCE file in the top-level directory.
+03:
+04: include $(TOPDIR)/rules.mk
+05:
+06: PKG_NAME:= hostfoo
+07: PKG_VERSION:= 1.0
+08: PKG_RELEASE:= 1
+09: PKG_MD5SUM:= 291ba57c0acd218da0b0916c280dcbae
+10: PKG_DESCR:= hostfoo utility
+11: PKG_SECTION:= misc
+12: PKG_URL:= http://www.foo.org/
+13: PKG_SITES:= http://download.foo.org/
+14:
+15: PKG_CFLINE_HOSTFOO:= depends on ADK_HOST_ONLY
+16:
+17: include $(TOPDIR)/mk/host.mk
+18: include $(TOPDIR)/mk/package.mk
+19:
+20: $(eval $(call HOST_template,HOSTFOO,hostfoo,$(PKG_VERSION)-${PKG_RELEASE}))
+21:
+22: HOST_STYLE:= auto
+23:
+24: include ${TOPDIR}/mk/host-bottom.mk
+25: include ${TOPDIR}/mk/pkg-bottom.mk
+------------------------
+
+The differences to a target package is the inclusion of +mk/host.mk+ in line 17 and
++mk/host-bottom.mk+ in line 24. Furthermore the HOST_template is called instead of
+the PKG_template. The last difference is the usage of +PKG_CFLINE_HOSTFOO+ to mark
+the package as host only package.
+
+Following mix between host and target package is possible, too:
+------------------------
+01: # This file is part of the OpenADK project. OpenADK is copyrighted
+02: # material, please see the LICENCE file in the top-level directory.
+03:
+04: include ${TOPDIR}/rules.mk
+05:
+06: PKG_NAME:= foo
+07: PKG_VERSION:= 1.0
+08: PKG_RELEASE:= 1
+09: PKG_MD5SUM:= 032a7b7b9f1a6e278ccde73f82cec5c2
+10: PKG_DESCR:= foo tool
+11: PKG_SECTION:= lang
+12: PKG_BUILDDEP:= foo-host
+13: PKG_URL:= http://www.foo.org/
+14: PKG_SITES:= http://download.foo.org/
+15:
+16: include ${TOPDIR}/mk/host.mk
+17: include ${TOPDIR}/mk/package.mk
+18:
+19: $(eval $(call HOST_template,FOO,foo,${PKG_VERSION}-${PKG_RELEASE}))
+20: $(eval $(call PKG_template,FOO,foo,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
+21:
+22: HOST_STYLE:= auto
+23:
+24: foo-install:
+25: ${INSTALL_DIR} ${IDIR_FOO}/usr/bin
+26: ${INSTALL_BIN} ${WRKINST}/usr/bin/foo ${IDIR_FOO}/usr/bin
+27:
+28: include ${TOPDIR}/mk/host-bottom.mk
+29: include ${TOPDIR}/mk/pkg-bottom.mk
+------------------------
+
+It is important to have foo-host as package build dependency, see line 12, so that the order is always build the host package
+and then the target package.
+If you need to rebuild a mixed package, you are advised to use:
+------------
+ $ make package=<package> clean hostpackage package
+------------
+
+At the moment there is one limitation regarding the recursive dependency resolving. It is just not implemented, yet.
+So you always need to set +PKG_BUILDDEP+ to all host tools dependencies in the right order. If package foo needs host
+tool bar, and host tool bar needs host library libbaz, you have to use following +PKG_BUILDDEP+ variable:
+------------
+ PKG_BUILDDEP:=libbaz-host bar-host
+------------
+
+
diff --git a/docs/adding-packages-manual.txt b/docs/adding-packages-manual.txt
new file mode 100644
index 000000000..b231c19fb
--- /dev/null
+++ b/docs/adding-packages-manual.txt
@@ -0,0 +1,83 @@
+// -*- mode:doc; -*-
+// vim: set syntax=asciidoc:
+
+Infrastructure for packages with specific build systems
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+By 'packages with specific build systems' we mean all the packages whose build
+system is not the standard one, speak 'autotools'. This typically includes
+packages whose build system is based on hand-written Makefiles or shell
+scripts.
+
+[[manual-package-tutorial]]
+
+------------------------------
+01: # This file is part of the OpenADK project. OpenADK is copyrighted
+02: # material, please see the LICENCE file in the top-level directory.
+03:
+04: include $(TOPDIR)/rules.mk
+05:
+06: PKG_NAME:= libfoo
+07: PKG_VERSION:= 1.0
+08: PKG_RELEASE:= 1
+09: PKG_MD5SUM:= eade38998313c25fd7934719cdf8a2ea
+10: PKG_DESCR:= foo library
+11: PKG_SECTION:= libs
+12: PKG_BUILDDEP:= openssl
+13: PKG_DEPENDS:= libopenssl
+14: PKG_URL:= http://www.libfoo.org/
+15: PKG_SITES:= http://download.libfoo.org/
+16:
+17: include $(TOPDIR)/mk/package.mk
+18:
+19: $(eval $(call PKG_template,LIBFOO,libfoo,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
+20:
+21: CONFIG_STYLE:= manual
+22: BUILD_STYLE:= manual
+23: INSTALL_STYLE:= manual
+24:
+25: do-configure:
+26: ${CP} ./files/config ${WRKBUILD}/.config
+27:
+28: do-build:
+29: ${MAKE} -C ${WRKBUILD} all
+30:
+31: do-install:
+32: ${INSTALL_DIR} ${IDIR_LIBFOO}/usr/lib
+33: ${CP} ${WRKBUILD}/libfoo.so* ${IDIR_LIBFOO}/usr/lib
+34:
+35: include ${TOPDIR}/mk/pkg-bottom.mk
+--------------------------------
+
+The Makefile begins with line 4 with the inclusion of the top level rules.mk
+file. After that the Makefile starts on line 6 to 15 with metadata
+information: the name of the package (+PKG_NAME+), the version of the package
+(+PKG_VERSION+), the release number of the package (+PKG_RELEASE+), which is
+used in OpenADK to mark any package updates, the md5 hash of the source archive
+(+PKG_MD5SUM+), the short one line description for the package (+PKG_DESCR+),
+the package section for the menu configuration system (+PKG_SECTION+), the
+package buildtime dependencies (+PKG_BUILDDEP+), the package runtime
+dependencies (+PKG_DEPENDS+), the package homepage (+PKG_URL+) and finally the
+internet locations at which the tarball can be downloaded from (+PKG_SITES+).
+Normally ${PKG_NAME}-${PKG_VERSION}.tar.gz will be downloaded. You can
+overwrite the default via the +DISTFILES+ variable. You can add more then one
+archive name in +DISTFILES+ via space separated. If you have no source archive
+at all, just use the boolean variable +NO_DISTFILES+ and set it to 1.
+
+On line 17 the +mk/package.mk+ file is included, which contains the PKG_template
+function, which is used in line 19.
+
+On line 21 to 23 we define that the configuration step, the building and install
+steps are manually provided.
+
+On line 25-26 we implement a manual configuration step of the libfoo package
+by copying a manually created config file into the build directory.
+
+On line 28-29 we start the compilation process via make.
+
+On line 31-33 we install the shared library into the package installation
+directory, which is used to create the resulting binary package or tar archive
+for the target.
+
+On line 35 we include +mk/pkg-bottom.mk+, which includes common functions used
+by the package fetching and building process.
diff --git a/docs/adding-packages.txt b/docs/adding-packages.txt
new file mode 100644
index 000000000..122ae6c3c
--- /dev/null
+++ b/docs/adding-packages.txt
@@ -0,0 +1,25 @@
+// -*- mode:doc; -*-
+// vim: set syntax=asciidoc:
+
+[[adding-packages]]
+Adding new packages to OpenADK
+------------------------------
+
+This section covers how new packages (userspace libraries or
+applications) can be integrated into OpenADK. It also shows how existing
+packages are integrated, which is needed for fixing issues or tuning
+their configuration.
+
+include::adding-packages-directory.txt[]
+
+include::adding-packages-manual.txt[]
+
+include::adding-packages-auto.txt[]
+
+include::adding-packages-host.txt[]
+
+include::adding-packages-hooks.txt[]
+
+include::adding-packages-conclusion.txt[]
+
+include::package-reference.txt[]
diff --git a/docs/advanced.txt b/docs/advanced.txt
new file mode 100644
index 000000000..4ef75e884
--- /dev/null
+++ b/docs/advanced.txt
@@ -0,0 +1,15 @@
+// -*- mode:doc; -*-
+// vim: set syntax=asciidoc:
+
+Advanced usage
+--------------
+
+include::using-openadk-toolchain.txt[]
+
+include::ccache-support.txt[]
+
+include::download-location.txt[]
+
+include::package-make-target.txt[]
+
+include::using-openadk-development.txt[]
diff --git a/docs/appendix.txt b/docs/appendix.txt
new file mode 100644
index 000000000..cf004b461
--- /dev/null
+++ b/docs/appendix.txt
@@ -0,0 +1,8 @@
+// -*- mode:doc; -*-
+// vim: set syntax=asciidoc:
+
+Appendix
+========
+
+include::network-configuration.txt[]
+
diff --git a/docs/ccache-support.txt b/docs/ccache-support.txt
new file mode 100644
index 000000000..3dfdd1fa2
--- /dev/null
+++ b/docs/ccache-support.txt
@@ -0,0 +1,21 @@
+// -*- mode:doc; -*-
+// vim: set syntax=asciidoc:
+
+[[ccache]]
+Using +ccache+ in OpenADK
+~~~~~~~~~~~~~~~~~~~~~~~~~
+
+http://ccache.samba.org[ccache] is a compiler cache. It stores the
+object files resulting from each compilation process, and is able to
+skip future compilation of the same source file (with same compiler
+and same arguments) by using the pre-existing object files. When doing
+almost identical builds from scratch a number of times, it can nicely
+speed up the build process.
+
++ccache+ support is integrated in OpenADK. You just have to enable +Use ccache
+to speedup recompilation+ in +Globale settings+. This will automatically build
++ccache+ and use it for every target compilation.
+
+The cache is located in +$HOME/.ccache+. It is stored outside of OpenADK
+directory so that it can be shared by separate OpenADK builds. If you want to
+get rid of the cache, simply remove this directory.
diff --git a/docs/common-usage.txt b/docs/common-usage.txt
new file mode 100644
index 000000000..b08475c4d
--- /dev/null
+++ b/docs/common-usage.txt
@@ -0,0 +1,87 @@
+// -*- mode:doc; -*-
+// vim: set syntax=asciidoc:
+
+Daily use
+---------
+
+Understanding when a full rebuild is necessary
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+OpenADK tries to detect what part of the system should be rebuilt when the
+system configuration is changed through +make menuconfig+. In some cases it
+automatically rebuilt packages, but sometimes just a warning is printed to the
+terminal, that a rebuild is necessary to make the changes an effect. If strange
+things are happening, the autodetection might have not worked correctly, then
+you should consider to rebuild everything. If you are following development you
+should always do a full rebuild after fetching updates via +git pull+. It is
+not always required, but if anything fails, you are on your own.
+Use following to do a full rebuild without refetching distfiles:
+
+--------------------
+ $ make cleandir && make
+--------------------
+
+Understanding how to rebuild packages
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+In OpenADK you can rebuild a single package with:
+--------------------
+ $ make package=<pkgname> clean package
+--------------------
+
+It will automatically remove all files added to the staging target directory
++target_*+. If you just want to restart compilation process, after making
+some fixes in +build_*/w-<pkgname>-<pkgversion>/+, just do:
+--------------------
+ $ make package=<pkgname> package
+--------------------
+
+If you are happy with your changes to the package sources, you can automatically
+generate a patch, which will be saved in +package/<pkgname>/patches and automatically
+applied on the next clean rebuild:
+--------------------
+ $ make package=<pkgname> update-patches
+--------------------
+
+The newly created patches will be opened in $EDITOR, so you can some comments to
+the top of the file, before the diff.
+
+
+Offline builds
+~~~~~~~~~~~~~~
+
+If you intend to do an offline build and just want to download
+all sources that you previously selected in the configurator
+then issue:
+
+--------------------
+ $ make download
+--------------------
+
+You can now disconnect or copy the content of your +dl+
+directory to the build-host.
+
+[[env-vars]]
+
+Environment variables
+~~~~~~~~~~~~~~~~~~~~~
+
+OpenADK also honors some environment variables, when they are passed
+to +make+.
+
+* +ARCH+, the architecture of the target system
+* +SYSTEM+, the target system name
+* +LIBC+, the C library for the target system
+* +COLLECT+, the package collection, which will be used
+* +VERBOSE+, verbose build, when set to 1
+
+An example that creates a configuration file for Raspberry PI with all
+software packages enabled, but not included in the resulting firmware image:
+
+--------------------
+ $ make ARCH=arm SYSTEM=raspberry-pi LIBC=musl allmodconfig
+--------------------
+
+This is often used in the development process of a target system, to verify that
+all packages are compilable.
+
diff --git a/docs/configure.txt b/docs/configure.txt
new file mode 100644
index 000000000..3fadc1f48
--- /dev/null
+++ b/docs/configure.txt
@@ -0,0 +1,68 @@
+// -*- mode:doc; -*-
+// vim: set syntax=asciidoc:
+
+[[toolchain]]
+
+Cross-compilation toolchain
+---------------------------
+
+A compilation toolchain is the set of tools that allows you to compile
+code for your system. It consists of a compiler (in our case, +gcc+),
+binary utils like assembler and linker (in our case, +binutils+) and a
+C standard library (either
+http://www.gnu.org/software/libc/libc.html[GNU Libc],
+http://www.uclibc.org/[uClibc] or
+http://www.musl-libc.org/[musl]).
+
+The system installed on your development station certainly already has
+a compilation toolchain that you can use to compile an application
+that runs on your system. If you're using a PC, your compilation
+toolchain runs on an x86 processor and generates code for an x86
+processor. Under most Linux systems, the compilation toolchain uses
+the GNU libc (glibc) as the C standard library. This compilation
+toolchain is called the "host compilation toolchain". The machine on
+which it is running, and on which you're working, is called the "host
+system" footnote:[This terminology differs from what is used by GNU
+configure, where the host is the machine on which the application will
+run (which is usually the same as target)].
+
+The compilation toolchain is provided by your distribution, and
+OpenADK has nothing to do with it (other than using it to build a
+cross-compilation toolchain and other tools that are run on the
+development host).
+
+As said above, the compilation toolchain that comes with your system
+runs on and generates code for the processor in your host system. As