kumquat-buildroot/docs/manual/adding-packages-gettext.txt
Samuel Martin 5e84b8b73c manual: rework the whole documentation stub
The new skeleton of the manual as it has been thought:
1.  About Buildroot:
     Presentation of Buildroot
2.  Starting up:
     Everything to quickly and easily start working with Buildroot
3.  Working with Buildroot
     Basics to make your work fitting your needs
4.  Troubleshooting
5.  Going further in Buildroot's innards
     Explaination of how buildroot is organised, how it works, etc
6.  Developer Guidelines
7.  Getting involved
8.  Contibuting to Buildroot
9.  Legal notice
10. Appendix

It is easy to distinguish two parts in this plan:
- Sections 1 to 4 mainly address people starting with Buildroot
- Sections 5 to 10 are more focused on how to develop Buildroot itself

Most of the existing sections have just been moved in the hierarchy,
few were split and dispatch in, what i think was the relevant section,
and numerous others have been created.

Signed-off-by: Samuel Martin <s.martin49@gmail.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
2012-11-15 23:58:38 +01:00

43 lines
1.5 KiB
Plaintext

// -*- mode:doc; -*-
Gettext integration and interaction with packages
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Many packages that support internationalization use the gettext
library. Dependencies for this library are fairly complicated and
therefore, deserves some explanation.
The 'uClibc' C library doesn't implement gettext functionality,
therefore with this C library, a separate gettext must be compiled. On
the other hand, the 'glibc' C library does integrate its own gettext,
and in this case, the separate gettext library should not be compiled,
because it creates various kinds of build failures.
Additionally, some packages (such as +libglib2+) do require gettext
unconditionally, while other packages (those who support
+--disable-nls+ in general) only require gettext when locale support
is enabled.
Therefore, Buildroot defines two configuration options:
* +BR2_NEEDS_GETTEXT+, which is true as soon as the toolchain doesn't
provide its own gettext implementation
* +BR2_NEEDS_GETTEXT_IF_LOCALE+, which is true if the toolchain
doesn't provide its own gettext implementation and if locale support
is enabled
Therefore, packages that unconditionally need gettext should:
* Use +select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT+
* Use +$(if $(BR2_NEEDS_GETTEXT),gettext)+ in the package
+DEPENDENCIES+ variable
Packages that need gettext only when locale support is enabled should:
* Use +select BR2_PACKAGE_GETTEXT if BR2_NEEDS_GETTEXT_IF_LOCALE+
* Use +$(if $(BR2_NEEDS_GETTEXT_IF_LOCALE),gettext)+ in the package
+DEPENDENCIES+ variable