buildroot/docs/manual
Thomas Devoogdt 4cf79d9b71 pkg-cmake: add option to select the Ninja generator
Cmake supports multiple generators. For now, Buildroot only uses the
venerable "GNU Makefile" generator, which generates Makefiles as the
build backend.

Cmake also has support for Ninja as a build backend, and provides the
corresponding generator. Ninja is a small build system with a focus on
speed. It is mainly used with the meson build system, but also cmake has
very good support for it.

Packages that are selecting Ninja (or over time another generator),
should also use the _BUILD_{ENV,OPTS} variables instead of the _MAKE
variables.

No _INSTALL{,_STAGING,_TARGET}_OPTS used so far, so reuse as cmake install opts:

    $ grep '_INSTALL_OPTS' $(git grep -l -E '\$\(eval \$\((host-)?cmake-package))')
    $ grep '_INSTALL_STAGING_OPTS' $(git grep -l -E '\$\(eval \$\((host-)?cmake-package))')
    $ grep '_INSTALL_TARGET_OPTS' $(git grep -l -E '\$\(eval \$\((host-)?cmake-package))')

The _MAKE_{ENV,OPTS} are copied to _BUILD_{ENV,OPTS}, involved packages:

    $ grep '_MAKE_ENV =' $(git grep -l -E '\$\(eval \$\((host-)?cmake-package))')

    package/netopeer2/netopeer2.mk:NETOPEER2_MAKE_ENV = \
    package/racehound/racehound.mk:RACEHOUND_MAKE_ENV = $(LINUX_MAKE_FLAGS)

    (qt6, webkitgtk, and wpewebkit also match, but already use -Gninja)

    $ grep '_MAKE_OPTS =' $(git grep -l -E '\$\(eval \$\((host-)?cmake-package))')

    package/mariadb/mariadb.mk:HOST_MARIADB_MAKE_OPTS = import_executables
    package/zeek/zeek.mk:HOST_ZEEK_MAKE_OPTS = binpac bifcl

Only "musepack" seems to overwrite MAKE to enforce -j1, so replace it:

    $ grep '_MAKE =' $(git grep -l -E '\$\(eval \$\((host-)?cmake-package))')

    package/musepack/musepack.mk:MUSEPACK_MAKE = $(MAKE1)

