From: Thomas Petazzoni via buildroot <buildroot@buildroot.org>
To: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Cc: buildroot@buildroot.org, Bernd Kuhls <bernd@kuhls.net>,
Eric Le Bihan <eric.le.bihan.dev@free.fr>
Subject: Re: [Buildroot] [PATCH v2 2/2] package/drogon: new package
Date: Thu, 1 Jan 2026 14:41:09 +0100 [thread overview]
Message-ID: <20260101144109.4ae20fd8@windsurf> (raw)
In-Reply-To: <20251109101711.493759-2-dario.binacchi@amarulasolutions.com>
Hello Dario,
On Sun, 9 Nov 2025 11:17:08 +0100
Dario Binacchi <dario.binacchi@amarulasolutions.com> wrote:
> Drogon is a C++17/20 based HTTP application framework. It can be used to
> easily build various types of web application server programs using C++.
>
> Project page: https://github.com/drogonframework/drogon
>
> Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
Thanks a lot for this new package proposal. It looks pretty good
overall, I only have a few requests below.
> diff --git a/package/drogon/0001-cmake-fix-cross-compiling-for-drogon_ctl.patch b/package/drogon/0001-cmake-fix-cross-compiling-for-drogon_ctl.patch
> new file mode 100644
> index 000000000000..70ec298cf5b8
> --- /dev/null
> +++ b/package/drogon/0001-cmake-fix-cross-compiling-for-drogon_ctl.patch
> @@ -0,0 +1,81 @@
> +From 3eda90ee8f46a9f309bf27e7faaf7f2dea1a7fde Mon Sep 17 00:00:00 2001
> +From: Dario Binacchi <dario.binacchi@amarulasolutions.com>
> +Date: Tue, 23 Sep 2025 11:37:59 +0200
> +Subject: [PATCH] cmake: fix cross-compiling for drogon_ctl
> +
> +Fix the the following errors raised by building drogon in Buildroot:
> +
> +[ 70%] Generating filter_cc.h, filter_cc.cc
> +cd ~/buildroot/output/build/drogon-v1.9.11/drogon_ctl && ./_drogon_ctl create view ~/buildroot/output/build/drogon-v1.9.11/drogon_ctl/templates/config_yaml.csp
> +cd ~/buildroot/output/build/drogon-v1.9.11/drogon_ctl && ./_drogon_ctl create view ~/buildroot/output/build/drogon-v1.9.11/drogon_ctl/templates/demoMain.csp
> +cd ~/buildroot/output/build/drogon-v1.9.11/drogon_ctl && ./_drogon_ctl create view ~/buildroot/output/build/drogon-v1.9.11/drogon_ctl/templates/filter_cc.csp
> +[ 71%] Generating test_main.h, test_main.cc
> +cd ~/buildroot/output/build/drogon-v1.9.11/drogon_ctl && ./_drogon_ctl create view ~/buildroot/output/build/drogon-v1.9.11/drogon_ctl/templates/cmake.csp
> +/bin/sh: 1: ./_drogon_ctl: Exec format error
> +/bin/sh: 1: ./_drogon_ctl: Exec format error
> +make[4]: *** [drogon_ctl/CMakeFiles/drogon_ctl.dir/build.make:88: drogon_ctl/config_yaml.h] Error 126
> +make[4]: *** Waiting for unfinished jobs....
> +make[4]: *** [drogon_ctl/CMakeFiles/drogon_ctl.dir/build.make:95: drogon_ctl/demoMain.h] Error 126
> +/bin/sh: 1: ./_drogon_ctl: Exec format error
> +make[4]: *** [drogon_ctl/CMakeFiles/drogon_ctl.dir/build.make:102: drogon_ctl/filter_cc.h] Error 126
> +/bin/sh: 1: ./_drogon_ctl: Exec format error
> +make[4]: *** [drogon_ctl/CMakeFiles/drogon_ctl.dir/build.make:74: drogon_ctl/cmake.h] Error 126
> +
> +When building drogon_ctl during cross-compilation, the host version of
> +_drogon_ctl must be used to generate output files, since the target
> +binary cannot run on the host.
> +
> +The change ensures that drogon_ctl builds correctly both for native and
> +cross-compiling environments.
> +
> +Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
> +Upstream: https://github.com/drogonframework/drogon/pull/2389/commits/3eda90ee8f46a9f309bf27e7faaf7f2dea1a7fde
It seems like this PR has been merged. Could you replace all Upstream:
links with the link to the final commit? And if any changes were made
as part of the review process, update the patches accordingly?
> +Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
> +Upstream: https://github.com/drogonframework/drogon/pull/2389/commits/77a8e3c91494ae094b5b1b18594ffaec11d37310
Same.
> +Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
> +Upstream: https://github.com/drogonframework/drogon/pull/2389/commits/535892bf6958c8d5619251ead204ada0002a8674
Same.
> +Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
> +Upstream: https://github.com/an-tao/trantor/pull/380
Here as well, the PR has been merged, so this should be updated.
> diff --git a/package/drogon/Config.in b/package/drogon/Config.in
> new file mode 100644
> index 000000000000..0db4258e309e
> --- /dev/null
> +++ b/package/drogon/Config.in
> @@ -0,0 +1,40 @@
> +config BR2_PACKAGE_DROGON
> + bool "drogon"
> + depends on BR2_INSTALL_LIBSTDCPP
> + depends on BR2_TOOLCHAIN_GCC_AT_LEAST_11 # C++17/20
> + depends on BR2_TOOLCHAIN_HAS_THREADS
> + select BR2_PACKAGE_JSONCPP
> + select BR2_PACKAGE_UTIL_LINUX
> + select BR2_PACKAGE_UTIL_LINUX_LIBUUID
> + select BR2_PACKAGE_ZLIB
> + help
> + Drogon is a C++17/20 based HTTP application framework.
> + Drogon can be used to easily build various types of web
> + application server programs using C++.
> +
> + https://github.com/drogonframework/drogon
> +
> +if BR2_PACKAGE_DROGON
> +
> +config BR2_PACKAGE_DROGON_BROTLI
> + bool "build Brotli"
What does this do? In Buildroot, Brotli is another package. Is it
related? Unrelated? Is this option enabling Brotli support? Does it
need the external brotli library provided by package/brotli?
A help text would be good, in fact.
> +config BR2_PACKAGE_DROGON_CTL
> + bool "build drogon_ctl"
What does this do? A help text would be good.
> + select BR2_PACKAGE_HOST_DROGON
This option is not needed I believe.
> +
> +config BR2_PACKAGE_DROGON_EXAMPLES
> + bool "build examples"
> +
> +config BR2_PACKAGE_DROGON_ORM
> + bool "build orm"
A help text would be nice.
> +
> +config BR2_PACKAGE_DROGON_YAML_CONFIG
> + bool "build yaml config"
A help text would be nice.
> diff --git a/package/drogon/Config.in.host b/package/drogon/Config.in.host
> new file mode 100644
> index 000000000000..b3b691e2cfe2
> --- /dev/null
> +++ b/package/drogon/Config.in.host
> @@ -0,0 +1,20 @@
> +config BR2_PACKAGE_HOST_DROGON
This option is not needed, host-drogon is just a build dependency of
drogon, so we don't need to have a visible menuconfig option for it.
> + bool "drogon"
This should have been:
bool "host-drogon"
but it's anyway not needed.
> + depends on BR2_HOST_INSTALL_LIBSTDCPP
Option doesn't exist.
> + depends on BR2_HOST_TOOLCHAIN_GCC_AT_LEAST_11 # C++17/20
Same.
> + depends on BR2_HOST_TOOLCHAIN_HAS_THREADS
Same.
> + select BR2_HOST_PACKAGE_JSONCPP
> + select BR2_HOST_PACKAGE_UTIL_LINUX
> + select BR2_HOST_PACKAGE_UTIL_LINUX_LIBUUID
> + select BR2_HOST_PACKAGE_ZLIB
Those options don't exist.
(But this is moot, as this whole file should be dropped, but I just
wanted to point out that you got it wrong on this).
> diff --git a/package/drogon/drogon.mk b/package/drogon/drogon.mk
> new file mode 100644
> index 000000000000..64ad08f4ab42
> --- /dev/null
> +++ b/package/drogon/drogon.mk
> @@ -0,0 +1,62 @@
> +################################################################################
> +#
> +# drogon
> +#
> +################################################################################
> +
> +DROGON_VERSION = v1.9.11
> +# DROGON_SITE = $(call github,drogonframework,drogon,v$(DROGON_VERSION))
Remove this line.
> +DROGON_SITE = https://github.com/drogonframework/drogon
> +DROGON_SITE_METHOD = git
> +DROGON_GIT_SUBMODULES = YES
> +DROGON_LICENSE = MIT
> +DROGON_LICENSE_FILES = LICENSE
> +DROGON_INSTALL_STAGING = YES
> +DROGON_DEPENDENCIES = jsoncpp util-linux zlib
> +HOST_DROGON_DEPENDENCIES = host-jsoncpp host-util-linux host-zlib
> +
> +DROGON_CONF_OPTS = \
> + -DBUILD_TESTS=OFF
> +
> +HOST_DROGON_CONF_OPTS = \
> + -DBUILD_TESTS=OFF \
> + -DBUILD_EXAMPLES=OFF
> +
> +ifeq ($(BR2_PACKAGE_DROGON_BROTLI),y)
> +DROGON_CONF_OPTS += -DBUILD_BROTLI=ON
> +else
> +DROGON_CONF_OPTS += -DBUILD_BROTLI=OFF
> +endif
> +
> +ifeq ($(BR2_PACKAGE_DROGON_CTL),y)
> +# When we have drogon_ctl for the target, we need to build the
> +# _drogon_ctl tool with host-drogon support so that it can be
> +# run during the building process
> +DROGON_DEPENDENCIES += host-drogon
> +DROGON_CONF_OPTS += -DBUILD_CTL=ON
> +HOST_DROGON_CONF_OPTS += -DBUILD_CTL=ON
Since host-drogon is only built when BR2_PACKAGE_DROGON_CTL, this
-DBUILD_CTL=ON for HOST_DROGON_CONF_OPTS should be in the unconditional
assignment of HOST_DROGON_CONF_OPTS (with -DBUILD_TESTS=OFF,
-DBUILD_EXAMPLES=OFF).
Could you adjust those details, and send a new iteration?
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
prev parent reply other threads:[~2026-01-01 13:41 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-09 10:17 [Buildroot] [PATCH v2 1/2] package/jsoncpp: add host variant Dario Binacchi
2025-11-09 10:17 ` [Buildroot] [PATCH v2 2/2] package/drogon: new package Dario Binacchi
2026-01-01 13:41 ` Thomas Petazzoni via buildroot [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260101144109.4ae20fd8@windsurf \
--to=buildroot@buildroot.org \
--cc=bernd@kuhls.net \
--cc=dario.binacchi@amarulasolutions.com \
--cc=eric.le.bihan.dev@free.fr \
--cc=thomas.petazzoni@bootlin.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox