using-buildroot-toolchain.txt 1.6 KB

12345678910111213141516171819202122232425262728293031323334
  1. // -*- mode:doc; -*-
  2. // vim: set syntax=asciidoc:
  3. ==== Using the generated toolchain outside Buildroot
  4. You may want to compile, for your target, your own programs or other
  5. software that are not packaged in Buildroot. In order to do this you
  6. can use the toolchain that was generated by Buildroot.
  7. The toolchain generated by Buildroot is located by default in
  8. +output/host/+. The simplest way to use it is to add
  9. +output/host/bin/+ to your PATH environment variable and then to
  10. use +ARCH-linux-gcc+, +ARCH-linux-objdump+, +ARCH-linux-ld+, etc.
  11. Alternatively, Buildroot can also export the toolchain and the development
  12. files of all selected packages, as an SDK, by running the command
  13. +make sdk+. This generates a tarball of the content of the host directory
  14. +output/host/+, named +<TARGET-TUPLE>_sdk-buildroot.tar.gz+ (which can be
  15. overriden by setting the environment variable +BR2_SDK_PREFIX+) and
  16. located in the output directory +output/images/+.
  17. This tarball can then be distributed to application developers, when
  18. they want to develop their applications that are not (yet) packaged as
  19. a Buildroot package.
  20. Upon extracting the SDK tarball, the user must run the script
  21. +relocate-sdk.sh+ (located at the top directory of the SDK), to make
  22. sure all paths are updated with the new location.
  23. Alternatively, if you just want to prepare the SDK without generating
  24. the tarball (e.g. because you will just be moving the +host+ directory,
  25. or will be generating the tarball on your own), Buildroot also allows
  26. you to just prepare the SDK with +make prepare-sdk+ without actually
  27. generating a tarball.