* [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages @ 2022-01-12 13:26 Adrian Perez de Castro 2022-01-12 13:26 ` [Buildroot] [PATCH RFC 1/2] package/ninja: do not require cmake Adrian Perez de Castro ` (4 more replies) 0 siblings, 5 replies; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-12 13:26 UTC (permalink / raw) To: buildroot; +Cc: Eric Le Bihan, Samuel Martin, Thomas Petazzoni Hello everybody, As discussed yesterday, here is a quick stab for testing and getting the conversation started about using Ninja for CMake-based packages (hence the missing documentation updates and the "RFC" tag in the subject :-D). In order to avoid the circular dependency of host-ninja requiring itself, ninja.mk gets changed to use host-generic-package with a build command that plainly runs the compiler on the set of sources we know are needed to build a minimal usable version of it under Unix-y systems. This is basically the list of sources that CMake would have picked (as per the CMakeLists.txt file) passed straight to $(HOSTCXX). The next change modifies pkg-cmake.mk to always pass -GNinja and removes the $(<PKG>_INSTALL[_STAGING,_TARGET]_OPTS) variables, because when using Ninja the "install/fast" targets are not generated by CMake (those are an internal detail of the Makefile generator, it seems). For consistency with the Meson package infrastructure variables $(NINJA), $(<PKG>_NINJA_ENV) and $(NINJA_OPTS) are honored by the default set of build/install commands. Now, there might be packages that break with this, and I would be particularly concerned about things like packages which use CMake and build out-of-tree kernel modules (as the kernel build infrastructure is all Make, and only Make!) but the changes included were enough for me to get Raspberry Pi images built with WebKit (both GTK and WPE ports) in it, which results in the following built using [host-]cmake-package: - brotli - cog - jpeg-turbo - openjpeg - webkitgtk - webp - woff2 - wpewebkit While not a long list by any means, I think it shows a decent sample of packages coming from different development teams that work just fine switching to Ninja. If anybody can suggest something with a bigger number of CMake packages to build (or a .config file to share) I will be more than happy to give it a test this with these patches applied :) Cheers, -Adrian Adrian Perez de Castro (2): package/ninja: do not require cmake package/pkg-cmake.mk: use ninja instead of make package/ninja/ninja.mk | 36 +++++++++++++++++++++++++++++++++++- package/pkg-cmake.mk | 24 ++++++++++++++---------- 2 files changed, 49 insertions(+), 11 deletions(-) -- 2.34.1 _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* [Buildroot] [PATCH RFC 1/2] package/ninja: do not require cmake 2022-01-12 13:26 [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro @ 2022-01-12 13:26 ` Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro 2022-01-12 13:26 ` [Buildroot] [PATCH RFC 2/2] package/pkg-cmake.mk: use ninja instead of make Adrian Perez de Castro ` (3 subsequent siblings) 4 siblings, 1 reply; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-12 13:26 UTC (permalink / raw) To: buildroot; +Cc: Eric Le Bihan, Samuel Martin, Thomas Petazzoni Use host-generic-package to manually build ninja. This avoids the need for host-cmake in preparation for the CMake build system machinery being changed to use ninja instead of make. Signed-off-by: Adrian Perez de Castro <aperez@igalia.com> --- package/ninja/ninja.mk | 36 +++++++++++++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) diff --git a/package/ninja/ninja.mk b/package/ninja/ninja.mk index ab1941023e..ae3be6a14f 100644 --- a/package/ninja/ninja.mk +++ b/package/ninja/ninja.mk @@ -9,8 +9,42 @@ NINJA_SITE = $(call github,ninja-build,ninja,v$(NINJA_VERSION)) NINJA_LICENSE = Apache-2.0 NINJA_LICENSE_FILES = COPYING +# Ninja is used by CMake-based packages, avoid a circular dependency by +# by using host-generic-package instead and using a single command to +# compile the binary. This does in essence the same as the "bootstrap.py" +# included in the distribution avoiding the need for host-python. +define HOST_NINJA_BUILD_CMDS + cd $(@D) && $(HOSTCXX) $(HOST_CXXFLAGS) $(HOST_LDFLAGS) \ + src/build_log.cc \ + src/build.cc \ + src/clean.cc \ + src/clparser.cc \ + src/dyndep.cc \ + src/dyndep_parser.cc \ + src/debug_flags.cc \ + src/deps_log.cc \ + src/disk_interface.cc \ + src/edit_distance.cc \ + src/eval_env.cc \ + src/graph.cc \ + src/graphviz.cc \ + src/line_printer.cc \ + src/manifest_parser.cc \ + src/metrics.cc \ + src/parser.cc \ + src/state.cc \ + src/string_piece_util.cc \ + src/util.cc \ + src/version.cc \ + src/depfile_parser.cc \ + src/lexer.cc \ + src/subprocess-posix.cc \ + src/ninja.cc \ + -o ninja +endef + define HOST_NINJA_INSTALL_CMDS $(INSTALL) -m 0755 -D $(@D)/ninja $(HOST_DIR)/bin/ninja endef -$(eval $(host-cmake-package)) +$(eval $(host-generic-package)) -- 2.34.1 _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply related [flat|nested] 25+ messages in thread
* [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages 2022-01-12 13:26 ` [Buildroot] [PATCH RFC 1/2] package/ninja: do not require cmake Adrian Perez de Castro @ 2022-01-21 15:42 ` Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 1/7] package/ninja: do not require cmake Adrian Perez de Castro ` (7 more replies) 0 siblings, 8 replies; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-21 15:42 UTC (permalink / raw) To: buildroot Cc: Eric Le Bihan, Pierre Ducroquet, Samuel Martin, Peter Seiderer, Thomas Petazzoni Hi all, Here's a new version of the patch set to use Ninja for all CMake packages. It is still incomplete (missing documentation, a couple of commits need better commit logs, etc.) so I will be still using the "RFC" tag =) This is what I wrote when I sent the initial version: > In order to avoid the circular dependency of host-ninja requiring itself, > ninja.mk gets changed to use host-generic-package with a build command > that plainly runs the compiler on the set of sources we know are needed > to build a minimal usable version of it under Unix-y systems. This is > basically the list of sources that CMake would have picked (as per the > CMakeLists.txt file) passed straight to $(HOSTCXX). > > The next change modifies pkg-cmake.mk to always pass -GNinja and removes > the $(<PKG>_INSTALL[_STAGING,_TARGET]_OPTS) variables, because when using > Ninja the "install/fast" targets are not generated by CMake (those are > an internal detail of the Makefile generator, it seems). For consistency > with the Meson package infrastructure variables $(NINJA), $(<PKG>_NINJA_ENV) > and $(NINJA_OPTS) are honored by the default set of build/install commands. While the main changes remain the same, this v2 includes a few fixes for packages which were needed to make them build using Ninja, and much more testing: out of the 306 packages which use CMake today, I have been able to successfully have 205 of them built. I will follow-up with another email commenting more on this, and with a defconfig attached. At this point I am confident that we can get all the packages built with CMake without loss of functionality. Only 5 packages out of 205 needing minor tweaks is a *very* good sign, IMO. Cheers, -Adrian Adrian Perez de Castro (7): package/ninja: do not require cmake package/pkg-cmake.mk: use ninja instead of make package/musepack: use MUSEPACK_NINJA_OPTS package/mariadb: use HOST_MARIADB_NINJA_OPTS package/kf5/kf5-extra-cmake-modules: do not build documentation package/libcorrect: avoid multiple rules for same target package/racehound: add patch to support building with ninja .../kf5-extra-cmake-modules.mk | 5 + package/libcorrect/libcorrect.mk | 2 + package/mariadb/mariadb.mk | 2 +- package/musepack/musepack.mk | 2 +- package/ninja/ninja.mk | 36 +++++- package/pkg-cmake.mk | 24 ++-- ...pport-non-Make-generators-e.g.-Ninja.patch | 112 ++++++++++++++++++ 7 files changed, 170 insertions(+), 13 deletions(-) create mode 100644 package/racehound/0002-CMake-Support-non-Make-generators-e.g.-Ninja.patch -- 2.34.1 _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* [Buildroot] [PATCH RFC v2 1/7] package/ninja: do not require cmake 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro @ 2022-01-21 15:42 ` Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 2/7] package/pkg-cmake.mk: use ninja instead of make Adrian Perez de Castro ` (6 subsequent siblings) 7 siblings, 0 replies; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-21 15:42 UTC (permalink / raw) To: buildroot Cc: Eric Le Bihan, Pierre Ducroquet, Samuel Martin, Peter Seiderer, Thomas Petazzoni Use host-generic-package to manually build ninja. This avoids the need for host-cmake in preparation for the CMake build system machinery being changed to use ninja instead of make. Signed-off-by: Adrian Perez de Castro <aperez@igalia.com> --- Changes v1 -> v2: - No changes. --- package/ninja/ninja.mk | 36 +++++++++++++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) diff --git a/package/ninja/ninja.mk b/package/ninja/ninja.mk index ab1941023e..ae3be6a14f 100644 --- a/package/ninja/ninja.mk +++ b/package/ninja/ninja.mk @@ -9,8 +9,42 @@ NINJA_SITE = $(call github,ninja-build,ninja,v$(NINJA_VERSION)) NINJA_LICENSE = Apache-2.0 NINJA_LICENSE_FILES = COPYING +# Ninja is used by CMake-based packages, avoid a circular dependency by +# by using host-generic-package instead and using a single command to +# compile the binary. This does in essence the same as the "bootstrap.py" +# included in the distribution avoiding the need for host-python. +define HOST_NINJA_BUILD_CMDS + cd $(@D) && $(HOSTCXX) $(HOST_CXXFLAGS) $(HOST_LDFLAGS) \ + src/build_log.cc \ + src/build.cc \ + src/clean.cc \ + src/clparser.cc \ + src/dyndep.cc \ + src/dyndep_parser.cc \ + src/debug_flags.cc \ + src/deps_log.cc \ + src/disk_interface.cc \ + src/edit_distance.cc \ + src/eval_env.cc \ + src/graph.cc \ + src/graphviz.cc \ + src/line_printer.cc \ + src/manifest_parser.cc \ + src/metrics.cc \ + src/parser.cc \ + src/state.cc \ + src/string_piece_util.cc \ + src/util.cc \ + src/version.cc \ + src/depfile_parser.cc \ + src/lexer.cc \ + src/subprocess-posix.cc \ + src/ninja.cc \ + -o ninja +endef + define HOST_NINJA_INSTALL_CMDS $(INSTALL) -m 0755 -D $(@D)/ninja $(HOST_DIR)/bin/ninja endef -$(eval $(host-cmake-package)) +$(eval $(host-generic-package)) -- 2.34.1 _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply related [flat|nested] 25+ messages in thread
* [Buildroot] [PATCH RFC v2 2/7] package/pkg-cmake.mk: use ninja instead of make 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 1/7] package/ninja: do not require cmake Adrian Perez de Castro @ 2022-01-21 15:42 ` Adrian Perez de Castro 2022-07-24 13:16 ` Arnout Vandecappelle 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 3/7] package/musepack: use MUSEPACK_NINJA_OPTS Adrian Perez de Castro ` (5 subsequent siblings) 7 siblings, 1 reply; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-21 15:42 UTC (permalink / raw) To: buildroot Cc: Eric Le Bihan, Pierre Ducroquet, Samuel Martin, Peter Seiderer, Thomas Petazzoni Switch to ninja as the build tool for the CMake package infrastructure. Note that the changes make packages which use [host-]cmake-package depend on host-ninja. Signed-off-by: Adrian Perez de Castro <aperez@igalia.com> --- Changes v1 -> v2: - No changes. --- package/pkg-cmake.mk | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/package/pkg-cmake.mk b/package/pkg-cmake.mk index 3b1db35fb6..65f005a914 100644 --- a/package/pkg-cmake.mk +++ b/package/pkg-cmake.mk @@ -51,11 +51,6 @@ endif define inner-cmake-package -$(2)_MAKE ?= $$(MAKE) -$(2)_INSTALL_OPTS ?= install -$(2)_INSTALL_STAGING_OPTS ?= DESTDIR=$$(STAGING_DIR) install/fast -$(2)_INSTALL_TARGET_OPTS ?= DESTDIR=$$(TARGET_DIR) install/fast - $(3)_SUPPORTS_IN_SOURCE_BUILD ?= YES @@ -88,6 +83,7 @@ define $(2)_CONFIGURE_CMDS rm -f CMakeCache.txt && \ PATH=$$(BR_PATH) \ $$($$(PKG)_CONF_ENV) $$(BR2_CMAKE) $$($$(PKG)_SRCDIR) \ + -GNinja \ -DCMAKE_TOOLCHAIN_FILE="$$(HOST_DIR)/share/buildroot/toolchainfile.cmake" \ -DCMAKE_INSTALL_PREFIX="/usr" \ -DCMAKE_COLOR_MAKEFILE=OFF \ @@ -117,6 +113,7 @@ define $(2)_CONFIGURE_CMDS PKG_CONFIG_ALLOW_SYSTEM_CFLAGS=1 \ PKG_CONFIG_ALLOW_SYSTEM_LIBS=1 \ $$($$(PKG)_CONF_ENV) $$(BR2_CMAKE) $$($$(PKG)_SRCDIR) \ + -GNinja \ -DCMAKE_INSTALL_SO_NO_EXE=0 \ -DCMAKE_FIND_ROOT_PATH="$$(HOST_DIR)" \ -DCMAKE_FIND_ROOT_PATH_MODE_PROGRAM="BOTH" \ @@ -154,6 +151,8 @@ endif # primitives to find {C,LD}FLAGS, add it to the dependency list. $(2)_DEPENDENCIES += host-pkgconf +$(2)_DEPENDENCIES += host-ninja + $(2)_DEPENDENCIES += $(BR2_CMAKE_HOST_DEPENDENCY) # @@ -163,11 +162,13 @@ $(2)_DEPENDENCIES += $(BR2_CMAKE_HOST_DEPENDENCY) ifndef $(2)_BUILD_CMDS ifeq ($(4),target) define $(2)_BUILD_CMDS - $$(TARGET_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) -C $$($$(PKG)_BUILDDIR) + $$(TARGET_MAKE_ENV) $$($$(PKG)_NINJA_ENV) \ + $$(NINJA) $$(NINJA_OPTS) $$($$(PKG)_NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) endef else define $(2)_BUILD_CMDS - $$(HOST_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) -C $$($$(PKG)_BUILDDIR) + $$(HOST_MAKE_ENV) $$($$(PKG)_NINJA_ENV) \ + $$(NINJA) $$(NINJA_OPTS) $$($$(PKG)_NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) endef endif endif @@ -178,7 +179,8 @@ endif # ifndef $(2)_INSTALL_CMDS define $(2)_INSTALL_CMDS - $$(HOST_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) $$($$(PKG)_INSTALL_OPTS) -C $$($$(PKG)_BUILDDIR) + $$(HOST_MAKE_ENV) $$($$(PKG)_NINJA_ENV) \ + $$(NINJA) $$(NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) install endef endif @@ -188,7 +190,8 @@ endif # ifndef $(2)_INSTALL_STAGING_CMDS define $(2)_INSTALL_STAGING_CMDS - $$(TARGET_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) $$($$(PKG)_INSTALL_STAGING_OPTS) -C $$($$(PKG)_BUILDDIR) + $$(TARGET_MAKE_ENV) $$($$(PKG)_NINJA_ENV) DESTDIR=$$(STAGING_DIR) \ + $$(NINJA) $$(NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) install endef endif @@ -198,7 +201,8 @@ endif # ifndef $(2)_INSTALL_TARGET_CMDS define $(2)_INSTALL_TARGET_CMDS - $$(TARGET_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) $$($$(PKG)_INSTALL_TARGET_OPTS) -C $$($$(PKG)_BUILDDIR) + $$(TARGET_MAKE_ENV) $$($$(PKG)_NINJA_ENV) DESTDIR=$$(TARGET_DIR) \ + $$(NINJA) $$(NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) install endef endif -- 2.34.1 _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply related [flat|nested] 25+ messages in thread
* Re: [Buildroot] [PATCH RFC v2 2/7] package/pkg-cmake.mk: use ninja instead of make 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 2/7] package/pkg-cmake.mk: use ninja instead of make Adrian Perez de Castro @ 2022-07-24 13:16 ` Arnout Vandecappelle 0 siblings, 0 replies; 25+ messages in thread From: Arnout Vandecappelle @ 2022-07-24 13:16 UTC (permalink / raw) To: Adrian Perez de Castro, buildroot Cc: Eric Le Bihan, Peter Seiderer, Samuel Martin, Thomas Petazzoni, Pierre Ducroquet On 21/01/2022 16:42, Adrian Perez de Castro wrote: > Switch to ninja as the build tool for the CMake package infrastructure. > Note that the changes make packages which use [host-]cmake-package > depend on host-ninja. > > Signed-off-by: Adrian Perez de Castro <aperez@igalia.com> > --- > Changes v1 -> v2: > - No changes. > --- > package/pkg-cmake.mk | 24 ++++++++++++++---------- > 1 file changed, 14 insertions(+), 10 deletions(-) > > diff --git a/package/pkg-cmake.mk b/package/pkg-cmake.mk > index 3b1db35fb6..65f005a914 100644 > --- a/package/pkg-cmake.mk > +++ b/package/pkg-cmake.mk > @@ -51,11 +51,6 @@ endif > > define inner-cmake-package > > -$(2)_MAKE ?= $$(MAKE) > -$(2)_INSTALL_OPTS ?= install > -$(2)_INSTALL_STAGING_OPTS ?= DESTDIR=$$(STAGING_DIR) install/fast > -$(2)_INSTALL_TARGET_OPTS ?= DESTDIR=$$(TARGET_DIR) install/fast > - > $(3)_SUPPORTS_IN_SOURCE_BUILD ?= YES > > > @@ -88,6 +83,7 @@ define $(2)_CONFIGURE_CMDS > rm -f CMakeCache.txt && \ > PATH=$$(BR_PATH) \ > $$($$(PKG)_CONF_ENV) $$(BR2_CMAKE) $$($$(PKG)_SRCDIR) \ > + -GNinja \ > -DCMAKE_TOOLCHAIN_FILE="$$(HOST_DIR)/share/buildroot/toolchainfile.cmake" \ > -DCMAKE_INSTALL_PREFIX="/usr" \ > -DCMAKE_COLOR_MAKEFILE=OFF \ > @@ -117,6 +113,7 @@ define $(2)_CONFIGURE_CMDS > PKG_CONFIG_ALLOW_SYSTEM_CFLAGS=1 \ > PKG_CONFIG_ALLOW_SYSTEM_LIBS=1 \ > $$($$(PKG)_CONF_ENV) $$(BR2_CMAKE) $$($$(PKG)_SRCDIR) \ > + -GNinja \ > -DCMAKE_INSTALL_SO_NO_EXE=0 \ > -DCMAKE_FIND_ROOT_PATH="$$(HOST_DIR)" \ > -DCMAKE_FIND_ROOT_PATH_MODE_PROGRAM="BOTH" \ > @@ -154,6 +151,8 @@ endif > # primitives to find {C,LD}FLAGS, add it to the dependency list. > $(2)_DEPENDENCIES += host-pkgconf > > +$(2)_DEPENDENCIES += host-ninja Ah, crap, I forgot this one... Maybe it's better after all to add $(2)_CMAKE_GENERATOR ?= Ninja ifeq ($($(2)_CMAKE_GENERATOR),Ninja) $(2)_DEPENDENCIES += host-ninja endif > + > $(2)_DEPENDENCIES += $(BR2_CMAKE_HOST_DEPENDENCY) > > # > @@ -163,11 +162,13 @@ $(2)_DEPENDENCIES += $(BR2_CMAKE_HOST_DEPENDENCY) > ifndef $(2)_BUILD_CMDS > ifeq ($(4),target) > define $(2)_BUILD_CMDS > - $$(TARGET_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) -C $$($$(PKG)_BUILDDIR) > + $$(TARGET_MAKE_ENV) $$($$(PKG)_NINJA_ENV) \ > + $$(NINJA) $$(NINJA_OPTS) $$($$(PKG)_NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) If cmake is used here instead of ninja directly, it doesn't make sense to have a global <PKG>_CMAKE_OPTS (or whatever) any more, because the options for --build are completely different from those of --install. It does, however, make sense to add <PKG>_BUILD_OPTS, <PKG>_INSTALL_TARGET_OPTS, etc. (which we do have for a couple of other infras already). But that is pretty independent of this series. Regards, Arnout > endef > else > define $(2)_BUILD_CMDS > - $$(HOST_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) -C $$($$(PKG)_BUILDDIR) > + $$(HOST_MAKE_ENV) $$($$(PKG)_NINJA_ENV) \ > + $$(NINJA) $$(NINJA_OPTS) $$($$(PKG)_NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) > endef > endif > endif > @@ -178,7 +179,8 @@ endif > # > ifndef $(2)_INSTALL_CMDS > define $(2)_INSTALL_CMDS > - $$(HOST_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) $$($$(PKG)_INSTALL_OPTS) -C $$($$(PKG)_BUILDDIR) > + $$(HOST_MAKE_ENV) $$($$(PKG)_NINJA_ENV) \ > + $$(NINJA) $$(NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) install > endef > endif > > @@ -188,7 +190,8 @@ endif > # > ifndef $(2)_INSTALL_STAGING_CMDS > define $(2)_INSTALL_STAGING_CMDS > - $$(TARGET_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) $$($$(PKG)_INSTALL_STAGING_OPTS) -C $$($$(PKG)_BUILDDIR) > + $$(TARGET_MAKE_ENV) $$($$(PKG)_NINJA_ENV) DESTDIR=$$(STAGING_DIR) \ > + $$(NINJA) $$(NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) install > endef > endif > > @@ -198,7 +201,8 @@ endif > # > ifndef $(2)_INSTALL_TARGET_CMDS > define $(2)_INSTALL_TARGET_CMDS > - $$(TARGET_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) $$($$(PKG)_INSTALL_TARGET_OPTS) -C $$($$(PKG)_BUILDDIR) > + $$(TARGET_MAKE_ENV) $$($$(PKG)_NINJA_ENV) DESTDIR=$$(TARGET_DIR) \ > + $$(NINJA) $$(NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) install > endef > endif > _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* [Buildroot] [PATCH RFC v2 3/7] package/musepack: use MUSEPACK_NINJA_OPTS 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 1/7] package/ninja: do not require cmake Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 2/7] package/pkg-cmake.mk: use ninja instead of make Adrian Perez de Castro @ 2022-01-21 15:42 ` Adrian Perez de Castro 2022-07-24 13:18 ` Arnout Vandecappelle 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 4/7] package/mariadb: use HOST_MARIADB_NINJA_OPTS Adrian Perez de Castro ` (4 subsequent siblings) 7 siblings, 1 reply; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-21 15:42 UTC (permalink / raw) To: buildroot Cc: Eric Le Bihan, Pierre Ducroquet, Samuel Martin, Peter Seiderer, Thomas Petazzoni Replace the usage of MUSEPACK_MAKE with MUSEPACK_NINJA_OPTS to disable the parallel build. Unfortunately switching to Ninja for building CMake packages has not solved the parallel build issues. Signed-off-by: Adrian Perez de Castro <aperez@igalia.com> --- Changes v1 -> v2: - Tweak muspack package to disallow parallel builds with Ninja. --- package/musepack/musepack.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package/musepack/musepack.mk b/package/musepack/musepack.mk index fc66c684a5..000db5fd76 100644 --- a/package/musepack/musepack.mk +++ b/package/musepack/musepack.mk @@ -9,8 +9,8 @@ MUSEPACK_SITE = http://files.musepack.net/source MUSEPACK_SOURCE = musepack_src_$(MUSEPACK_VERSION).tar.gz MUSEPACK_DEPENDENCIES = libcuefile libreplaygain MUSEPACK_INSTALL_STAGING = YES -MUSEPACK_MAKE = $(MAKE1) MUSEPACK_LICENSE = BSD-3-Clause (*mpcdec), LGPL-2.1+ (*mpcenc) MUSEPACK_LICENSE_FILES = libmpcdec/COPYING libmpcenc/quant.c +MUSEPACK_NINJA_OPTS = -j1 $(eval $(cmake-package)) -- 2.34.1 _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply related [flat|nested] 25+ messages in thread
* Re: [Buildroot] [PATCH RFC v2 3/7] package/musepack: use MUSEPACK_NINJA_OPTS 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 3/7] package/musepack: use MUSEPACK_NINJA_OPTS Adrian Perez de Castro @ 2022-07-24 13:18 ` Arnout Vandecappelle 0 siblings, 0 replies; 25+ messages in thread From: Arnout Vandecappelle @ 2022-07-24 13:18 UTC (permalink / raw) To: Adrian Perez de Castro, buildroot Cc: Eric Le Bihan, Peter Seiderer, Samuel Martin, Thomas Petazzoni, Pierre Ducroquet On 21/01/2022 16:42, Adrian Perez de Castro wrote: > Replace the usage of MUSEPACK_MAKE with MUSEPACK_NINJA_OPTS to disable > the parallel build. Unfortunately switching to Ninja for building CMake > packages has not solved the parallel build issues. > > Signed-off-by: Adrian Perez de Castro <aperez@igalia.com> > --- > Changes v1 -> v2: > - Tweak muspack package to disallow parallel builds with Ninja. > --- > package/musepack/musepack.mk | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/package/musepack/musepack.mk b/package/musepack/musepack.mk > index fc66c684a5..000db5fd76 100644 > --- a/package/musepack/musepack.mk > +++ b/package/musepack/musepack.mk > @@ -9,8 +9,8 @@ MUSEPACK_SITE = http://files.musepack.net/source > MUSEPACK_SOURCE = musepack_src_$(MUSEPACK_VERSION).tar.gz > MUSEPACK_DEPENDENCIES = libcuefile libreplaygain > MUSEPACK_INSTALL_STAGING = YES > -MUSEPACK_MAKE = $(MAKE1) > MUSEPACK_LICENSE = BSD-3-Clause (*mpcdec), LGPL-2.1+ (*mpcenc) > MUSEPACK_LICENSE_FILES = libmpcdec/COPYING libmpcenc/quant.c > +MUSEPACK_NINJA_OPTS = -j1 Ah, right, for something like this we *do* need <PKG>_BUILD_OPTS... Regards, Arnout > > $(eval $(cmake-package)) _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* [Buildroot] [PATCH RFC v2 4/7] package/mariadb: use HOST_MARIADB_NINJA_OPTS 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro ` (2 preceding siblings ...) 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 3/7] package/musepack: use MUSEPACK_NINJA_OPTS Adrian Perez de Castro @ 2022-01-21 15:42 ` Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 5/7] package/kf5/kf5-extra-cmake-modules: do not build documentation Adrian Perez de Castro ` (3 subsequent siblings) 7 siblings, 0 replies; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-21 15:42 UTC (permalink / raw) To: buildroot Cc: Eric Le Bihan, Pierre Ducroquet, Samuel Martin, Peter Seiderer, Thomas Petazzoni Replace usage of HOST_MARIADB_MAKE_OPTS with HOST_MARIADB_NINJA_OPTS. Signed-off-by: Adrian Perez de Castro <aperez@igalia.com> --- Changes v1 -> v2: - Tweeak to use CMake+Ninja infra. --- package/mariadb/mariadb.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package/mariadb/mariadb.mk b/package/mariadb/mariadb.mk index db967ca3ed..d24174dd74 100644 --- a/package/mariadb/mariadb.mk +++ b/package/mariadb/mariadb.mk @@ -101,7 +101,7 @@ HOST_MARIADB_CONF_OPTS += -DWITH_SSL=system # -DIMPORT_EXECUTABLES=$(HOST_MARIADB_BUILDDIR)/import_executables.cmake # must then be passed to cmake during target build. # see also https://mariadb.com/kb/en/mariadb/cross-compiling-mariadb/ -HOST_MARIADB_MAKE_OPTS = import_executables +HOST_MARIADB_NINJA_OPTS = import_executables MARIADB_CONF_OPTS += \ -DIMPORT_EXECUTABLES=$(HOST_MARIADB_BUILDDIR)/import_executables.cmake -- 2.34.1 _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply related [flat|nested] 25+ messages in thread
* [Buildroot] [PATCH RFC v2 5/7] package/kf5/kf5-extra-cmake-modules: do not build documentation 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro ` (3 preceding siblings ...) 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 4/7] package/mariadb: use HOST_MARIADB_NINJA_OPTS Adrian Perez de Castro @ 2022-01-21 15:42 ` Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 6/7] package/libcorrect: avoid multiple rules for same target Adrian Perez de Castro ` (2 subsequent siblings) 7 siblings, 0 replies; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-21 15:42 UTC (permalink / raw) To: buildroot Cc: Eric Le Bihan, Pierre Ducroquet, Samuel Martin, Peter Seiderer, Thomas Petazzoni Pass needed CMake options to disable generating documentations. The documentation is built using python-sphinx, which is not packaged in Buildroot. Prior to this change, if the build host would have a Python installation with the sphinx module installed the automatic detection tried to build documentation, which would fail in cases where the sphinxcontrib-qthelp package is missing from the host Python installation. The error message in this case was: Extension error: Could not import extension ecm (exception: cannot import name 'htmlescape' from 'sphinx.util.pycompat' (/usr/lib/python3.10/site-packages/sphinx/util/pycompat.py)) Signed-off-by: Adrian Perez de Castro <aperez@igalia.com> --- Changes v1 -> v2: - Add CMake options to skip trying to build documentation. --- .../kf5/kf5-extra-cmake-modules/kf5-extra-cmake-modules.mk | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/package/kf5/kf5-extra-cmake-modules/kf5-extra-cmake-modules.mk b/package/kf5/kf5-extra-cmake-modules/kf5-extra-cmake-modules.mk index 3c4281b960..ba2748456e 100644 --- a/package/kf5/kf5-extra-cmake-modules/kf5-extra-cmake-modules.mk +++ b/package/kf5/kf5-extra-cmake-modules/kf5-extra-cmake-modules.mk @@ -14,4 +14,9 @@ KF5_EXTRA_CMAKE_MODULES_DEPENDENCIES = host-pkgconf KF5_EXTRA_CMAKE_MODULES_INSTALL_STAGING = YES KF5_EXTRA_CMAKE_MODULES_INSTALL_TARGET = NO +KF5_EXTRA_CMAKE_MODULES_CONF_OPTS += \ + -DBUILD_HTML_DOCS=OFF \ + -DBUILD_MAN_DOCS=OFF \ + -DBUILD_QTHELP_DOCS=OFF + $(eval $(cmake-package)) -- 2.34.1 _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply related [flat|nested] 25+ messages in thread
* [Buildroot] [PATCH RFC v2 6/7] package/libcorrect: avoid multiple rules for same target 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro ` (4 preceding siblings ...) 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 5/7] package/kf5/kf5-extra-cmake-modules: do not build documentation Adrian Perez de Castro @ 2022-01-21 15:42 ` Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 7/7] package/racehound: add patch to support building with ninja Adrian Perez de Castro 2022-01-21 15:53 ` [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro 7 siblings, 0 replies; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-21 15:42 UTC (permalink / raw) To: buildroot Cc: Eric Le Bihan, Pierre Ducroquet, Samuel Martin, Peter Seiderer, Thomas Petazzoni Signed-off-by: Adrian Perez de Castro <aperez@igalia.com> --- Changes v1 -> v2: - Avoid CMake generating two targets with the same name. Needs a better fix sent upstream to tweak CMakeLists.txt instead. --- package/libcorrect/libcorrect.mk | 2 ++ 1 file changed, 2 insertions(+) diff --git a/package/libcorrect/libcorrect.mk b/package/libcorrect/libcorrect.mk index 0a84aa5c26..225111a64f 100644 --- a/package/libcorrect/libcorrect.mk +++ b/package/libcorrect/libcorrect.mk @@ -10,4 +10,6 @@ LIBCORRECT_LICENSE = BSD-3-Clause LIBCORRECT_LICENSE_FILES = LICENSE LIBCORRECT_INSTALL_STAGING = YES +LIBCORRECT_CONF_OPTS += -DBUILD_SHARED_LIBS=OFF + $(eval $(cmake-package)) -- 2.34.1 _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply related [flat|nested] 25+ messages in thread
* [Buildroot] [PATCH RFC v2 7/7] package/racehound: add patch to support building with ninja 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro ` (5 preceding siblings ...) 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 6/7] package/libcorrect: avoid multiple rules for same target Adrian Perez de Castro @ 2022-01-21 15:42 ` Adrian Perez de Castro 2022-01-21 15:53 ` [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro 7 siblings, 0 replies; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-21 15:42 UTC (permalink / raw) To: buildroot Cc: Eric Le Bihan, Pierre Ducroquet, Samuel Martin, Peter Seiderer, Thomas Petazzoni SSIA. Signed-off-by: Adrian Perez de Castro <aperez@igalia.com> Upstream-Status: https://github.com/euspectre/racehound/pull/6 --- Changes v1 -> v2: - Patch added to call into Kbuild with plain make. --- ...pport-non-Make-generators-e.g.-Ninja.patch | 112 ++++++++++++++++++ 1 file changed, 112 insertions(+) create mode 100644 package/racehound/0002-CMake-Support-non-Make-generators-e.g.-Ninja.patch diff --git a/package/racehound/0002-CMake-Support-non-Make-generators-e.g.-Ninja.patch b/package/racehound/0002-CMake-Support-non-Make-generators-e.g.-Ninja.patch new file mode 100644 index 0000000000..7f90fb8c69 --- /dev/null +++ b/package/racehound/0002-CMake-Support-non-Make-generators-e.g.-Ninja.patch @@ -0,0 +1,112 @@ +From f8d266b017fd76e2de9d20e0bb3951a5338075d1 Mon Sep 17 00:00:00 2001 +From: Adrian Perez de Castro <aperez@igalia.com> +Date: Fri, 14 Jan 2022 14:33:21 +0200 +Subject: [PATCH] CMake: Support non-Make generators, e.g. Ninja + +--- + cmake/modules/FindKbuild.cmake | 15 +++++++++++++-- + cmake/modules/kbuild_system.cmake | 4 ++-- + cmake/modules/kmodule_files/CMakeLists.txt | 11 +++++++++-- + core/tests/common_target/CMakeLists.txt | 2 +- + 4 files changed, 25 insertions(+), 7 deletions(-) + +diff --git a/cmake/modules/FindKbuild.cmake b/cmake/modules/FindKbuild.cmake +index b79d140..2ba0a78 100644 +--- a/cmake/modules/FindKbuild.cmake ++++ b/cmake/modules/FindKbuild.cmake +@@ -5,6 +5,7 @@ + # (often /lib/modules/${KBUILD_VERSION_STRING}/build) + # KBUILD_INCLUDE_DIR - not used + # KBUILD_FOUND - TRUE if everything is correct, FALSE otherwise ++# KBUILD_MAKE_COMMAND - Command to run for Make invocations. + + if (NOT KBUILD_VERSION_STRING) + set(KBUILD_VERSION_STRING ${CMAKE_SYSTEM_VERSION} CACHE STRING +@@ -18,8 +19,18 @@ endif (NOT KBUILD_BUILD_DIR) + + set(KBUILD_INCLUDE_DIRS "NOT USED") + +-# Note: only KBUILD_BUILD_DIR variable is really used in the project. +-# Other variables defined only for FindModule architecture of CMake. ++# Only makefiles have $(MAKE) defined, in other cases invoke make directly. ++if (CMAKE_GENERATOR STREQUAL "Unix Makefiles") ++ set(KBUILD_MAKE_COMMAND $\(MAKE\)) ++else () ++ find_program(KBUILD_MAKE_COMMAND make REQUIRED) ++ set(KBUILD_MAKE_COMMAND ${KBUILD_MAKE_COMMAND} CC=${CMAKE_C_COMPILER} CFLAGS=${CMAKE_C_FLAGS}) ++endif () ++ ++ ++# Note: only KBUILD_BUILD_DIR and KBUILD_MAKE_COMMAND variables are really ++# used in the project. Other variables defined only for FindModule ++# architecture of CMake. + + # Handle the QUIETLY and REQUIRED arguments and set KBUILD_FOUND to TRUE if + # all listed variables are TRUE +diff --git a/cmake/modules/kbuild_system.cmake b/cmake/modules/kbuild_system.cmake +index e28ef33..e4e33df 100644 +--- a/cmake/modules/kbuild_system.cmake ++++ b/cmake/modules/kbuild_system.cmake +@@ -262,13 +262,13 @@ function(kbuild_add_module name) + > "${_dir}.${_name}.o.cmd") + endforeach(shipped_source_noext_abs ${shipped_source_noext_abs}) + endif(shipped_sources_noext_abs) +- ++ + # The rule to create module + add_custom_command( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/${name}.ko ${symvers_file} + ${cmd_create_command} + ${symvers_command} +- COMMAND $(MAKE) -C ${KBUILD_BUILD_DIR} ++ COMMAND ${KBUILD_MAKE_COMMAND} -C ${KBUILD_BUILD_DIR} + M=${CMAKE_CURRENT_BINARY_DIR} modules + DEPENDS ${depend_files} + ) +diff --git a/cmake/modules/kmodule_files/CMakeLists.txt b/cmake/modules/kmodule_files/CMakeLists.txt +index 1147cc5..6115153 100644 +--- a/cmake/modules/kmodule_files/CMakeLists.txt ++++ b/cmake/modules/kmodule_files/CMakeLists.txt +@@ -5,7 +5,7 @@ if (NOT KERNELDIR) + set(KERNELDIR /lib/modules/${KBUILD_VERSION_STRING}/build) + endif (NOT KERNELDIR) + +-set(PWD $\(shell pwd\)) ++set(PWD $$\(pwd\)) + + project(kmodule_try_compile) + # Create rule for produce file from another file via copiing +@@ -27,9 +27,16 @@ if(COPY_FILE) + copy_file("${COPY_FILE}" "${CMAKE_CURRENT_BINARY_DIR}/try_compile.ko") + endif(COPY_FILE) + ++# Only makefiles have $(MAKE) defined, in other cases invoke make directly. ++if (CMAKE_GENERATOR STREQUAL "Unix Makefiles") ++ set(KBUILD_MAKE_COMMAND $\(MAKE\)) ++else () ++ find_program(KBUILD_MAKE_COMMAND make REQUIRED) ++endif () ++ + # Rule to produce try_compile.ko from try_compile.c + add_custom_command(OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/try_compile.ko" +- COMMAND $(MAKE) -C ${KERNELDIR} M=${PWD} modules ++ COMMAND ${KBUILD_MAKE_COMMAND} -C ${KERNELDIR} M=${PWD} modules + DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/try_compile.c") + + # Kbuild system cannot work with out-of-source build, +diff --git a/core/tests/common_target/CMakeLists.txt b/core/tests/common_target/CMakeLists.txt +index cf257ad..fe48e68 100644 +--- a/core/tests/common_target/CMakeLists.txt ++++ b/core/tests/common_target/CMakeLists.txt +@@ -17,7 +17,7 @@ add_custom_target("common_target_module" + + add_custom_command( + OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/${KMODULE_NAME}.ko" +- COMMAND $(MAKE) -f module.makefile ++ COMMAND ${KBUILD_MAKE_COMMAND} -f module.makefile + DEPENDS + "${CMAKE_CURRENT_BINARY_DIR}/cfake.c" + "${CMAKE_CURRENT_BINARY_DIR}/cfake.h" +-- +2.34.1 + -- 2.34.1 _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply related [flat|nested] 25+ messages in thread
* Re: [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro ` (6 preceding siblings ...) 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 7/7] package/racehound: add patch to support building with ninja Adrian Perez de Castro @ 2022-01-21 15:53 ` Adrian Perez de Castro 7 siblings, 0 replies; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-21 15:53 UTC (permalink / raw) To: buildroot Cc: Eric Le Bihan, Peter Seiderer, Samuel Martin, Thomas Petazzoni, Pierre Ducroquet [-- Attachment #1.1.1: Type: text/plain, Size: 2788 bytes --] Hello, On Fri, 21 Jan 2022 17:42:28 +0200 Adrian Perez de Castro <aperez@igalia.com> wrote: > Here's a new version of the patch set to use Ninja for all CMake packages. > It is still incomplete (missing documentation, a couple of commits need > better commit logs, etc.) so I will be still using the "RFC" tag =) > > This is what I wrote when I sent the initial version: > > > In order to avoid the circular dependency of host-ninja requiring itself, > > ninja.mk gets changed to use host-generic-package with a build command > > that plainly runs the compiler on the set of sources we know are needed > > to build a minimal usable version of it under Unix-y systems. This is > > basically the list of sources that CMake would have picked (as per the > > CMakeLists.txt file) passed straight to $(HOSTCXX). > > > > The next change modifies pkg-cmake.mk to always pass -GNinja and removes > > the $(<PKG>_INSTALL[_STAGING,_TARGET]_OPTS) variables, because when using > > Ninja the "install/fast" targets are not generated by CMake (those are > > an internal detail of the Makefile generator, it seems). For consistency > > with the Meson package infrastructure variables $(NINJA), $(<PKG>_NINJA_ENV) > > and $(NINJA_OPTS) are honored by the default set of build/install commands. > > While the main changes remain the same, this v2 includes a few fixes for > packages which were needed to make them build using Ninja, and much more > testing: out of the 306 packages which use CMake today, I have been able to > successfully have 205 of them built. I will follow-up with another email > commenting more on this, and with a defconfig attached. > > At this point I am confident that we can get all the packages built with > CMake without loss of functionality. Only 5 packages out of 205 needing > minor tweaks is a *very* good sign, IMO. You can find two files attached to this mail: - v2-status.txt: lists all the CMake packages, marked with the following symbols: - [ ] - Package not yet tested. - [*] - Package tested, builds fine unchanged. - [=] - Package tested, builds with changes/patches applied. - [?] - Package tested, failed to build but the failure does not seem caused from switching from Make to Ninja. - qemu_x86_64_cmakeninja1_defconfig: a defconfig that can be used to build all the packages marked with [*] from the status list. I will need some other different defconfigs to test some of the packages, because they may be platform specific (like rpi-firmware) or need options enabled which conflict with other packages from the list. My plan is to continue in the next weeks and slowly get to the point where all the CMake packages can be built using Ninja, using the minimum amount of defconfigs possible. Cheers, -Adrian [-- Attachment #1.1.2: qemu_x86_64_cmakeninja1_defconfig --] [-- Type: text/plain, Size: 6656 bytes --] BR2_x86_64=y BR2_CCACHE=y BR2_OPTIMIZE_2=y BR2_SSP_ALL=y BR2_FORTIFY_SOURCE_2=y BR2_TOOLCHAIN_BUILDROOT_GLIBC=y BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_5_15=y BR2_TOOLCHAIN_BUILDROOT_CXX=y BR2_TOOLCHAIN_BUILDROOT_FORTRAN=y BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV=y BR2_SYSTEM_DHCP="eth0" BR2_ROOTFS_POST_BUILD_SCRIPT="board/qemu/x86_64/post-build.sh" BR2_ROOTFS_POST_IMAGE_SCRIPT="board/qemu/post-image.sh" BR2_ROOTFS_POST_SCRIPT_ARGS="$(BR2_DEFCONFIG)" BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_VERSION=y BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="5.15" BR2_LINUX_KERNEL_USE_CUSTOM_CONFIG=y BR2_LINUX_KERNEL_CUSTOM_CONFIG_FILE="board/qemu/x86_64/linux.config" BR2_LINUX_KERNEL_NEEDS_HOST_LIBELF=y BR2_PACKAGE_BUSYBOX_SHOW_OTHERS=y BR2_PACKAGE_FLUIDSYNTH=y BR2_PACKAGE_FLUIDSYNTH_SDL2=y BR2_PACKAGE_GSTREAMER1=y # BR2_PACKAGE_GSTREAMER1_GST_DEBUG is not set BR2_PACKAGE_GST1_PLUGINS_BASE=y BR2_PACKAGE_MUSEPACK=y BR2_PACKAGE_YMPD=y BR2_PACKAGE_UNZIP=y BR2_PACKAGE_SENTRY_NATIVE=y BR2_PACKAGE_TCF_AGENT=y BR2_PACKAGE_JQ=y BR2_PACKAGE_FIRMWARE_UTILS=y BR2_PACKAGE_UNIONFS=y BR2_PACKAGE_FLARE_ENGINE=y BR2_PACKAGE_FLARE_GAME=y BR2_PACKAGE_LUGARU=y BR2_PACKAGE_MINETEST=y BR2_PACKAGE_SOLARUS=y BR2_PACKAGE_SUPERTUX=y BR2_PACKAGE_SUPERTUXKART=y BR2_PACKAGE_MESA3D_DEMOS=y BR2_PACKAGE_MIDORI=y BR2_PACKAGE_CEGUI=y BR2_PACKAGE_FREERDP=y BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_CROCUS=y BR2_PACKAGE_MESA3D_VULKAN_DRIVER_INTEL=y BR2_PACKAGE_MESA3D_OPENGL_GLX=y BR2_PACKAGE_MESA3D_OPENGL_EGL=y BR2_PACKAGE_MESA3D_OPENGL_ES=y BR2_PACKAGE_SDL2_KMSDRM=y BR2_PACKAGE_SDL2_OPENGLES=y BR2_PACKAGE_VULKAN_HEADERS=y BR2_PACKAGE_QT5=y BR2_PACKAGE_QT5BASE_OPENGL=y BR2_PACKAGE_QT5BASE_OPENGL_ES2=y BR2_PACKAGE_QT5BASE_PNG=y BR2_PACKAGE_QT5BASE_ICU=y BR2_PACKAGE_QT5LOCATION=y BR2_PACKAGE_QT5SENSORS=y BR2_PACKAGE_QT5TOOLS=y BR2_PACKAGE_QT5TOOLS_LINGUIST_TOOLS=y BR2_PACKAGE_CUTELYST=y BR2_PACKAGE_GRANTLEE=y BR2_PACKAGE_KF5=y BR2_PACKAGE_KF5_MODEMMANAGER_QT=y BR2_PACKAGE_KF5_NETWORKMANAGER_QT=y BR2_PACKAGE_QJSON=y BR2_PACKAGE_SIMPLE_MAIL=y BR2_PACKAGE_XORG7=y BR2_PACKAGE_XSERVER_XORG_SERVER=y BR2_PACKAGE_XDRIVER_XF86_INPUT_LIBINPUT=y BR2_PACKAGE_XDRIVER_XF86_VIDEO_INTEL=y BR2_PACKAGE_APITRACE=y BR2_PACKAGE_BRICKD=y BR2_PACKAGE_CDRKIT=y BR2_PACKAGE_LIBIEC61850=y BR2_PACKAGE_LINUX_SERIAL_TEST=y BR2_PACKAGE_OPENFPGALOADER=y BR2_PACKAGE_OPENPOWERLINK=y BR2_PACKAGE_READ_EDID=y BR2_PACKAGE_UBUS=y BR2_PACKAGE_LUAJIT_COMPAT52=y BR2_PACKAGE_EASYDBUS=y BR2_PACKAGE_LUA_EV=y BR2_PACKAGE_LUA_SDL2=y BR2_PACKAGE_LUVI=y BR2_PACKAGE_PYTHON3_BZIP2=y BR2_PACKAGE_PYTHON3_PYEXPAT=y BR2_PACKAGE_PYTHON3_XZ=y BR2_PACKAGE_PYTHON3_ZLIB=y BR2_PACKAGE_PYTHON_FLATBUFFERS=y BR2_PACKAGE_PYTHON_MAKO=y BR2_PACKAGE_PYTHON_PAHO_MQTT=y BR2_PACKAGE_PYTHON_PYBIND=y BR2_PACKAGE_ALURE=y BR2_PACKAGE_BCG729=y BR2_PACKAGE_LIBASPLIB=y BR2_PACKAGE_LIBCODEC2=y BR2_PACKAGE_LIBCUE=y BR2_PACKAGE_LIBEBUR128=y BR2_PACKAGE_LIBSOXR=y BR2_PACKAGE_SPEEXDSP=y BR2_PACKAGE_TAGLIB=y BR2_PACKAGE_SNAPPY=y BR2_PACKAGE_ZLIB_NG=y BR2_PACKAGE_ZZIPLIB=y BR2_PACKAGE_LIBOLM=y BR2_PACKAGE_LIBSSH=y BR2_PACKAGE_LIBSSH_SERVER=y BR2_PACKAGE_LIBUECC=y BR2_PACKAGE_USTREAM_SSL=y BR2_PACKAGE_CPPDB=y BR2_PACKAGE_LEVELDB=y BR2_PACKAGE_LIBGIT2=y BR2_PACKAGE_LIBMDBX=y BR2_PACKAGE_LIBMDBX_CXX=y BR2_PACKAGE_MYSQL=y BR2_PACKAGE_MARIADB=y BR2_PACKAGE_EXIV2=y BR2_PACKAGE_GRAPHITE2=y BR2_PACKAGE_INTEL_MEDIASDK=y BR2_PACKAGE_JASPER=y BR2_PACKAGE_LENSFUN=y BR2_PACKAGE_LENSFUN_TOOLS=y BR2_PACKAGE_LIBGTA=y BR2_PACKAGE_LIBGTK3=y # BR2_PACKAGE_LIBGTK3_BROADWAY is not set BR2_PACKAGE_OPENCV4=y BR2_PACKAGE_OPENCV4_LIB_FLANN=y BR2_PACKAGE_OPENCV4_JPEG2000_WITH_OPENJPEG=y BR2_PACKAGE_POPPLER=y BR2_PACKAGE_POPPLER_QT5=y BR2_PACKAGE_WAFFLE=y BR2_PACKAGE_WAYLANDPP=y BR2_PACKAGE_ZXING_CPP=y BR2_PACKAGE_C_PERIPHERY=y BR2_PACKAGE_HACKRF=y BR2_PACKAGE_LET_ME_CREATE=y BR2_PACKAGE_LIBCEC=y BR2_PACKAGE_LIBFTDI1_LIBFTDIPP1=y BR2_PACKAGE_LIBIIO=y BR2_PACKAGE_LIBIQRF=y BR2_PACKAGE_LIBSIGROK=y BR2_PACKAGE_LIBSIGROKCXX=y BR2_PACKAGE_MRAA=y BR2_PACKAGE_CJSON=y BR2_PACKAGE_JSON_FOR_MODERN_CPP=y BR2_PACKAGE_RAPIDJSON=y BR2_PACKAGE_TINYXML2=y BR2_PACKAGE_VALIJSON=y BR2_PACKAGE_XERCES=y BR2_PACKAGE_YAJL=y BR2_PACKAGE_YAML_CPP=y BR2_PACKAGE_GLOG=y BR2_PACKAGE_LOG4CXX=y BR2_PACKAGE_LOG4QT=y BR2_PACKAGE_BENTO4=y BR2_PACKAGE_LIBMATROSKA=y BR2_PACKAGE_LIBYUV=y BR2_PACKAGE_X265=y BR2_PACKAGE_X265_CLI=y BR2_PACKAGE_AZURE_IOT_SDK_C=y BR2_PACKAGE_CURLPP=y BR2_PACKAGE_GRPC=y BR2_PACKAGE_LIBCGI=y # BR2_PACKAGE_LIBCURL_EXTRA_PROTOCOLS_FEATURES is not set BR2_PACKAGE_LIBCURL_MBEDTLS=y BR2_PACKAGE_LIBMINIUPNPC=y BR2_PACKAGE_LIBNETCONF2=y BR2_PACKAGE_LIBRSYNC=y BR2_PACKAGE_LIBUHTTPD=y BR2_PACKAGE_LIBURIPARSER=y BR2_PACKAGE_LIBUWSC=y BR2_PACKAGE_LIBVNCSERVER=y BR2_PACKAGE_NANOMSG=y BR2_PACKAGE_PAHO_MQTT_CPP=y BR2_PACKAGE_PISTACHE=y BR2_PACKAGE_QPID_PROTON=y BR2_PACKAGE_RABBITMQ_C=y BR2_PACKAGE_SYSREPO=y BR2_PACKAGE_THRIFT=y BR2_PACKAGE_WAMPCC=y BR2_PACKAGE_WEBSOCKETPP=y BR2_PACKAGE_ARMADILLO=y BR2_PACKAGE_AVRO_C=y BR2_PACKAGE_BOOST_RANDOM=y BR2_PACKAGE_CCTZ=y BR2_PACKAGE_CEREAL=y BR2_PACKAGE_CLANG=y BR2_PACKAGE_CMOCKA=y BR2_PACKAGE_EIGEN=y BR2_PACKAGE_ELFUTILS=y BR2_PACKAGE_FLANN=y BR2_PACKAGE_FLATCC=y BR2_PACKAGE_GFLAGS=y BR2_PACKAGE_GLI=y BR2_PACKAGE_GTEST=y BR2_PACKAGE_GTEST_GMOCK=y BR2_PACKAGE_LIBB64=y BR2_PACKAGE_LIBCORRECT=y BR2_PACKAGE_LIBEASTL=y BR2_PACKAGE_LIBGEOS=y BR2_PACKAGE_LIBICAL=y BR2_PACKAGE_LIBKS=y BR2_PACKAGE_LIBOSMIUM=y BR2_PACKAGE_LIBSPATIALINDEX=y BR2_PACKAGE_LIBUCI=y BR2_PACKAGE_MSGPACK=y BR2_PACKAGE_QHULL=y BR2_PACKAGE_UVW=y BR2_PACKAGE_UTF8PROC=y BR2_PACKAGE_COLLECTD=y BR2_PACKAGE_COLLECTD_REDIS=y BR2_PACKAGE_GNURADIO_CTRLPORT=y BR2_PACKAGE_GNURADIO_DTV=y BR2_PACKAGE_GNURADIO_PYTHON=y BR2_PACKAGE_GNURADIO_UTILS=y BR2_PACKAGE_GNURADIO_ZEROMQ=y BR2_PACKAGE_GNURADIO_CHANNELS=y BR2_PACKAGE_GNURADIO_QTGUI=y BR2_PACKAGE_GNURADIO_TRELLIS=y BR2_PACKAGE_GNURADIO_UHD=y BR2_PACKAGE_GQRX=y BR2_PACKAGE_GR_OSMOSDR_PYTHON=y BR2_PACKAGE_GR_OSMOSDR_IQFILE=y BR2_PACKAGE_GR_OSMOSDR_RTLSDR=y BR2_PACKAGE_GR_OSMOSDR_RTLSDR_TCP=y BR2_PACKAGE_GR_OSMOSDR_RFSPACE=y BR2_PACKAGE_RTL_433=y BR2_PACKAGE_TASKD=y BR2_PACKAGE_CANNELLONI=y BR2_PACKAGE_EASYFRAMES=y BR2_PACKAGE_GERBERA=y BR2_PACKAGE_HIAWATHA=y BR2_PACKAGE_I2PD=y BR2_PACKAGE_LINPHONE=y BR2_PACKAGE_MJPG_STREAMER=y BR2_PACKAGE_MRP=y BR2_PACKAGE_NETWORK_MANAGER=y BR2_PACKAGE_NETWORK_MANAGER_TUI=y BR2_PACKAGE_NETWORK_MANAGER_MODEM_MANAGER=y BR2_PACKAGE_ODHCP6C=y BR2_PACKAGE_OPENOBEX=y BR2_PACKAGE_SNORT3=y BR2_PACKAGE_SPICE_PROTOCOL=y BR2_PACKAGE_UHTTPD=y BR2_PACKAGE_UQMI=y BR2_PACKAGE_ZNC=y BR2_PACKAGE_RTTY=y BR2_PACKAGE_TTYD=y BR2_PACKAGE_UTIL_LINUX_BINARIES=y BR2_PACKAGE_HOST_E2FSPROGS=y BR2_PACKAGE_HOST_FATCAT=y BR2_PACKAGE_HOST_LLD=y BR2_PACKAGE_HOST_QEMU_SYSTEM_MODE=y [-- Attachment #1.1.3: v2-status.txt --] [-- Type: text/plain, Size: 11588 bytes --] [*] package/alure/alure.mk [*] package/apitrace/apitrace.mk [*] package/armadillo/armadillo.mk [*] package/avro-c/avro-c.mk [*] package/azure-iot-sdk-c/azure-iot-sdk-c.mk [*] package/bcg729/bcg729.mk [*] package/bctoolbox/bctoolbox.mk [*] package/belle-sip/belle-sip.mk [*] package/belr/belr.mk [*] package/bento4/bento4.mk [*] package/brickd/brickd.mk [*] package/brotli/brotli.mk [*] package/c-periphery/c-periphery.mk [*] package/cannelloni/cannelloni.mk [*] package/cctz/cctz.mk [*] package/cdrkit/cdrkit.mk [*] package/cegui/cegui.mk [*] package/cereal/cereal.mk [*] package/cfm/cfm.mk [*] package/cjson/cjson.mk [*] package/clang/clang.mk [*] package/cmake/cmake.mk [*] package/cmocka/cmocka.mk [*] package/cog/cog.mk [*] package/cppdb/cppdb.mk [*] package/cppzmq/cppzmq.mk [*] package/curlpp/curlpp.mk [*] package/cutelyst/cutelyst.mk [*] package/doxygen/doxygen.mk [*] package/easydbus/easydbus.mk [*] package/easyframes/easyframes.mk [*] package/eigen/eigen.mk [*] package/exiv2/exiv2.mk [*] package/fatcat/fatcat.mk [*] package/firmware-utils/firmware-utils.mk [*] package/flann/flann.mk [*] package/flare-engine/flare-engine.mk [*] package/flare-game/flare-game.mk [*] package/flatbuffers/flatbuffers.mk [*] package/flatcc/flatcc.mk [*] package/fluidsynth/fluidsynth.mk [*] package/fmt/fmt.mk [*] package/freerdp/freerdp.mk [*] package/gerbera/gerbera.mk [*] package/gflags/gflags.mk [*] package/gli/gli.mk [*] package/glm/glm.mk [*] package/glog/glog.mk [*] package/gnuradio/gnuradio.mk [*] package/gqrx/gqrx.mk [*] package/gr-osmosdr/gr-osmosdr.mk [*] package/grantlee/grantlee.mk [*] package/graphite2/graphite2.mk [*] package/grpc/grpc.mk [*] package/gtest/gtest.mk [*] package/hackrf/hackrf.mk [*] package/hiawatha/hiawatha.mk [*] package/hiredis/hiredis.mk [*] package/i2pd/i2pd.mk [*] package/intel-gmmlib/intel-gmmlib.mk [*] package/intel-mediadriver/intel-mediadriver.mk [*] package/intel-mediasdk/intel-mediasdk.mk [*] package/jasper/jasper.mk [*] package/jpeg-turbo/jpeg-turbo.mk [*] package/json-c/json-c.mk [*] package/json-for-modern-cpp/json-for-modern-cpp.mk [*] package/kf5/kf5-extra-cmake-modules/kf5-extra-cmake-modules.mk [*] package/kf5/kf5-kcoreaddons/kf5-kcoreaddons.mk [*] package/kf5/kf5-modemmanager-qt/kf5-modemmanager-qt.mk [*] package/kf5/kf5-networkmanager-qt/kf5-networkmanager-qt.mk [*] package/lapack/lapack.mk [*] package/lensfun/lensfun.mk [*] package/let-me-create/let-me-create.mk [*] package/leveldb/leveldb.mk [*] package/libabseil-cpp/libabseil-cpp.mk [*] package/libasplib/libasplib.mk [*] package/libcec/libcec.mk [*] package/libcgi/libcgi.mk [*] package/libcodec2/libcodec2.mk [*] package/libcue/libcue.mk [*] package/libcuefile/libcuefile.mk [*] package/libeastl/libeastl.mk [*] package/libebml/libebml.mk [*] package/libebur128/libebur128.mk [*] package/libftdi1/libftdi1.mk [*] package/libgeos/libgeos.mk [*] package/libgit2/libgit2.mk [*] package/libgta/libgta.mk [*] package/libical/libical.mk [*] package/libiec61850/libiec61850.mk [*] package/libiio/libiio.mk [*] package/libiqrf/libiqrf.mk [*] package/libks/libks.mk [*] package/libmatroska/libmatroska.mk [*] package/libmdbx/libmdbx.mk [*] package/libminiupnpc/libminiupnpc.mk [*] package/libnetconf2/libnetconf2.mk [*] package/libolm/libolm.mk [*] package/libosmium/libosmium.mk [*] package/libplatform/libplatform.mk [*] package/librsync/librsync.mk [*] package/librtlsdr/librtlsdr.mk [*] package/libssh/libssh.mk [*] package/libubox/libubox.mk [*] package/libuci/libuci.mk [*] package/libuecc/libuecc.mk [*] package/libuhttpd/libuhttpd.mk [*] package/liburiparser/liburiparser.mk [*] package/libvncserver/libvncserver.mk [*] package/libwebsockets/libwebsockets.mk [*] package/libyuv/libyuv.mk [*] package/libzip/libzip.mk [*] package/linphone/linphone.mk [*] package/linux-serial-test/linux-serial-test.mk [*] package/lld/lld.mk [*] package/llvm/llvm.mk [*] package/log4cxx/log4cxx.mk [*] package/log4qt/log4qt.mk [*] package/lua-ev/lua-ev.mk [*] package/lua-sdl2/lua-sdl2.mk [*] package/luv/luv.mk [*] package/luvi/luvi.mk [*] package/lzlib/lzlib.mk [*] package/lzo/lzo.mk [*] package/mariadb/mariadb.mk [*] package/mbedtls/mbedtls.mk [*] package/mediastreamer/mediastreamer.mk [*] package/midori/midori.mk [*] package/mjpg-streamer/mjpg-streamer.mk [*] package/mraa/mraa.mk [*] package/mrp/mrp.mk [*] package/msgpack/msgpack.mk [*] package/musepack/musepack.mk [*] package/nanomsg/nanomsg.mk [*] package/odhcp6c/odhcp6c.mk [*] package/openal/openal.mk [*] package/opencv4/opencv4.mk [*] package/openjpeg/openjpeg.mk [*] package/openobex/openobex.mk [*] package/openpowerlink/openpowerlink.mk [*] package/ortp/ortp.mk [*] package/paho-mqtt-c/paho-mqtt-c.mk [*] package/paho-mqtt-cpp/paho-mqtt-cpp.mk [*] package/physfs/physfs.mk [*] package/pistache/pistache.mk [*] package/poppler/poppler.mk [*] package/protozero/protozero.mk [*] package/pugixml/pugixml.mk [*] package/python-pybind/python-pybind.mk [*] package/qhull/qhull.mk [*] package/qjson/qjson.mk [*] package/qpid-proton/qpid-proton.mk [*] package/rabbitmq-c/rabbitmq-c.mk [*] package/rapidjson/rapidjson.mk [*] package/re2/re2.mk [*] package/read-edid/read-edid.mk [*] package/rtl_433/rtl_433.mk [*] package/rtty/rtty.mk [*] package/sentry-native/sentry-native.mk [*] package/simple-mail/simple-mail.mk [*] package/snappy/snappy.mk [*] package/snort3/snort3.mk [*] package/solarus/solarus.mk [*] package/spdlog/spdlog.mk [*] package/sysrepo/sysrepo.mk [*] package/taglib/taglib.mk [*] package/taskd/taskd.mk [*] package/tcf-agent/tcf-agent.mk [*] package/thrift/thrift.mk [*] package/tinyxml2/tinyxml2.mk [*] package/ttyd/ttyd.mk [*] package/ubus/ubus.mk [*] package/uhd/uhd.mk [*] package/uhttpd/uhttpd.mk [*] package/unionfs/unionfs.mk [*] package/unzip/unzip.mk [*] package/uqmi/uqmi.mk [*] package/ustream-ssl/ustream-ssl.mk [*] package/utf8proc/utf8proc.mk [*] package/uvw/uvw.mk [*] package/valijson/valijson.mk [*] package/vulkan-headers/vulkan-headers.mk [*] package/waffle/waffle.mk [*] package/wampcc/wampcc.mk [*] package/waylandpp/waylandpp.mk [*] package/webkitgtk/webkitgtk.mk [*] package/websocketpp/websocketpp.mk [*] package/woff2/woff2.mk [*] package/wpewebkit/wpewebkit.mk [*] package/x265/x265.mk [*] package/xerces/xerces.mk [*] package/yajl/yajl.mk [*] package/yaml-cpp/yaml-cpp.mk [*] package/ympd/ympd.mk [*] package/zlib-ng/zlib-ng.mk [*] package/znc/znc.mk [*] package/zxing-cpp/zxing-cpp.mk [*] package/zziplib/zziplib.mk [*] package/libsoxr/libsoxr.mk [*] package/libspatialindex/libspatialindex.mk [*] package/lugaru/lugaru.mk [*] package/minetest/minetest.mk [*] package/openfpgaloader/openfpgaloader.mk [*] package/supertux/supertux.mk [*] package/supertuxkart/supertuxkart.mk [=] package/libcorrect/libcorrect.mk [=] package/ninja/ninja.mk [?] package/racehound/racehound.mk [?] package/azmq/azmq.mk [?] package/bullet/bullet.mk [?] package/cppcms/cppcms.mk [?] package/netopeer2/netopeer2.mk [?] package/piglit/piglit.mk [?] package/pulseview/pulseview.mk [?] package/qt5/qt5webkit/qt5webkit.mk [?] package/quazip/quazip.mk [?] package/sysdig/sysdig.mk [?] package/wireshark/wireshark.mk [ ] package/assimp/assimp.mk [ ] package/chipmunk/chipmunk.mk [ ] package/domoticz/domoticz.mk [ ] package/kodi-audiodecoder-modplug/kodi-audiodecoder-modplug.mk [ ] package/kodi-audiodecoder-nosefart/kodi-audiodecoder-nosefart.mk [ ] package/kodi-audiodecoder-sidplay/kodi-audiodecoder-sidplay.mk [ ] package/kodi-audiodecoder-snesapu/kodi-audiodecoder-snesapu.mk [ ] package/kodi-audiodecoder-stsound/kodi-audiodecoder-stsound.mk [ ] package/kodi-audiodecoder-timidity/kodi-audiodecoder-timidity.mk [ ] package/kodi-audiodecoder-vgmstream/kodi-audiodecoder-vgmstream.mk [ ] package/kodi-audioencoder-flac/kodi-audioencoder-flac.mk [ ] package/kodi-audioencoder-lame/kodi-audioencoder-lame.mk [ ] package/kodi-audioencoder-vorbis/kodi-audioencoder-vorbis.mk [ ] package/kodi-audioencoder-wav/kodi-audioencoder-wav.mk [ ] package/kodi-inputstream-adaptive/kodi-inputstream-adaptive.mk [ ] package/kodi-inputstream-ffmpegdirect/kodi-inputstream-ffmpegdirect.mk [ ] package/kodi-inputstream-rtmp/kodi-inputstream-rtmp.mk [ ] package/kodi-jsonschemabuilder/kodi-jsonschemabuilder.mk [ ] package/kodi-peripheral-joystick/kodi-peripheral-joystick.mk [ ] package/kodi-peripheral-xarcade/kodi-peripheral-xarcade.mk [ ] package/kodi-pvr-argustv/kodi-pvr-argustv.mk [ ] package/kodi-pvr-dvblink/kodi-pvr-dvblink.mk [ ] package/kodi-pvr-dvbviewer/kodi-pvr-dvbviewer.mk [ ] package/kodi-pvr-filmon/kodi-pvr-filmon.mk [ ] package/kodi-pvr-hdhomerun/kodi-pvr-hdhomerun.mk [ ] package/kodi-pvr-hts/kodi-pvr-hts.mk [ ] package/kodi-pvr-iptvsimple/kodi-pvr-iptvsimple.mk [ ] package/kodi-pvr-mediaportal-tvserver/kodi-pvr-mediaportal-tvserver.mk [ ] package/kodi-pvr-mythtv/kodi-pvr-mythtv.mk [ ] package/kodi-pvr-nextpvr/kodi-pvr-nextpvr.mk [ ] package/kodi-pvr-njoy/kodi-pvr-njoy.mk [ ] package/kodi-pvr-octonet/kodi-pvr-octonet.mk [ ] package/kodi-pvr-pctv/kodi-pvr-pctv.mk [ ] package/kodi-pvr-plutotv/kodi-pvr-plutotv.mk [ ] package/kodi-pvr-stalker/kodi-pvr-stalker.mk [ ] package/kodi-pvr-vbox/kodi-pvr-vbox.mk [ ] package/kodi-pvr-vdr-vnsi/kodi-pvr-vdr-vnsi.mk [ ] package/kodi-pvr-vuplus/kodi-pvr-vuplus.mk [ ] package/kodi-pvr-waipu/kodi-pvr-waipu.mk [ ] package/kodi-pvr-wmc/kodi-pvr-wmc.mk [ ] package/kodi-pvr-zattoo/kodi-pvr-zattoo.mk [ ] package/kodi-screensaver-asteroids/kodi-screensaver-asteroids.mk [ ] package/kodi-screensaver-asterwave/kodi-screensaver-asterwave.mk [ ] package/kodi-screensaver-biogenesis/kodi-screensaver-biogenesis.mk [ ] package/kodi-screensaver-cpblobs/kodi-screensaver-cpblobs.mk [ ] package/kodi-screensaver-greynetic/kodi-screensaver-greynetic.mk [ ] package/kodi-screensaver-matrixtrails/kodi-screensaver-matrixtrails.mk [ ] package/kodi-screensaver-pingpong/kodi-screensaver-pingpong.mk [ ] package/kodi-screensaver-pyro/kodi-screensaver-pyro.mk [ ] package/kodi-screensaver-rsxs/kodi-screensaver-rsxs.mk [ ] package/kodi-screensaver-stars/kodi-screensaver-stars.mk [ ] package/kodi-texturepacker/kodi-texturepacker.mk [ ] package/kodi-vfs-libarchive/kodi-vfs-libarchive.mk [ ] package/kodi-vfs-rar/kodi-vfs-rar.mk [ ] package/kodi-vfs-sftp/kodi-vfs-sftp.mk [ ] package/kodi-visualisation-fishbmc/kodi-visualisation-fishbmc.mk [ ] package/kodi-visualisation-goom/kodi-visualisation-goom.mk [ ] package/kodi-visualisation-matrix/kodi-visualisation-matrix.mk [ ] package/kodi-visualisation-shadertoy/kodi-visualisation-shadertoy.mk [ ] package/kodi-visualisation-spectrum/kodi-visualisation-spectrum.mk [ ] package/kodi-visualisation-starburst/kodi-visualisation-starburst.mk [ ] package/kodi-visualisation-waveform/kodi-visualisation-waveform.mk [ ] package/kodi/kodi.mk [ ] package/libcpprestsdk/libcpprestsdk.mk [ ] package/libfreeglut/libfreeglut.mk [ ] package/libglfw/libglfw.mk [ ] package/libressl/libressl.mk [ ] package/libubootenv/libubootenv.mk [ ] package/libuwsc/libuwsc.mk [ ] package/libyang/libyang.mk [ ] package/mfgtools/mfgtools.mk [ ] package/minizip/minizip.mk [ ] package/ne10/ne10.mk [ ] package/ogre/ogre.mk [ ] package/open62541/open62541.mk [ ] package/opencv3/opencv3.mk [ ] package/opentracing-cpp/opentracing-cpp.mk [ ] package/optee-benchmark/optee-benchmark.mk [ ] package/optee-client/optee-client.mk [ ] package/optee-examples/optee-examples.mk [ ] package/optee-test/optee-test.mk [ ] package/osm2pgsql/osm2pgsql.mk [ ] package/rpi-userland/rpi-userland.mk [ ] package/sdbus-cpp/sdbus-cpp.mk [ ] package/stellarium/stellarium.mk [ ] package/synergy/synergy.mk [ ] package/timescaledb/timescaledb.mk [ ] package/xmrig/xmrig.mk [-- Attachment #1.2: signature.asc --] [-- Type: application/pgp-signature, Size: 195 bytes --] [-- Attachment #2: Type: text/plain, Size: 150 bytes --] _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* [Buildroot] [PATCH RFC 2/2] package/pkg-cmake.mk: use ninja instead of make 2022-01-12 13:26 [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro 2022-01-12 13:26 ` [Buildroot] [PATCH RFC 1/2] package/ninja: do not require cmake Adrian Perez de Castro @ 2022-01-12 13:26 ` Adrian Perez de Castro 2022-01-12 14:35 ` Thomas Petazzoni 2022-01-12 14:36 ` [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages Thomas Petazzoni ` (2 subsequent siblings) 4 siblings, 1 reply; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-12 13:26 UTC (permalink / raw) To: buildroot; +Cc: Eric Le Bihan, Samuel Martin, Thomas Petazzoni Switch to ninja as the build tool for the CMake package infrastructure. Note that the changes make packages which use [host-]cmake-package depend on host-ninja. Signed-off-by: Adrian Perez de Castro <aperez@igalia.com> --- package/pkg-cmake.mk | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/package/pkg-cmake.mk b/package/pkg-cmake.mk index 3b1db35fb6..65f005a914 100644 --- a/package/pkg-cmake.mk +++ b/package/pkg-cmake.mk @@ -51,11 +51,6 @@ endif define inner-cmake-package -$(2)_MAKE ?= $$(MAKE) -$(2)_INSTALL_OPTS ?= install -$(2)_INSTALL_STAGING_OPTS ?= DESTDIR=$$(STAGING_DIR) install/fast -$(2)_INSTALL_TARGET_OPTS ?= DESTDIR=$$(TARGET_DIR) install/fast - $(3)_SUPPORTS_IN_SOURCE_BUILD ?= YES @@ -88,6 +83,7 @@ define $(2)_CONFIGURE_CMDS rm -f CMakeCache.txt && \ PATH=$$(BR_PATH) \ $$($$(PKG)_CONF_ENV) $$(BR2_CMAKE) $$($$(PKG)_SRCDIR) \ + -GNinja \ -DCMAKE_TOOLCHAIN_FILE="$$(HOST_DIR)/share/buildroot/toolchainfile.cmake" \ -DCMAKE_INSTALL_PREFIX="/usr" \ -DCMAKE_COLOR_MAKEFILE=OFF \ @@ -117,6 +113,7 @@ define $(2)_CONFIGURE_CMDS PKG_CONFIG_ALLOW_SYSTEM_CFLAGS=1 \ PKG_CONFIG_ALLOW_SYSTEM_LIBS=1 \ $$($$(PKG)_CONF_ENV) $$(BR2_CMAKE) $$($$(PKG)_SRCDIR) \ + -GNinja \ -DCMAKE_INSTALL_SO_NO_EXE=0 \ -DCMAKE_FIND_ROOT_PATH="$$(HOST_DIR)" \ -DCMAKE_FIND_ROOT_PATH_MODE_PROGRAM="BOTH" \ @@ -154,6 +151,8 @@ endif # primitives to find {C,LD}FLAGS, add it to the dependency list. $(2)_DEPENDENCIES += host-pkgconf +$(2)_DEPENDENCIES += host-ninja + $(2)_DEPENDENCIES += $(BR2_CMAKE_HOST_DEPENDENCY) # @@ -163,11 +162,13 @@ $(2)_DEPENDENCIES += $(BR2_CMAKE_HOST_DEPENDENCY) ifndef $(2)_BUILD_CMDS ifeq ($(4),target) define $(2)_BUILD_CMDS - $$(TARGET_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) -C $$($$(PKG)_BUILDDIR) + $$(TARGET_MAKE_ENV) $$($$(PKG)_NINJA_ENV) \ + $$(NINJA) $$(NINJA_OPTS) $$($$(PKG)_NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) endef else define $(2)_BUILD_CMDS - $$(HOST_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) -C $$($$(PKG)_BUILDDIR) + $$(HOST_MAKE_ENV) $$($$(PKG)_NINJA_ENV) \ + $$(NINJA) $$(NINJA_OPTS) $$($$(PKG)_NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) endef endif endif @@ -178,7 +179,8 @@ endif # ifndef $(2)_INSTALL_CMDS define $(2)_INSTALL_CMDS - $$(HOST_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) $$($$(PKG)_INSTALL_OPTS) -C $$($$(PKG)_BUILDDIR) + $$(HOST_MAKE_ENV) $$($$(PKG)_NINJA_ENV) \ + $$(NINJA) $$(NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) install endef endif @@ -188,7 +190,8 @@ endif # ifndef $(2)_INSTALL_STAGING_CMDS define $(2)_INSTALL_STAGING_CMDS - $$(TARGET_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) $$($$(PKG)_INSTALL_STAGING_OPTS) -C $$($$(PKG)_BUILDDIR) + $$(TARGET_MAKE_ENV) $$($$(PKG)_NINJA_ENV) DESTDIR=$$(STAGING_DIR) \ + $$(NINJA) $$(NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) install endef endif @@ -198,7 +201,8 @@ endif # ifndef $(2)_INSTALL_TARGET_CMDS define $(2)_INSTALL_TARGET_CMDS - $$(TARGET_MAKE_ENV) $$($$(PKG)_MAKE_ENV) $$($$(PKG)_MAKE) $$($$(PKG)_MAKE_OPTS) $$($$(PKG)_INSTALL_TARGET_OPTS) -C $$($$(PKG)_BUILDDIR) + $$(TARGET_MAKE_ENV) $$($$(PKG)_NINJA_ENV) DESTDIR=$$(TARGET_DIR) \ + $$(NINJA) $$(NINJA_OPTS) -C $$($$(PKG)_BUILDDIR) install endef endif -- 2.34.1 _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply related [flat|nested] 25+ messages in thread
* Re: [Buildroot] [PATCH RFC 2/2] package/pkg-cmake.mk: use ninja instead of make 2022-01-12 13:26 ` [Buildroot] [PATCH RFC 2/2] package/pkg-cmake.mk: use ninja instead of make Adrian Perez de Castro @ 2022-01-12 14:35 ` Thomas Petazzoni 2022-01-12 16:51 ` Adrian Perez de Castro 0 siblings, 1 reply; 25+ messages in thread From: Thomas Petazzoni @ 2022-01-12 14:35 UTC (permalink / raw) To: Adrian Perez de Castro; +Cc: Eric Le Bihan, Samuel Martin, buildroot Hello, On Wed, 12 Jan 2022 15:26:18 +0200 Adrian Perez de Castro <aperez@igalia.com> wrote: > Switch to ninja as the build tool for the CMake package infrastructure. > Note that the changes make packages which use [host-]cmake-package > depend on host-ninja. > > Signed-off-by: Adrian Perez de Castro <aperez@igalia.com> > --- > package/pkg-cmake.mk | 24 ++++++++++++++---------- > 1 file changed, 14 insertions(+), 10 deletions(-) > > diff --git a/package/pkg-cmake.mk b/package/pkg-cmake.mk > index 3b1db35fb6..65f005a914 100644 > --- a/package/pkg-cmake.mk > +++ b/package/pkg-cmake.mk > @@ -51,11 +51,6 @@ endif > > define inner-cmake-package > > -$(2)_MAKE ?= $$(MAKE) > -$(2)_INSTALL_OPTS ?= install > -$(2)_INSTALL_STAGING_OPTS ?= DESTDIR=$$(STAGING_DIR) install/fast > -$(2)_INSTALL_TARGET_OPTS ?= DESTDIR=$$(TARGET_DIR) install/fast This means an audit of all cmake-package packages need to be done to see if any of those variables is used. I could spot: MUSEPACK_MAKE = $(MAKE1) But also: HOST_MARIADB_MAKE_OPTS = import_executables Best regards, Thomas -- Thomas Petazzoni, co-owner and CEO, Bootlin Embedded Linux and Kernel engineering and training https://bootlin.com _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [Buildroot] [PATCH RFC 2/2] package/pkg-cmake.mk: use ninja instead of make 2022-01-12 14:35 ` Thomas Petazzoni @ 2022-01-12 16:51 ` Adrian Perez de Castro 0 siblings, 0 replies; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-12 16:51 UTC (permalink / raw) To: Thomas Petazzoni; +Cc: Eric Le Bihan, Samuel Martin, buildroot [-- Attachment #1.1: Type: text/plain, Size: 1736 bytes --] Hi, On Wed, 12 Jan 2022 15:35:16 +0100 Thomas Petazzoni <thomas.petazzoni@bootlin.com> wrote: > On Wed, 12 Jan 2022 15:26:18 +0200 > Adrian Perez de Castro <aperez@igalia.com> wrote: > > > Switch to ninja as the build tool for the CMake package infrastructure. > > Note that the changes make packages which use [host-]cmake-package > > depend on host-ninja. > > > > Signed-off-by: Adrian Perez de Castro <aperez@igalia.com> > > --- > > package/pkg-cmake.mk | 24 ++++++++++++++---------- > > 1 file changed, 14 insertions(+), 10 deletions(-) > > > > diff --git a/package/pkg-cmake.mk b/package/pkg-cmake.mk > > index 3b1db35fb6..65f005a914 100644 > > --- a/package/pkg-cmake.mk > > +++ b/package/pkg-cmake.mk > > @@ -51,11 +51,6 @@ endif > > > > define inner-cmake-package > > > > -$(2)_MAKE ?= $$(MAKE) > > -$(2)_INSTALL_OPTS ?= install > > -$(2)_INSTALL_STAGING_OPTS ?= DESTDIR=$$(STAGING_DIR) install/fast > > -$(2)_INSTALL_TARGET_OPTS ?= DESTDIR=$$(TARGET_DIR) install/fast > > This means an audit of all cmake-package packages need to be done to > see if any of those variables is used. I will be going through the packages in the next days, for now a couple of notes on the ones you mentioned already, below. > I could spot: > > MUSEPACK_MAKE = $(MAKE1) I fixed this locally using: MUSEPACK_NINJA_OPTS = -j1 Sadly, switching to Ninja does not fix parallel builds for this package. > But also: > > HOST_MARIADB_MAKE_OPTS = import_executables Replacing with the following works, because the CMake Ninja generator also produces top-level phony targets: HOST_MARIADB_NINJA_OPTS = import_executables Both these tweaks (and likely a bunch more) will be part of v2 of the patch set :) Cheers, —Adrián [-- Attachment #1.2: signature.asc --] [-- Type: application/pgp-signature, Size: 195 bytes --] [-- Attachment #2: Type: text/plain, Size: 150 bytes --] _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages 2022-01-12 13:26 [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro 2022-01-12 13:26 ` [Buildroot] [PATCH RFC 1/2] package/ninja: do not require cmake Adrian Perez de Castro 2022-01-12 13:26 ` [Buildroot] [PATCH RFC 2/2] package/pkg-cmake.mk: use ninja instead of make Adrian Perez de Castro @ 2022-01-12 14:36 ` Thomas Petazzoni 2022-01-12 15:09 ` Adrian Perez de Castro 2022-01-12 16:05 ` Alexander Dahl 2022-07-24 13:05 ` Arnout Vandecappelle 4 siblings, 1 reply; 25+ messages in thread From: Thomas Petazzoni @ 2022-01-12 14:36 UTC (permalink / raw) To: Adrian Perez de Castro; +Cc: Eric Le Bihan, Samuel Martin, buildroot Hello Adrian, On Wed, 12 Jan 2022 15:26:16 +0200 Adrian Perez de Castro <aperez@igalia.com> wrote: > While not a long list by any means, I think it shows a decent sample of > packages coming from different development teams that work just fine > switching to Ninja. > > If anybody can suggest something with a bigger number of CMake packages to > build (or a .config file to share) I will be more than happy to give it a > test this with these patches applied :) Packages that need to be tested: ./package/alure/alure.mk ./package/apitrace/apitrace.mk ./package/armadillo/armadillo.mk ./package/assimp/assimp.mk ./package/avro-c/avro-c.mk ./package/azmq/azmq.mk ./package/azure-iot-sdk-c/azure-iot-sdk-c.mk ./package/bcg729/bcg729.mk ./package/bctoolbox/bctoolbox.mk ./package/belle-sip/belle-sip.mk ./package/belr/belr.mk ./package/bento4/bento4.mk ./package/brickd/brickd.mk ./package/brotli/brotli.mk ./package/bullet/bullet.mk ./package/cannelloni/cannelloni.mk ./package/cctz/cctz.mk ./package/cdrkit/cdrkit.mk ./package/cegui/cegui.mk ./package/cereal/cereal.mk ./package/cfm/cfm.mk ./package/chipmunk/chipmunk.mk ./package/cjson/cjson.mk ./package/clang/clang.mk ./package/cmake/cmake.mk ./package/cmocka/cmocka.mk ./package/cog/cog.mk ./package/c-periphery/c-periphery.mk ./package/cppcms/cppcms.mk ./package/cppdb/cppdb.mk ./package/cppzmq/cppzmq.mk ./package/curlpp/curlpp.mk ./package/cutelyst/cutelyst.mk ./package/domoticz/domoticz.mk ./package/doxygen/doxygen.mk ./package/easydbus/easydbus.mk ./package/easyframes/easyframes.mk ./package/eigen/eigen.mk ./package/exiv2/exiv2.mk ./package/fatcat/fatcat.mk ./package/firmware-utils/firmware-utils.mk ./package/flann/flann.mk ./package/flare-engine/flare-engine.mk ./package/flare-game/flare-game.mk ./package/flatbuffers/flatbuffers.mk ./package/flatcc/flatcc.mk ./package/fluidsynth/fluidsynth.mk ./package/fmt/fmt.mk ./package/freerdp/freerdp.mk ./package/gerbera/gerbera.mk ./package/gflags/gflags.mk ./package/gli/gli.mk ./package/glm/glm.mk ./package/glog/glog.mk ./package/gnuradio/gnuradio.mk ./package/gqrx/gqrx.mk ./package/grantlee/grantlee.mk ./package/graphite2/graphite2.mk ./package/gr-osmosdr/gr-osmosdr.mk ./package/grpc/grpc.mk ./package/gtest/gtest.mk ./package/hackrf/hackrf.mk ./package/hiawatha/hiawatha.mk ./package/hiredis/hiredis.mk ./package/i2pd/i2pd.mk ./package/intel-gmmlib/intel-gmmlib.mk ./package/intel-mediadriver/intel-mediadriver.mk ./package/intel-mediasdk/intel-mediasdk.mk ./package/jasper/jasper.mk ./package/jpeg-turbo/jpeg-turbo.mk ./package/json-c/json-c.mk ./package/json-for-modern-cpp/json-for-modern-cpp.mk ./package/kf5/kf5-extra-cmake-modules/kf5-extra-cmake-modules.mk ./package/kf5/kf5-kcoreaddons/kf5-kcoreaddons.mk ./package/kf5/kf5-modemmanager-qt/kf5-modemmanager-qt.mk ./package/kf5/kf5-networkmanager-qt/kf5-networkmanager-qt.mk ./package/kodi-audiodecoder-modplug/kodi-audiodecoder-modplug.mk ./package/kodi-audiodecoder-nosefart/kodi-audiodecoder-nosefart.mk ./package/kodi-audiodecoder-sidplay/kodi-audiodecoder-sidplay.mk ./package/kodi-audiodecoder-snesapu/kodi-audiodecoder-snesapu.mk ./package/kodi-audiodecoder-stsound/kodi-audiodecoder-stsound.mk ./package/kodi-audiodecoder-timidity/kodi-audiodecoder-timidity.mk ./package/kodi-audiodecoder-vgmstream/kodi-audiodecoder-vgmstream.mk ./package/kodi-audioencoder-flac/kodi-audioencoder-flac.mk ./package/kodi-audioencoder-lame/kodi-audioencoder-lame.mk ./package/kodi-audioencoder-vorbis/kodi-audioencoder-vorbis.mk ./package/kodi-audioencoder-wav/kodi-audioencoder-wav.mk ./package/kodi-inputstream-adaptive/kodi-inputstream-adaptive.mk ./package/kodi-inputstream-ffmpegdirect/kodi-inputstream-ffmpegdirect.mk ./package/kodi-inputstream-rtmp/kodi-inputstream-rtmp.mk ./package/kodi-jsonschemabuilder/kodi-jsonschemabuilder.mk ./package/kodi/kodi.mk ./package/kodi-peripheral-joystick/kodi-peripheral-joystick.mk ./package/kodi-peripheral-xarcade/kodi-peripheral-xarcade.mk ./package/kodi-pvr-argustv/kodi-pvr-argustv.mk ./package/kodi-pvr-dvblink/kodi-pvr-dvblink.mk ./package/kodi-pvr-dvbviewer/kodi-pvr-dvbviewer.mk ./package/kodi-pvr-filmon/kodi-pvr-filmon.mk ./package/kodi-pvr-hdhomerun/kodi-pvr-hdhomerun.mk ./package/kodi-pvr-hts/kodi-pvr-hts.mk ./package/kodi-pvr-iptvsimple/kodi-pvr-iptvsimple.mk ./package/kodi-pvr-mediaportal-tvserver/kodi-pvr-mediaportal-tvserver.mk ./package/kodi-pvr-mythtv/kodi-pvr-mythtv.mk ./package/kodi-pvr-nextpvr/kodi-pvr-nextpvr.mk ./package/kodi-pvr-njoy/kodi-pvr-njoy.mk ./package/kodi-pvr-octonet/kodi-pvr-octonet.mk ./package/kodi-pvr-pctv/kodi-pvr-pctv.mk ./package/kodi-pvr-plutotv/kodi-pvr-plutotv.mk ./package/kodi-pvr-stalker/kodi-pvr-stalker.mk ./package/kodi-pvr-vbox/kodi-pvr-vbox.mk ./package/kodi-pvr-vdr-vnsi/kodi-pvr-vdr-vnsi.mk ./package/kodi-pvr-vuplus/kodi-pvr-vuplus.mk ./package/kodi-pvr-waipu/kodi-pvr-waipu.mk ./package/kodi-pvr-wmc/kodi-pvr-wmc.mk ./package/kodi-pvr-zattoo/kodi-pvr-zattoo.mk ./package/kodi-screensaver-asteroids/kodi-screensaver-asteroids.mk ./package/kodi-screensaver-asterwave/kodi-screensaver-asterwave.mk ./package/kodi-screensaver-biogenesis/kodi-screensaver-biogenesis.mk ./package/kodi-screensaver-cpblobs/kodi-screensaver-cpblobs.mk ./package/kodi-screensaver-greynetic/kodi-screensaver-greynetic.mk ./package/kodi-screensaver-matrixtrails/kodi-screensaver-matrixtrails.mk ./package/kodi-screensaver-pingpong/kodi-screensaver-pingpong.mk ./package/kodi-screensaver-pyro/kodi-screensaver-pyro.mk ./package/kodi-screensaver-rsxs/kodi-screensaver-rsxs.mk ./package/kodi-screensaver-stars/kodi-screensaver-stars.mk ./package/kodi-texturepacker/kodi-texturepacker.mk ./package/kodi-vfs-libarchive/kodi-vfs-libarchive.mk ./package/kodi-vfs-rar/kodi-vfs-rar.mk ./package/kodi-vfs-sftp/kodi-vfs-sftp.mk ./package/kodi-visualisation-fishbmc/kodi-visualisation-fishbmc.mk ./package/kodi-visualisation-goom/kodi-visualisation-goom.mk ./package/kodi-visualisation-matrix/kodi-visualisation-matrix.mk ./package/kodi-visualisation-shadertoy/kodi-visualisation-shadertoy.mk ./package/kodi-visualisation-spectrum/kodi-visualisation-spectrum.mk ./package/kodi-visualisation-starburst/kodi-visualisation-starburst.mk ./package/kodi-visualisation-waveform/kodi-visualisation-waveform.mk ./package/lapack/lapack.mk ./package/lensfun/lensfun.mk ./package/let-me-create/let-me-create.mk ./package/leveldb/leveldb.mk ./package/libabseil-cpp/libabseil-cpp.mk ./package/libasplib/libasplib.mk ./package/libcec/libcec.mk ./package/libcgi/libcgi.mk ./package/libcodec2/libcodec2.mk ./package/libcorrect/libcorrect.mk ./package/libcpprestsdk/libcpprestsdk.mk ./package/libcuefile/libcuefile.mk ./package/libcue/libcue.mk ./package/libeastl/libeastl.mk ./package/libebml/libebml.mk ./package/libebur128/libebur128.mk ./package/libfreeglut/libfreeglut.mk ./package/libftdi1/libftdi1.mk ./package/libgeos/libgeos.mk ./package/libgit2/libgit2.mk ./package/libglfw/libglfw.mk ./package/libgta/libgta.mk ./package/libical/libical.mk ./package/libiec61850/libiec61850.mk ./package/libiio/libiio.mk ./package/libiqrf/libiqrf.mk ./package/libks/libks.mk ./package/libmatroska/libmatroska.mk ./package/libmdbx/libmdbx.mk ./package/libminiupnpc/libminiupnpc.mk ./package/libnetconf2/libnetconf2.mk ./package/libolm/libolm.mk ./package/libosmium/libosmium.mk ./package/libplatform/libplatform.mk ./package/libressl/libressl.mk ./package/librsync/librsync.mk ./package/librtlsdr/librtlsdr.mk ./package/libsoxr/libsoxr.mk ./package/libspatialindex/libspatialindex.mk ./package/libssh/libssh.mk ./package/libubootenv/libubootenv.mk ./package/libubox/libubox.mk ./package/libuci/libuci.mk ./package/libuecc/libuecc.mk ./package/libuhttpd/libuhttpd.mk ./package/liburiparser/liburiparser.mk ./package/libuwsc/libuwsc.mk ./package/libvncserver/libvncserver.mk ./package/libwebsockets/libwebsockets.mk ./package/libyang/libyang.mk ./package/libyuv/libyuv.mk ./package/libzip/libzip.mk ./package/linphone/linphone.mk ./package/linux-serial-test/linux-serial-test.mk ./package/lld/lld.mk ./package/llvm/llvm.mk ./package/log4cxx/log4cxx.mk ./package/log4qt/log4qt.mk ./package/lua-ev/lua-ev.mk ./package/lua-sdl2/lua-sdl2.mk ./package/lugaru/lugaru.mk ./package/luvi/luvi.mk ./package/luv/luv.mk ./package/lzlib/lzlib.mk ./package/lzo/lzo.mk ./package/mariadb/mariadb.mk ./package/mbedtls/mbedtls.mk ./package/mediastreamer/mediastreamer.mk ./package/mfgtools/mfgtools.mk ./package/midori/midori.mk ./package/minetest/minetest.mk ./package/minizip/minizip.mk ./package/mjpg-streamer/mjpg-streamer.mk ./package/mraa/mraa.mk ./package/mrp/mrp.mk ./package/msgpack/msgpack.mk ./package/musepack/musepack.mk ./package/nanomsg/nanomsg.mk ./package/ne10/ne10.mk ./package/netopeer2/netopeer2.mk ./package/ninja/ninja.mk ./package/odhcp6c/odhcp6c.mk ./package/ogre/ogre.mk ./package/open62541/open62541.mk ./package/openal/openal.mk ./package/opencv3/opencv3.mk ./package/opencv4/opencv4.mk ./package/openfpgaloader/openfpgaloader.mk ./package/openjpeg/openjpeg.mk ./package/openobex/openobex.mk ./package/openpowerlink/openpowerlink.mk ./package/opentracing-cpp/opentracing-cpp.mk ./package/optee-benchmark/optee-benchmark.mk ./package/optee-client/optee-client.mk ./package/optee-examples/optee-examples.mk ./package/optee-test/optee-test.mk ./package/ortp/ortp.mk ./package/osm2pgsql/osm2pgsql.mk ./package/paho-mqtt-c/paho-mqtt-c.mk ./package/paho-mqtt-cpp/paho-mqtt-cpp.mk ./package/physfs/physfs.mk ./package/piglit/piglit.mk ./package/pistache/pistache.mk ./package/pkg-cmake.mk ./package/poppler/poppler.mk ./package/protozero/protozero.mk ./package/pugixml/pugixml.mk ./package/pulseview/pulseview.mk ./package/python-pybind/python-pybind.mk ./package/qhull/qhull.mk ./package/qjson/qjson.mk ./package/qpid-proton/qpid-proton.mk ./package/qt5/qt5webkit/qt5webkit.mk ./package/quazip/quazip.mk ./package/rabbitmq-c/rabbitmq-c.mk ./package/racehound/racehound.mk ./package/rapidjson/rapidjson.mk ./package/re2/re2.mk ./package/read-edid/read-edid.mk ./package/rpi-userland/rpi-userland.mk ./package/rtl_433/rtl_433.mk ./package/rtty/rtty.mk ./package/sdbus-cpp/sdbus-cpp.mk ./package/sentry-native/sentry-native.mk ./package/simple-mail/simple-mail.mk ./package/snappy/snappy.mk ./package/snort3/snort3.mk ./package/solarus/solarus.mk ./package/spdlog/spdlog.mk ./package/stellarium/stellarium.mk ./package/supertuxkart/supertuxkart.mk ./package/supertux/supertux.mk ./package/synergy/synergy.mk ./package/sysdig/sysdig.mk ./package/sysrepo/sysrepo.mk ./package/taglib/taglib.mk ./package/taskd/taskd.mk ./package/tcf-agent/tcf-agent.mk ./package/thrift/thrift.mk ./package/timescaledb/timescaledb.mk ./package/tinyxml2/tinyxml2.mk ./package/ttyd/ttyd.mk ./package/ubus/ubus.mk ./package/uhd/uhd.mk ./package/uhttpd/uhttpd.mk ./package/unionfs/unionfs.mk ./package/unzip/unzip.mk ./package/uqmi/uqmi.mk ./package/ustream-ssl/ustream-ssl.mk ./package/utf8proc/utf8proc.mk ./package/uvw/uvw.mk ./package/valijson/valijson.mk ./package/vulkan-headers/vulkan-headers.mk ./package/waffle/waffle.mk ./package/wampcc/wampcc.mk ./package/waylandpp/waylandpp.mk ./package/webkitgtk/webkitgtk.mk ./package/websocketpp/websocketpp.mk ./package/wireshark/wireshark.mk ./package/woff2/woff2.mk ./package/wpewebkit/wpewebkit.mk ./package/x265/x265.mk ./package/xerces/xerces.mk ./package/xmrig/xmrig.mk ./package/yajl/yajl.mk ./package/yaml-cpp/yaml-cpp.mk ./package/ympd/ympd.mk ./package/zlib-ng/zlib-ng.mk ./package/znc/znc.mk ./package/zxing-cpp/zxing-cpp.mk ./package/zziplib/zziplib.mk The list is much longer than the ~10 samples you have taken I'm afraid :-) Best regards, Thomas -- Thomas Petazzoni, co-owner and CEO, Bootlin Embedded Linux and Kernel engineering and training https://bootlin.com _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages 2022-01-12 14:36 ` [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages Thomas Petazzoni @ 2022-01-12 15:09 ` Adrian Perez de Castro 2022-01-12 16:02 ` Thomas Petazzoni 0 siblings, 1 reply; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-12 15:09 UTC (permalink / raw) To: Thomas Petazzoni; +Cc: Eric Le Bihan, Samuel Martin, buildroot [-- Attachment #1.1: Type: text/plain, Size: 12764 bytes --] Hi Thomas, all, On Wed, 12 Jan 2022 15:36:34 +0100 Thomas Petazzoni <thomas.petazzoni@bootlin.com> wrote: > On Wed, 12 Jan 2022 15:26:16 +0200 > Adrian Perez de Castro <aperez@igalia.com> wrote: > > > While not a long list by any means, I think it shows a decent sample of > > packages coming from different development teams that work just fine > > switching to Ninja. > > > > If anybody can suggest something with a bigger number of CMake packages to > > build (or a .config file to share) I will be more than happy to give it a > > test this with these patches applied :) > > Packages that need to be tested: > > ./package/alure/alure.mk > ./package/apitrace/apitrace.mk > ./package/armadillo/armadillo.mk > ./package/assimp/assimp.mk > ./package/avro-c/avro-c.mk > ./package/azmq/azmq.mk > ./package/azure-iot-sdk-c/azure-iot-sdk-c.mk > ./package/bcg729/bcg729.mk > ./package/bctoolbox/bctoolbox.mk > ./package/belle-sip/belle-sip.mk > ./package/belr/belr.mk > ./package/bento4/bento4.mk > ./package/brickd/brickd.mk > ./package/brotli/brotli.mk > ./package/bullet/bullet.mk > ./package/cannelloni/cannelloni.mk > ./package/cctz/cctz.mk > ./package/cdrkit/cdrkit.mk > ./package/cegui/cegui.mk > ./package/cereal/cereal.mk > ./package/cfm/cfm.mk > ./package/chipmunk/chipmunk.mk > ./package/cjson/cjson.mk > ./package/clang/clang.mk > ./package/cmake/cmake.mk > ./package/cmocka/cmocka.mk > ./package/cog/cog.mk > ./package/c-periphery/c-periphery.mk > ./package/cppcms/cppcms.mk > ./package/cppdb/cppdb.mk > ./package/cppzmq/cppzmq.mk > ./package/curlpp/curlpp.mk > ./package/cutelyst/cutelyst.mk > ./package/domoticz/domoticz.mk > ./package/doxygen/doxygen.mk > ./package/easydbus/easydbus.mk > ./package/easyframes/easyframes.mk > ./package/eigen/eigen.mk > ./package/exiv2/exiv2.mk > ./package/fatcat/fatcat.mk > ./package/firmware-utils/firmware-utils.mk > ./package/flann/flann.mk > ./package/flare-engine/flare-engine.mk > ./package/flare-game/flare-game.mk > ./package/flatbuffers/flatbuffers.mk > ./package/flatcc/flatcc.mk > ./package/fluidsynth/fluidsynth.mk > ./package/fmt/fmt.mk > ./package/freerdp/freerdp.mk > ./package/gerbera/gerbera.mk > ./package/gflags/gflags.mk > ./package/gli/gli.mk > ./package/glm/glm.mk > ./package/glog/glog.mk > ./package/gnuradio/gnuradio.mk > ./package/gqrx/gqrx.mk > ./package/grantlee/grantlee.mk > ./package/graphite2/graphite2.mk > ./package/gr-osmosdr/gr-osmosdr.mk > ./package/grpc/grpc.mk > ./package/gtest/gtest.mk > ./package/hackrf/hackrf.mk > ./package/hiawatha/hiawatha.mk > ./package/hiredis/hiredis.mk > ./package/i2pd/i2pd.mk > ./package/intel-gmmlib/intel-gmmlib.mk > ./package/intel-mediadriver/intel-mediadriver.mk > ./package/intel-mediasdk/intel-mediasdk.mk > ./package/jasper/jasper.mk > ./package/jpeg-turbo/jpeg-turbo.mk > ./package/json-c/json-c.mk > ./package/json-for-modern-cpp/json-for-modern-cpp.mk > ./package/kf5/kf5-extra-cmake-modules/kf5-extra-cmake-modules.mk > ./package/kf5/kf5-kcoreaddons/kf5-kcoreaddons.mk > ./package/kf5/kf5-modemmanager-qt/kf5-modemmanager-qt.mk > ./package/kf5/kf5-networkmanager-qt/kf5-networkmanager-qt.mk > ./package/kodi-audiodecoder-modplug/kodi-audiodecoder-modplug.mk > ./package/kodi-audiodecoder-nosefart/kodi-audiodecoder-nosefart.mk > ./package/kodi-audiodecoder-sidplay/kodi-audiodecoder-sidplay.mk > ./package/kodi-audiodecoder-snesapu/kodi-audiodecoder-snesapu.mk > ./package/kodi-audiodecoder-stsound/kodi-audiodecoder-stsound.mk > ./package/kodi-audiodecoder-timidity/kodi-audiodecoder-timidity.mk > ./package/kodi-audiodecoder-vgmstream/kodi-audiodecoder-vgmstream.mk > ./package/kodi-audioencoder-flac/kodi-audioencoder-flac.mk > ./package/kodi-audioencoder-lame/kodi-audioencoder-lame.mk > ./package/kodi-audioencoder-vorbis/kodi-audioencoder-vorbis.mk > ./package/kodi-audioencoder-wav/kodi-audioencoder-wav.mk > ./package/kodi-inputstream-adaptive/kodi-inputstream-adaptive.mk > ./package/kodi-inputstream-ffmpegdirect/kodi-inputstream-ffmpegdirect.mk > ./package/kodi-inputstream-rtmp/kodi-inputstream-rtmp.mk > ./package/kodi-jsonschemabuilder/kodi-jsonschemabuilder.mk > ./package/kodi/kodi.mk > ./package/kodi-peripheral-joystick/kodi-peripheral-joystick.mk > ./package/kodi-peripheral-xarcade/kodi-peripheral-xarcade.mk > ./package/kodi-pvr-argustv/kodi-pvr-argustv.mk > ./package/kodi-pvr-dvblink/kodi-pvr-dvblink.mk > ./package/kodi-pvr-dvbviewer/kodi-pvr-dvbviewer.mk > ./package/kodi-pvr-filmon/kodi-pvr-filmon.mk > ./package/kodi-pvr-hdhomerun/kodi-pvr-hdhomerun.mk > ./package/kodi-pvr-hts/kodi-pvr-hts.mk > ./package/kodi-pvr-iptvsimple/kodi-pvr-iptvsimple.mk > ./package/kodi-pvr-mediaportal-tvserver/kodi-pvr-mediaportal-tvserver.mk > ./package/kodi-pvr-mythtv/kodi-pvr-mythtv.mk > ./package/kodi-pvr-nextpvr/kodi-pvr-nextpvr.mk > ./package/kodi-pvr-njoy/kodi-pvr-njoy.mk > ./package/kodi-pvr-octonet/kodi-pvr-octonet.mk > ./package/kodi-pvr-pctv/kodi-pvr-pctv.mk > ./package/kodi-pvr-plutotv/kodi-pvr-plutotv.mk > ./package/kodi-pvr-stalker/kodi-pvr-stalker.mk > ./package/kodi-pvr-vbox/kodi-pvr-vbox.mk > ./package/kodi-pvr-vdr-vnsi/kodi-pvr-vdr-vnsi.mk > ./package/kodi-pvr-vuplus/kodi-pvr-vuplus.mk > ./package/kodi-pvr-waipu/kodi-pvr-waipu.mk > ./package/kodi-pvr-wmc/kodi-pvr-wmc.mk > ./package/kodi-pvr-zattoo/kodi-pvr-zattoo.mk > ./package/kodi-screensaver-asteroids/kodi-screensaver-asteroids.mk > ./package/kodi-screensaver-asterwave/kodi-screensaver-asterwave.mk > ./package/kodi-screensaver-biogenesis/kodi-screensaver-biogenesis.mk > ./package/kodi-screensaver-cpblobs/kodi-screensaver-cpblobs.mk > ./package/kodi-screensaver-greynetic/kodi-screensaver-greynetic.mk > ./package/kodi-screensaver-matrixtrails/kodi-screensaver-matrixtrails.mk > ./package/kodi-screensaver-pingpong/kodi-screensaver-pingpong.mk > ./package/kodi-screensaver-pyro/kodi-screensaver-pyro.mk > ./package/kodi-screensaver-rsxs/kodi-screensaver-rsxs.mk > ./package/kodi-screensaver-stars/kodi-screensaver-stars.mk > ./package/kodi-texturepacker/kodi-texturepacker.mk > ./package/kodi-vfs-libarchive/kodi-vfs-libarchive.mk > ./package/kodi-vfs-rar/kodi-vfs-rar.mk > ./package/kodi-vfs-sftp/kodi-vfs-sftp.mk > ./package/kodi-visualisation-fishbmc/kodi-visualisation-fishbmc.mk > ./package/kodi-visualisation-goom/kodi-visualisation-goom.mk > ./package/kodi-visualisation-matrix/kodi-visualisation-matrix.mk > ./package/kodi-visualisation-shadertoy/kodi-visualisation-shadertoy.mk > ./package/kodi-visualisation-spectrum/kodi-visualisation-spectrum.mk > ./package/kodi-visualisation-starburst/kodi-visualisation-starburst.mk > ./package/kodi-visualisation-waveform/kodi-visualisation-waveform.mk > ./package/lapack/lapack.mk > ./package/lensfun/lensfun.mk > ./package/let-me-create/let-me-create.mk > ./package/leveldb/leveldb.mk > ./package/libabseil-cpp/libabseil-cpp.mk > ./package/libasplib/libasplib.mk > ./package/libcec/libcec.mk > ./package/libcgi/libcgi.mk > ./package/libcodec2/libcodec2.mk > ./package/libcorrect/libcorrect.mk > ./package/libcpprestsdk/libcpprestsdk.mk > ./package/libcuefile/libcuefile.mk > ./package/libcue/libcue.mk > ./package/libeastl/libeastl.mk > ./package/libebml/libebml.mk > ./package/libebur128/libebur128.mk > ./package/libfreeglut/libfreeglut.mk > ./package/libftdi1/libftdi1.mk > ./package/libgeos/libgeos.mk > ./package/libgit2/libgit2.mk > ./package/libglfw/libglfw.mk > ./package/libgta/libgta.mk > ./package/libical/libical.mk > ./package/libiec61850/libiec61850.mk > ./package/libiio/libiio.mk > ./package/libiqrf/libiqrf.mk > ./package/libks/libks.mk > ./package/libmatroska/libmatroska.mk > ./package/libmdbx/libmdbx.mk > ./package/libminiupnpc/libminiupnpc.mk > ./package/libnetconf2/libnetconf2.mk > ./package/libolm/libolm.mk > ./package/libosmium/libosmium.mk > ./package/libplatform/libplatform.mk > ./package/libressl/libressl.mk > ./package/librsync/librsync.mk > ./package/librtlsdr/librtlsdr.mk > ./package/libsoxr/libsoxr.mk > ./package/libspatialindex/libspatialindex.mk > ./package/libssh/libssh.mk > ./package/libubootenv/libubootenv.mk > ./package/libubox/libubox.mk > ./package/libuci/libuci.mk > ./package/libuecc/libuecc.mk > ./package/libuhttpd/libuhttpd.mk > ./package/liburiparser/liburiparser.mk > ./package/libuwsc/libuwsc.mk > ./package/libvncserver/libvncserver.mk > ./package/libwebsockets/libwebsockets.mk > ./package/libyang/libyang.mk > ./package/libyuv/libyuv.mk > ./package/libzip/libzip.mk > ./package/linphone/linphone.mk > ./package/linux-serial-test/linux-serial-test.mk > ./package/lld/lld.mk > ./package/llvm/llvm.mk > ./package/log4cxx/log4cxx.mk > ./package/log4qt/log4qt.mk > ./package/lua-ev/lua-ev.mk > ./package/lua-sdl2/lua-sdl2.mk > ./package/lugaru/lugaru.mk > ./package/luvi/luvi.mk > ./package/luv/luv.mk > ./package/lzlib/lzlib.mk > ./package/lzo/lzo.mk > ./package/mariadb/mariadb.mk > ./package/mbedtls/mbedtls.mk > ./package/mediastreamer/mediastreamer.mk > ./package/mfgtools/mfgtools.mk > ./package/midori/midori.mk > ./package/minetest/minetest.mk > ./package/minizip/minizip.mk > ./package/mjpg-streamer/mjpg-streamer.mk > ./package/mraa/mraa.mk > ./package/mrp/mrp.mk > ./package/msgpack/msgpack.mk > ./package/musepack/musepack.mk > ./package/nanomsg/nanomsg.mk > ./package/ne10/ne10.mk > ./package/netopeer2/netopeer2.mk > ./package/ninja/ninja.mk > ./package/odhcp6c/odhcp6c.mk > ./package/ogre/ogre.mk > ./package/open62541/open62541.mk > ./package/openal/openal.mk > ./package/opencv3/opencv3.mk > ./package/opencv4/opencv4.mk > ./package/openfpgaloader/openfpgaloader.mk > ./package/openjpeg/openjpeg.mk > ./package/openobex/openobex.mk > ./package/openpowerlink/openpowerlink.mk > ./package/opentracing-cpp/opentracing-cpp.mk > ./package/optee-benchmark/optee-benchmark.mk > ./package/optee-client/optee-client.mk > ./package/optee-examples/optee-examples.mk > ./package/optee-test/optee-test.mk > ./package/ortp/ortp.mk > ./package/osm2pgsql/osm2pgsql.mk > ./package/paho-mqtt-c/paho-mqtt-c.mk > ./package/paho-mqtt-cpp/paho-mqtt-cpp.mk > ./package/physfs/physfs.mk > ./package/piglit/piglit.mk > ./package/pistache/pistache.mk > ./package/pkg-cmake.mk > ./package/poppler/poppler.mk > ./package/protozero/protozero.mk > ./package/pugixml/pugixml.mk > ./package/pulseview/pulseview.mk > ./package/python-pybind/python-pybind.mk > ./package/qhull/qhull.mk > ./package/qjson/qjson.mk > ./package/qpid-proton/qpid-proton.mk > ./package/qt5/qt5webkit/qt5webkit.mk > ./package/quazip/quazip.mk > ./package/rabbitmq-c/rabbitmq-c.mk > ./package/racehound/racehound.mk > ./package/rapidjson/rapidjson.mk > ./package/re2/re2.mk > ./package/read-edid/read-edid.mk > ./package/rpi-userland/rpi-userland.mk > ./package/rtl_433/rtl_433.mk > ./package/rtty/rtty.mk > ./package/sdbus-cpp/sdbus-cpp.mk > ./package/sentry-native/sentry-native.mk > ./package/simple-mail/simple-mail.mk > ./package/snappy/snappy.mk > ./package/snort3/snort3.mk > ./package/solarus/solarus.mk > ./package/spdlog/spdlog.mk > ./package/stellarium/stellarium.mk > ./package/supertuxkart/supertuxkart.mk > ./package/supertux/supertux.mk > ./package/synergy/synergy.mk > ./package/sysdig/sysdig.mk > ./package/sysrepo/sysrepo.mk > ./package/taglib/taglib.mk > ./package/taskd/taskd.mk > ./package/tcf-agent/tcf-agent.mk > ./package/thrift/thrift.mk > ./package/timescaledb/timescaledb.mk > ./package/tinyxml2/tinyxml2.mk > ./package/ttyd/ttyd.mk > ./package/ubus/ubus.mk > ./package/uhd/uhd.mk > ./package/uhttpd/uhttpd.mk > ./package/unionfs/unionfs.mk > ./package/unzip/unzip.mk > ./package/uqmi/uqmi.mk > ./package/ustream-ssl/ustream-ssl.mk > ./package/utf8proc/utf8proc.mk > ./package/uvw/uvw.mk > ./package/valijson/valijson.mk > ./package/vulkan-headers/vulkan-headers.mk > ./package/waffle/waffle.mk > ./package/wampcc/wampcc.mk > ./package/waylandpp/waylandpp.mk > ./package/webkitgtk/webkitgtk.mk > ./package/websocketpp/websocketpp.mk > ./package/wireshark/wireshark.mk > ./package/woff2/woff2.mk > ./package/wpewebkit/wpewebkit.mk > ./package/x265/x265.mk > ./package/xerces/xerces.mk > ./package/xmrig/xmrig.mk > ./package/yajl/yajl.mk > ./package/yaml-cpp/yaml-cpp.mk > ./package/ympd/ympd.mk > ./package/zlib-ng/zlib-ng.mk > ./package/znc/znc.mk > ./package/zxing-cpp/zxing-cpp.mk > ./package/zziplib/zziplib.mk Ah, I guess you grepped the *.mk files for "cmake-package"; that didn't cross my mind but now that it crossed my mind I feel silly for not thinking about it before ^_^ > The list is much longer than the ~10 samples you have taken I'm afraid :-) Of course I knew it would be way longer, but I wanted to show something quick after yesterday's discussion on IRC. I'll keep poking at things to see how it fares for the rest of packages above and publish updated versions of the patch set as I go fixing things. Cheers, —Adrián [-- Attachment #1.2: signature.asc --] [-- Type: application/pgp-signature, Size: 195 bytes --] [-- Attachment #2: Type: text/plain, Size: 150 bytes --] _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages 2022-01-12 15:09 ` Adrian Perez de Castro @ 2022-01-12 16:02 ` Thomas Petazzoni 0 siblings, 0 replies; 25+ messages in thread From: Thomas Petazzoni @ 2022-01-12 16:02 UTC (permalink / raw) To: Adrian Perez de Castro; +Cc: Eric Le Bihan, Samuel Martin, buildroot On Wed, 12 Jan 2022 17:09:38 +0200 Adrian Perez de Castro <aperez@igalia.com> wrote: > Ah, I guess you grepped the *.mk files for "cmake-package"; that didn't > cross my mind but now that it crossed my mind I feel silly for not thinking > about it before ^_^ Exactly what I did, indeed. Please note that we do not require that absolutely all packages are tested before merging this. The autobuilders will not their amount of work there to validate everything. But it would be good to have tested a wider configuration with more CMake packages enabled. Make sure to include the defconfig you have tested in the cover letter. Thanks! Thomas -- Thomas Petazzoni, co-owner and CEO, Bootlin Embedded Linux and Kernel engineering and training https://bootlin.com _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages 2022-01-12 13:26 [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro ` (2 preceding siblings ...) 2022-01-12 14:36 ` [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages Thomas Petazzoni @ 2022-01-12 16:05 ` Alexander Dahl 2022-01-12 16:47 ` Adrian Perez de Castro 2022-07-24 13:05 ` Arnout Vandecappelle 4 siblings, 1 reply; 25+ messages in thread From: Alexander Dahl @ 2022-01-12 16:05 UTC (permalink / raw) To: Adrian Perez de Castro Cc: Eric Le Bihan, Samuel Martin, Thomas Petazzoni, buildroot [-- Attachment #1.1: Type: text/plain, Size: 3154 bytes --] Hello Adrian, On Wed, Jan 12, 2022 at 03:26:16PM +0200, Adrian Perez de Castro wrote: > As discussed yesterday, here is a quick stab for testing and getting the > conversation started about using Ninja for CMake-based packages (hence the > missing documentation updates and the "RFC" tag in the subject :-D). I miss some general motivation for switching from Makefile to Ninja generator. Can you add some reasoning or numbers to upcoming patch set revisions? Thanks and greets Alex > > In order to avoid the circular dependency of host-ninja requiring itself, > ninja.mk gets changed to use host-generic-package with a build command > that plainly runs the compiler on the set of sources we know are needed > to build a minimal usable version of it under Unix-y systems. This is > basically the list of sources that CMake would have picked (as per the > CMakeLists.txt file) passed straight to $(HOSTCXX). > > The next change modifies pkg-cmake.mk to always pass -GNinja and removes > the $(<PKG>_INSTALL[_STAGING,_TARGET]_OPTS) variables, because when using > Ninja the "install/fast" targets are not generated by CMake (those are > an internal detail of the Makefile generator, it seems). For consistency > with the Meson package infrastructure variables $(NINJA), $(<PKG>_NINJA_ENV) > and $(NINJA_OPTS) are honored by the default set of build/install commands. > > Now, there might be packages that break with this, and I would be > particularly concerned about things like packages which use CMake and > build out-of-tree kernel modules (as the kernel build infrastructure is > all Make, and only Make!) but the changes included were enough for me > to get Raspberry Pi images built with WebKit (both GTK and WPE ports) > in it, which results in the following built using [host-]cmake-package: > > - brotli > - cog > - jpeg-turbo > - openjpeg > - webkitgtk > - webp > - woff2 > - wpewebkit > > While not a long list by any means, I think it shows a decent sample of > packages coming from different development teams that work just fine > switching to Ninja. > > If anybody can suggest something with a bigger number of CMake packages to > build (or a .config file to share) I will be more than happy to give it a > test this with these patches applied :) > > Cheers, > -Adrian > > > Adrian Perez de Castro (2): > package/ninja: do not require cmake > package/pkg-cmake.mk: use ninja instead of make > > package/ninja/ninja.mk | 36 +++++++++++++++++++++++++++++++++++- > package/pkg-cmake.mk | 24 ++++++++++++++---------- > 2 files changed, 49 insertions(+), 11 deletions(-) > > -- > 2.34.1 > > _______________________________________________ > buildroot mailing list > buildroot@buildroot.org > https://lists.buildroot.org/mailman/listinfo/buildroot -- /"\ ASCII RIBBON | »With the first link, the chain is forged. The first \ / CAMPAIGN | speech censured, the first thought forbidden, the X AGAINST | first freedom denied, chains us all irrevocably.« / \ HTML MAIL | (Jean-Luc Picard, quoting Judge Aaron Satie) [-- Attachment #1.2: signature.asc --] [-- Type: application/pgp-signature, Size: 833 bytes --] [-- Attachment #2: Type: text/plain, Size: 150 bytes --] _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages 2022-01-12 16:05 ` Alexander Dahl @ 2022-01-12 16:47 ` Adrian Perez de Castro 2022-01-12 18:55 ` Arnout Vandecappelle 0 siblings, 1 reply; 25+ messages in thread From: Adrian Perez de Castro @ 2022-01-12 16:47 UTC (permalink / raw) To: Alexander Dahl; +Cc: Eric Le Bihan, Samuel Martin, Thomas Petazzoni, buildroot [-- Attachment #1.1: Type: text/plain, Size: 863 bytes --] Hi Alexander, On Wed, 12 Jan 2022 17:05:13 +0100 Alexander Dahl <post@lespocky.de> wrote: > On Wed, Jan 12, 2022 at 03:26:16PM +0200, Adrian Perez de Castro wrote: > > As discussed yesterday, here is a quick stab for testing and getting the > > conversation started about using Ninja for CMake-based packages (hence the > > missing documentation updates and the "RFC" tag in the subject :-D). > > I miss some general motivation for switching from Makefile to Ninja > generator. Can you add some reasoning or numbers to upcoming patch set > revisions? Ninja is generally faster, tends to make better use of parallelism, and in my experience less likely to break in odd ways. Once I have a defconfig with a bigger set of CMake-based packages working I'll do some numbers as well to compare build times before and after the switch to Ninja. Cheers, —Adrián [-- Attachment #1.2: signature.asc --] [-- Type: application/pgp-signature, Size: 195 bytes --] [-- Attachment #2: Type: text/plain, Size: 150 bytes --] _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages 2022-01-12 16:47 ` Adrian Perez de Castro @ 2022-01-12 18:55 ` Arnout Vandecappelle 2022-01-13 15:49 ` Thomas Petazzoni 0 siblings, 1 reply; 25+ messages in thread From: Arnout Vandecappelle @ 2022-01-12 18:55 UTC (permalink / raw) To: Adrian Perez de Castro, Alexander Dahl Cc: Eric Le Bihan, Samuel Martin, Thomas Petazzoni, buildroot On 12/01/2022 17:47, Adrian Perez de Castro wrote: > Hi Alexander, > > On Wed, 12 Jan 2022 17:05:13 +0100 Alexander Dahl <post@lespocky.de> wrote: > >> On Wed, Jan 12, 2022 at 03:26:16PM +0200, Adrian Perez de Castro wrote: >>> As discussed yesterday, here is a quick stab for testing and getting the >>> conversation started about using Ninja for CMake-based packages (hence the >>> missing documentation updates and the "RFC" tag in the subject :-D). >> >> I miss some general motivation for switching from Makefile to Ninja >> generator. Can you add some reasoning or numbers to upcoming patch set >> revisions? > > Ninja is generally faster, tends to make better use of parallelism, and > in my experience less likely to break in odd ways. Once I have a defconfig > with a bigger set of CMake-based packages working I'll do some numbers as > well to compare build times before and after the switch to Ninja. There's one disadvantage to Ninja in Buildroot context: until [1] is fixed, it doesn't collaborate well with top-level parallel build. This means that if you run with a toplevel JLEVEL of e.g. 24, you can easil end up with 40-100 compiles running in parallel. The problem already exists for meson packages, but these are sufficiently rare that they don't pose a problem in practice. I don't know if it's going to become a problem if cmake packages are added to the mix. I don't think this is blocker at all, but it's worth considering. Regards, Arnout [1] https://github.com/ninja-build/ninja/issues/1139 _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages 2022-01-12 18:55 ` Arnout Vandecappelle @ 2022-01-13 15:49 ` Thomas Petazzoni 2022-05-05 21:35 ` James Hilliard 0 siblings, 1 reply; 25+ messages in thread From: Thomas Petazzoni @ 2022-01-13 15:49 UTC (permalink / raw) To: Arnout Vandecappelle Cc: Adrian Perez de Castro, Eric Le Bihan, Alexander Dahl, Samuel Martin, buildroot On Wed, 12 Jan 2022 19:55:03 +0100 Arnout Vandecappelle <arnout@mind.be> wrote: > There's one disadvantage to Ninja in Buildroot context: until [1] is fixed, it > doesn't collaborate well with top-level parallel build. This means that if you > run with a toplevel JLEVEL of e.g. 24, you can easil end up with 40-100 compiles > running in parallel. The problem already exists for meson packages, but these > are sufficiently rare that they don't pose a problem in practice. I don't know > if it's going to become a problem if cmake packages are added to the mix. meson-based packages are no longer rare: we now have 116 packages using the meson-package infrastructure, including very high profile packages such as systemd, mesa3d, libglib2, and more. It is still higher than the 328 cmake-based package we have of course, but I wouldn't say that meson is "sufficiently rare" :-) Annoying that this problem hasn't been resolved in upstream ninja :-/ Thomas -- Thomas Petazzoni, co-owner and CEO, Bootlin Embedded Linux and Kernel engineering and training https://bootlin.com _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages 2022-01-13 15:49 ` Thomas Petazzoni @ 2022-05-05 21:35 ` James Hilliard 0 siblings, 0 replies; 25+ messages in thread From: James Hilliard @ 2022-05-05 21:35 UTC (permalink / raw) To: Thomas Petazzoni Cc: Eric Le Bihan, Samuel Martin, Alexander Dahl, buildroot, Adrian Perez de Castro On Thu, Jan 13, 2022 at 8:49 AM Thomas Petazzoni <thomas.petazzoni@bootlin.com> wrote: > > On Wed, 12 Jan 2022 19:55:03 +0100 > Arnout Vandecappelle <arnout@mind.be> wrote: > > > There's one disadvantage to Ninja in Buildroot context: until [1] is fixed, it > > doesn't collaborate well with top-level parallel build. This means that if you > > run with a toplevel JLEVEL of e.g. 24, you can easil end up with 40-100 compiles > > running in parallel. The problem already exists for meson packages, but these > > are sufficiently rare that they don't pose a problem in practice. I don't know > > if it's going to become a problem if cmake packages are added to the mix. > > meson-based packages are no longer rare: we now have 116 packages using > the meson-package infrastructure, including very high profile packages > such as systemd, mesa3d, libglib2, and more. > > It is still higher than the 328 cmake-based package we have of course, > but I wouldn't say that meson is "sufficiently rare" :-) > > Annoying that this problem hasn't been resolved in upstream ninja :-/ We're now using kitware/cmake's fork with jobserver support FYI: https://github.com/buildroot/buildroot/commit/227d7e0cbaaf093f509f5728f06fad5f53caed7b > > Thomas > -- > Thomas Petazzoni, co-owner and CEO, Bootlin > Embedded Linux and Kernel engineering and training > https://bootlin.com > _______________________________________________ > buildroot mailing list > buildroot@buildroot.org > https://lists.buildroot.org/mailman/listinfo/buildroot _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
* Re: [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages 2022-01-12 13:26 [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro ` (3 preceding siblings ...) 2022-01-12 16:05 ` Alexander Dahl @ 2022-07-24 13:05 ` Arnout Vandecappelle 4 siblings, 0 replies; 25+ messages in thread From: Arnout Vandecappelle @ 2022-07-24 13:05 UTC (permalink / raw) To: Adrian Perez de Castro, buildroot Cc: Eric Le Bihan, Samuel Martin, Thomas Petazzoni Hi Adrián, Are you still interested to respin this series? It would be nice to have this feature - especially since e.g. Qt6 in fact *expects* to be built with Ninja. On 12/01/2022 14:26, Adrian Perez de Castro wrote: > Hello everybody, > > As discussed yesterday, here is a quick stab for testing and getting the > conversation started about using Ninja for CMake-based packages (hence the > missing documentation updates and the "RFC" tag in the subject :-D). Documentation is of course needed for the non-RFC one. For testing, we agreed that it's sufficient to test on a few (10-20) major packages and rely on the autobuilders for the rest. > In order to avoid the circular dependency of host-ninja requiring itself, > ninja.mk gets changed to use host-generic-package with a build command > that plainly runs the compiler on the set of sources we know are needed > to build a minimal usable version of it under Unix-y systems. This is > basically the list of sources that CMake would have picked (as per the > CMakeLists.txt file) passed straight to $(HOSTCXX). To avoid this hack: we thought it should be simple to allow a package to use Makefiles instead of Ninja, by: - using an approach like [1] to call 'cmake' to do the build and install instead of calling 'ninja' directly; - packages that really require makefiles can pass '-GUnix Makefiles' in <PKG>_CONFIGURE_OPTS (the second -G should override the first one, I hope). This can be used by ninja to keep on building itself with cmake. > The next change modifies pkg-cmake.mk to always pass -GNinja and removes > the $(<PKG>_INSTALL[_STAGING,_TARGET]_OPTS) variables, because when using > Ninja the "install/fast" targets are not generated by CMake (those are > an internal detail of the Makefile generator, it seems). For consistency > with the Meson package infrastructure variables $(NINJA), $(<PKG>_NINJA_ENV) > and $(NINJA_OPTS) are honored by the default set of build/install commands. > > Now, there might be packages that break with this, and I would be > particularly concerned about things like packages which use CMake and > build out-of-tree kernel modules (as the kernel build infrastructure is > all Make, and only Make!) but the changes included were enough for me > to get Raspberry Pi images built with WebKit (both GTK and WPE ports) > in it, which results in the following built using [host-]cmake-package: > > - brotli > - cog > - jpeg-turbo > - openjpeg > - webkitgtk > - webp > - woff2 > - wpewebkit > > While not a long list by any means, I think it shows a decent sample of > packages coming from different development teams that work just fine > switching to Ninja. > > If anybody can suggest something with a bigger number of CMake packages to > build (or a .config file to share) I will be more than happy to give it a > test this with these patches applied :) I think gnuradio is also a good one to test, it has a fairly complicated build system IIRC. > > Cheers, > -Adrian Regards, Arnout [1] https://patchwork.ozlabs.org/project/buildroot/patch/20220722060936.566534-1-james.hilliard1@gmail.com/ > > > Adrian Perez de Castro (2): > package/ninja: do not require cmake > package/pkg-cmake.mk: use ninja instead of make > > package/ninja/ninja.mk | 36 +++++++++++++++++++++++++++++++++++- > package/pkg-cmake.mk | 24 ++++++++++++++---------- > 2 files changed, 49 insertions(+), 11 deletions(-) > _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 25+ messages in thread
end of thread, other threads:[~2022-07-24 13:18 UTC | newest] Thread overview: 25+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2022-01-12 13:26 [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro 2022-01-12 13:26 ` [Buildroot] [PATCH RFC 1/2] package/ninja: do not require cmake Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 1/7] package/ninja: do not require cmake Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 2/7] package/pkg-cmake.mk: use ninja instead of make Adrian Perez de Castro 2022-07-24 13:16 ` Arnout Vandecappelle 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 3/7] package/musepack: use MUSEPACK_NINJA_OPTS Adrian Perez de Castro 2022-07-24 13:18 ` Arnout Vandecappelle 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 4/7] package/mariadb: use HOST_MARIADB_NINJA_OPTS Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 5/7] package/kf5/kf5-extra-cmake-modules: do not build documentation Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 6/7] package/libcorrect: avoid multiple rules for same target Adrian Perez de Castro 2022-01-21 15:42 ` [Buildroot] [PATCH RFC v2 7/7] package/racehound: add patch to support building with ninja Adrian Perez de Castro 2022-01-21 15:53 ` [Buildroot] [PATCH RFC v2 0/7] Use Ninja as build tool for CMake-based packages Adrian Perez de Castro 2022-01-12 13:26 ` [Buildroot] [PATCH RFC 2/2] package/pkg-cmake.mk: use ninja instead of make Adrian Perez de Castro 2022-01-12 14:35 ` Thomas Petazzoni 2022-01-12 16:51 ` Adrian Perez de Castro 2022-01-12 14:36 ` [Buildroot] [PATCH RFC 0/2] Use Ninja as build tool for CMake-based packages Thomas Petazzoni 2022-01-12 15:09 ` Adrian Perez de Castro 2022-01-12 16:02 ` Thomas Petazzoni 2022-01-12 16:05 ` Alexander Dahl 2022-01-12 16:47 ` Adrian Perez de Castro 2022-01-12 18:55 ` Arnout Vandecappelle 2022-01-13 15:49 ` Thomas Petazzoni 2022-05-05 21:35 ` James Hilliard 2022-07-24 13:05 ` Arnout Vandecappelle
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.