getting_started.rst 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. Getting Started
  2. ===============
  3. To build Gluon, first check out the repository:
  4. ::
  5. git clone git://github.com/freifunk-gluon gluon # Get the gluon repo
  6. after that change to the source root directory:
  7. ::
  8. cd gluon # go to the recently created directory
  9. to perform the following commands:
  10. ::
  11. git clone git://github.com/freifunk-gluon/site-ffhl.git site # Get the Freifunk Lübeck site repository - or use your own!
  12. make update # Get other repositories used by Gluon
  13. make # Build Gluon
  14. When calling make, the OpenWRT build environment is prepared/updated.
  15. In case of errors read the messages carefully and try to fix the stated issues (e.g. install tools not available yet).
  16. To rebuild the images only, just use:
  17. ::
  18. make images
  19. The built images can be found in the directory `images`. Of these, the factory
  20. images are to be used when flashing from the original firmware a device came with,
  21. and sysupgrade is to upgrade from other versions of Gluon or any other OpenWRT-based
  22. system.
  23. For the build reserve 6GB of disk space. The build requires packages
  24. for `subversion`, ncurses headers (`libncurses-dev`) and zlib headers
  25. (`libz-dev`).
  26. There are two levels of `make clean`:
  27. ::
  28. make clean
  29. will ensure all packages are rebuilt; this is what you normally want to do after an update.
  30. ::
  31. make dirclean
  32. will clean the entire tree, so the toolchain will be rebuilt as well, which is
  33. not necessary in most cases, and will take a while.
  34. Environment variables
  35. ---------------------
  36. Gluon's build process can be controlled by various environment variables.
  37. GLUON_SITEDIR
  38. Path to the site configuration. Defaults to ``site/``.
  39. GLUON_IMAGEDIR
  40. Path where images will be stored. Defaults to ``images/``.
  41. GLUON_BUILDDIR
  42. Working directory during build. Defaults to ``build/``.
  43. So all in all, to update and rebuild a Gluon build tree, the following commands should be used:
  44. ::
  45. git pull
  46. (cd site && git pull)
  47. make update
  48. make clean
  49. make