Signed-off-by: Thomas Devoogdt <thomas.devoogdt@barco.com>
Reviewed-by: John Keeping <john@metanate.com>
[yann.morin.1998@free.fr:
  - switch to FOO_CMAKE_BACKEND = (make|ninja)
  - use firstword of $(MAKE), not $(BR2_MAKE)
  - explain why we use firstword of $(MAKE)
  - update manual with the three new variables
  - yweak commit log
]
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
2023-08-06 15:38:00 +02:00
..
adding-board-support.txt doc/manual: fix formatting slightly 2023-04-16 14:33:42 +02:00
adding-packages-asciidoc.txt package/doc-asciidoc: allow docs to request a specific TOC depth 2023-04-10 21:49:22 +02:00
adding-packages-autotools.txt manual: drop LIBFOO_GETTEXTIZE, add LIBFOO_AUTOPOINT 2023-03-25 21:56:19 +01:00
adding-packages-cargo.txt package/pkg-cargo: allow building in a sub-directory 2022-03-07 22:04:54 +01:00
adding-packages-cmake.txt pkg-cmake: add option to select the Ninja generator 2023-08-06 15:38:00 +02:00
adding-packages-conclusion.txt manual: use one-line titles instead of two-line titles (trivial) 2014-05-02 10:27:59 +02:00
adding-packages-directory.txt docs/manual: document flit/pep517 python package infrastructure 2022-05-04 21:47:37 +02:00
adding-packages-generic.txt docs/manual/adding-packages-generic: remove useless carriage return 2022-02-11 10:10:18 +01:00
adding-packages-gettext.txt docs/manual: update gettext details 2017-07-05 01:37:38 +02:00
adding-packages-golang.txt docs/manual/adding-packages-golang.txt: add some details about vendoring 2022-01-08 23:35:40 +01:00
adding-packages-hooks.txt manual: add _TARGET_FINALIZE_HOOKS in the list of hooks 2022-06-04 11:30:42 +02:00
adding-packages-kconfig.txt package/pkg-kconfig: generate generic help 2021-07-25 15:20:24 +02:00
adding-packages-kernel-module.txt docs/manual: remove override in conditional 2022-03-05 17:27:04 +01:00
adding-packages-linux-kernel-spec-infra.txt package/linux-tools: change method for including linux-tool sub-makefiles 2017-07-19 21:16:38 +02:00
adding-packages-luarocks.txt package/pkg-luarocks.mk: add support of host-luarocks-package 2020-04-12 14:48:18 +02:00
adding-packages-meson.txt package/pkg-meson.mk: add FOO_MESON_EXTRA_PROPERTIES 2020-03-22 22:37:34 +01:00
adding-packages-perl.txt scancpan: add PERL_FOO_DISTNAME in perl-foo.mk 2018-10-24 00:22:13 +01:00
adding-packages-python.txt docs/manual: document flit/pep517 python package infrastructure 2022-05-04 21:47:37 +02:00
adding-packages-qmake.txt docs/manual: fix typo in name of a qmake-package variable 2021-08-28 22:48:21 +02:00
adding-packages-rebar.txt docs/manual: document <pkg>_KEEP_DEPENDENCIES in rebar-package infra 2018-12-09 17:24:29 +01:00
adding-packages-tips.txt docs/manual: add documentation for the gitlab macro 2021-03-28 22:44:57 +02:00
adding-packages-virtual.txt package/sunxi-mali-utgard: rename from sunxi-mali-mainline 2022-01-06 19:01:51 +01:00
adding-packages-waf.txt docs/manual: fix typo 2020-08-23 15:12:46 +02:00
adding-packages.txt package/pkg-qmake: new qmake package infrastructure 2020-03-09 22:26:42 +01:00
advanced.txt manual: high-level restructuring 2014-08-17 21:09:52 +02:00
appendix.txt docs/manual: add appendix about migration from older versions 2017-09-06 22:13:17 +02:00
beyond-buildroot.txt docs/manual/beyond-buildroot: additional minor fixes 2015-07-10 19:17:02 +02:00
ccache-support.txt docs/manual/ccache-support.txt: document the new BR2_USE_CCACHE variable 2022-07-30 13:45:16 +02:00
common-usage.txt docs/manual: add 'menuconfig' to out-of-tree examples 2023-02-15 22:28:58 +01:00
configure-other-components.txt docs/manual: add U-Boot configuration 2015-07-19 14:47:11 +02:00
configure.txt docs/manual: add section on start script recommendations 2022-02-06 16:35:53 +01:00
contribute.txt docs/manual: check-package before submitting patch 2023-02-06 18:54:18 +01:00
customize-configuration.txt docs/manual: fix configurations listing command 2022-06-22 22:09:26 +02:00
customize-device-permission-tables.txt manual: remove the extra whitespaces 2014-12-20 15:55:54 +01:00
customize-directory-structure.txt docs/manual: fixed some spelling mistakes 2022-12-02 20:41:13 +01:00
customize-outside-br.txt docs/manual: add section about br2-external init 2020-10-14 23:04:33 +02:00
customize-packages.txt docs/manual: document the br2-external NAME 2016-10-16 13:01:02 +02:00
customize-patches.txt docs/manual: small typo fixes and cleanup 2020-03-28 19:45:28 +01:00
customize-post-image.txt package/Makefile.in: expose CONFIG_DIR to post-build/post-image scripts 2021-05-06 22:58:54 +02:00
customize-quick-guide.txt docs/manual: add U-Boot configuration 2015-07-19 14:47:11 +02:00
customize-rootfs.txt package/Makefile.in: expose CONFIG_DIR to post-build/post-image scripts 2021-05-06 22:58:54 +02:00
customize-users-tables.txt manual/user guide/customization: add section on users tables 2014-09-21 19:41:12 +02:00
customize.txt manual/user guide/customization: rework 'step-by-step instructions' 2014-09-21 19:41:12 +02:00
debugging-buildroot.txt docs/manual: add list of instrumentation steps 2015-05-05 22:47:32 +02:00
developers.txt utils/get-developers: implement a -v action for DEVELOPERS file validation 2022-07-23 16:32:58 +02:00
download-infra.txt manual: use one-line titles instead of two-line titles (trivial) 2014-05-02 10:27:59 +02:00
download-location.txt docs/manual: centralize recommendations about BR2_DL_DIR 2017-02-07 14:55:02 +01:00
faq-troubleshooting.txt docs/manual: Remove link to emdebian and replace with debian port page 2022-03-15 22:28:01 +01:00
getting.txt docs/manual: misc improvements to Vagrant usage documentation 2016-02-08 13:33:43 +01:00
how-buildroot-works.txt manual/user guide: high-level restructuring 2014-08-21 15:39:32 +02:00
integration-selinux-support.txt docs/manual: introduce "Integration topics" chapter 2022-07-29 22:44:10 +02:00
integration-systemd.txt docs/manual: add integration section for systemd with dbus 2022-07-29 22:45:11 +02:00
integration.txt docs/manual: add integration section for systemd with dbus 2022-07-29 22:45:11 +02:00
introduction.txt manual: high-level restructuring 2014-08-17 21:09:52 +02:00
known-issues.txt Remove support for the NDS32 architecture 2022-06-19 18:30:45 +02:00
legal-notice.txt docs/manual/legal-notice.txt: update list of non-saved material 2020-01-18 18:38:40 +01:00
make-tips.txt docs/manual: Document Kconfig requirements for uboot 2022-03-07 21:36:03 +01:00
makedev-syntax.txt makedevs: add capability support 2016-06-30 12:13:38 +02:00
makeusers-syntax.txt docs/manual/makeusers-syntax.txt: add caveat for upgrading 2022-05-28 23:43:15 +02:00
manual.mk manual: get rid of the lists of packages 2016-09-19 19:32:59 +02:00
manual.txt Cleanup/simplify copyright info 2023-01-14 21:16:07 +01:00
migrating.txt docs/manual/migrating.txt: add section with general migrating tips 2021-08-05 22:01:41 +02:00
package-make-target.txt docs/manual: update package-make-target.txt with more targets 2019-01-29 00:32:11 +01:00
patch-policy.txt docs/manual: rewrite section for upstream documentation 2023-04-15 19:36:46 +02:00
prerequisite.txt docs/manual/prerequisite.txt: add findutils in dependencies 2022-08-15 22:21:33 +02:00
quickstart.txt Merge branch 'next' 2019-12-02 09:39:41 +01:00
rebuilding-packages.txt docs/manual: fix typo 2020-01-02 09:28:47 +01:00
release-engineering.txt docs/manual: new chapter on release engineering 2020-05-25 21:59:21 +02:00
resources.txt docs/manual: fix patchwork URL 2022-07-23 18:57:22 +02:00
using-buildroot-debugger.txt docs/manual/using-buildroot-debugger: suggest '-ix' iso '-x' when loading gdbinit 2021-09-21 22:43:03 +02:00
using-buildroot-development.txt docs: use-case for un-ignoring VCS directories and overridden source dir 2019-06-10 16:49:51 +02:00
using-buildroot-toolchain.txt package/environment-setup: fix spelling of the script file in the manual. 2021-01-07 23:09:47 +01:00
writing-rules.txt docs/manual: ditch redundant -f 'rm' flag 2023-03-28 21:36:07 +02:00