kumquat-buildroot/docs/manual
Yann E. MORIN ba6360316f core: enhance printvars
Currently, the output of printvars copntains the name of the variable,
its expanded value and its un-expanded value.

However, most of the time, we need the actual, expanded value, so it can
be re-used from a (non-Buildroot) infrastructure script, like a
post-build script, or a build-farm driver (e.g. a Jenkins job...)

Add two options that a user may set to change the output of printvars:
  - QUOTED_VARS, if set, will quote the value
  - RAW_VARS, if set, will print the unexpanded value

The new output by default only prints the expanded value now.

So that it can be used as such:

    $ make -s printvars VARS=BUSYBOX_VERSION
    BUSYBOX_VERSION=1.26.2

    $ make -s printvars VARS=BUSYBOX_RDEPENDENCIES QUOTED_VARS=YES
    BUSYBOX_RDEPENDENCIES='ncurses util-linux'

    $ make -s printvars VARS=BUSYBOX_FINAL_PATCH_DEPENDENCIES RAW_VARS=YES
    BUSYBOX_FINAL_PATCH_DEPENDENCIES=$(sort $(BUSYBOX_PATCH_DEPENDENCIES))

And it is even possible to directly evaluate it in a shell script:

    eval $(make -s printvars VARS=BUSYBOX_VERSION QUOTED_VARS=YES)

Backward compatibility of the output is not maintained. It is believed
that scripts that depended on the previous output were very fragile to
begin with, because they had to filter the non-formatted output
(splitting on spaces or braces was not really possible, because values
could contain either).

Document printvars and its options in the manual; list it in the output
of 'make help'.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Thomas De Schampheleire <patrickdepinguin@gmail.com>
Cc: Arnout Vandecappelle <arnout@mind.be>
Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
2017-03-29 21:55:14 +02:00
..
adding-board-support.txt
adding-packages-asciidoc.txt docs/manual: document the br2-external NAME 2016-10-16 13:01:02 +02:00
adding-packages-autotools.txt
adding-packages-cmake.txt
adding-packages-conclusion.txt
adding-packages-directory.txt docs/manual: fix typo 2016-11-29 23:28:25 +01:00
adding-packages-generic.txt docs/manual: suggest 'YES' as the value for LIBFOO_GIT_SUBMODULES 2017-02-07 14:47:04 +01:00
adding-packages-gettext.txt
adding-packages-hooks.txt core/pkg-generic: allow packages to declare target-finalize hooks 2016-07-05 15:48:48 +02:00
adding-packages-kconfig.txt docs/manual: update pkg-kconfig doc about <pkg>_KCONFIG_DOTCONFIG 2016-09-17 14:46:04 +02:00
adding-packages-kernel-module.txt docs/manual: add documentation for linux-ext and linux-tools. 2015-07-14 23:35:58 +02:00
adding-packages-linux-kernel-spec-infra.txt docs/manual: update the linux tools section 2016-09-22 12:32:34 +02:00
adding-packages-luarocks.txt luarocks-package: lowercase the upstream name for LuaRocks 2017-03-05 22:01:39 +01:00
adding-packages-perl.txt pkg-perl: add PREFER_INSTALLER variable 2017-01-29 14:54:08 +01:00
adding-packages-python.txt docs/manual: fix scanpypi path typos 2016-10-19 23:39:42 +02:00
adding-packages-rebar.txt
adding-packages-tips.txt docs/manual: Modify GitHub FOO_SITE explanation 2015-07-28 23:37:39 +02:00
adding-packages-virtual.txt manual: get rid of the lists of packages 2016-09-19 19:32:59 +02:00
adding-packages-waf.txt doc/manual: document the new waf-package infra variables 2016-12-11 18:03:59 +01:00
adding-packages.txt docs/manual: document the waf-package infra 2016-12-02 22:36:49 +01:00
advanced.txt
appendix.txt docs/manual: add appendix to convert old br2-external trees 2016-10-16 13:01:02 +02:00
beyond-buildroot.txt docs/manual/beyond-buildroot: additional minor fixes 2015-07-10 19:17:02 +02:00
br2-external-converting.txt docs/manual: document multi br2-external 2016-10-16 13:01:02 +02:00
ccache-support.txt ccache: support changing the output directory 2015-10-04 18:22:21 +02:00
common-usage.txt docs/manual: centralize recommendations about BR2_DL_DIR 2017-02-07 14:55:02 +01:00
configure-other-components.txt docs/manual: add U-Boot configuration 2015-07-19 14:47:11 +02:00
configure.txt docs: update URL to uClibc-ng homepage 2016-10-14 16:49:35 +02:00
contribute.txt docs/manual: add new section about the DEVELOPERS file and get-developer 2016-09-21 09:17:58 +02:00
customize-configuration.txt docs/manual: add U-Boot configuration 2015-07-19 14:47:11 +02:00
customize-device-permission-tables.txt
customize-directory-structure.txt docs/manual: document the br2-external NAME 2016-10-16 13:01:02 +02:00
customize-outside-br.txt docs/manual: fix typo 2016-11-29 23:28:25 +01:00
customize-packages.txt docs/manual: document the br2-external NAME 2016-10-16 13:01:02 +02:00
customize-patches.txt
customize-post-image.txt
customize-quick-guide.txt docs/manual: add U-Boot configuration 2015-07-19 14:47:11 +02:00
customize-rootfs.txt docs/manual: document BR2_ROOTFS_POST_FAKEROOT_SCRIPT 2016-07-04 15:22:57 +02:00
customize-users-tables.txt
customize.txt
debugging-buildroot.txt
developers.txt docs/manual: fix typo 2016-09-22 00:02:52 +02:00
download-infra.txt
download-location.txt docs/manual: centralize recommendations about BR2_DL_DIR 2017-02-07 14:55:02 +01:00
eclipse-integration.txt
faq-troubleshooting.txt
getting.txt docs/manual: misc improvements to Vagrant usage documentation 2016-02-08 13:33:43 +01:00
how-buildroot-works.txt
introduction.txt
known-issues.txt docs/manual/known-issues: remove occurrences of eglibc 2016-06-28 22:27:27 +02:00
legal-notice.txt docs/manual: document MPL licenses 2017-03-16 16:58:04 +01:00
make-tips.txt core: enhance printvars 2017-03-29 21:55:14 +02:00
makedev-syntax.txt makedevs: add capability support 2016-06-30 12:13:38 +02:00
makeusers-syntax.txt
manual.mk manual: get rid of the lists of packages 2016-09-19 19:32:59 +02:00
manual.txt Makefile, manual: Bump copyright year 2017-01-27 19:10:22 +01:00
package-make-target.txt
patch-policy.txt docs/manual: fix patch naming convention 2016-08-09 15:45:32 +02:00
prerequisite.txt docs: Add bc to required tools 2017-01-06 12:18:30 +01:00
quickstart.txt
rebuilding-packages.txt
resources.txt docs: use lists.buildroot.org to refer to the mailman archives 2015-09-14 14:50:40 +02:00
using-buildroot-debugger.txt
using-buildroot-development.txt manual: fix typo 2016-08-19 11:25:39 +02:00
using-buildroot-toolchain.txt
writing-rules.txt Document the 72 char limit on package description. 2015-07-13 12:16:45 +02:00