From: "Yann E. MORIN" <yann.morin.1998@free.fr>
To: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Cc: Norbert Lange <nolange79@gmail.com>,
Sen Hastings <sen@hastings.org>,
buildroot@buildroot.org
Subject: Re: [Buildroot] [PATCH] package/systemd: account for arch dependency of vmspawn support
Date: Mon, 19 Aug 2024 22:41:23 +0200 [thread overview]
Message-ID: <ZsOt8zO2Ne5rUvaf@landeda> (raw)
In-Reply-To: <20240818122521.955359-1-thomas.petazzoni@bootlin.com>
Thomas, All,
On 2024-08-18 14:25 +0200, Thomas Petazzoni via buildroot spake thusly:
> Since upstream commit
> 5c57a8650630304d8434a348283b6b643fbc676b ("vmspawn: add support for
> -D/--directory"), src/vmspawn/vmspawn-util.h defines a
> QEMU_MACHINE_TYPE based on the architecture, and not all architectures
> are supported. This commit first appeared in systemd v256.
>
> Due to this, the unsupported architectures fail with:
>
> In file included from ../src/vmspawn/vmspawn-util.c:27:
> ../src/vmspawn/vmspawn-util.h:46:4: error: #error "No qemu machine defined for this architecture"
> 46 | # error "No qemu machine defined for this architecture"
> | ^~~~~
>
> So let's add a BR2_PACKAGE_SYSTEMD_VMSPAWN_ARCH_SUPPORTS and use it to
> ensure vmspawn support is only used on architectures that are
> supported. Even though no-one selects BR2_PACKAGE_SYSTEMD_VMSPAWN (and
> would therefore need to inherit the
> BR2_PACKAGE_SYSTEMD_VMSPAWN_ARCH_SUPPORTS dependency), we nevertheless
> introduce BR2_PACKAGE_SYSTEMD_VMSPAWN_ARCH_SUPPORTS to make the
> depency list prettier than a long "depends on A || B || C || D ||
> ...".
Yes, that's much clearer that way, thanks!
> Fixes:
>
> http://autobuild.buildroot.net/results/0e614375f731f7bfe3c6041c6e89a09c31898053/
>
> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Applied to master, thanks.
Regards,
Yann E. MORIN.
> ---
> package/systemd/Config.in | 14 ++++++++++++++
> 1 file changed, 14 insertions(+)
>
> diff --git a/package/systemd/Config.in b/package/systemd/Config.in
> index 6708adce9b..113a8093c4 100644
> --- a/package/systemd/Config.in
> +++ b/package/systemd/Config.in
> @@ -599,8 +599,22 @@ config BR2_PACKAGE_SYSTEMD_VCONSOLE_DEFAULT_KEYMAP
> Default keymap for the system. Leave empty to not set a
> default keymap.
>
> +# See for which architectures QEMU_MACHINE_TYPE is defined in
> +# src/vmspawn/vmspawn-util.h
> +config BR2_PACKAGE_SYSTEMD_VMSPAWN_ARCH_SUPPORTS
> + bool
> + default y if BR2_aarch64 || BR2_aarch64_be
> + default y if BR2_arm || BR2_armeb
> + default y if BR2_i386
> + default y if BR2_mips || BR2_mips64 || BR2_mipsel || BR2_mips64el
> + default y if BR2_powerpc || BR2_powerpc64 || BR2_powerpc64le
> + default y if BR2_riscv
> + default y if BR2_s390x
> + default y if BR2_x86_64
> +
> config BR2_PACKAGE_SYSTEMD_VMSPAWN
> bool "enable vmspawn"
> + depends on BR2_PACKAGE_SYSTEMD_VMSPAWN_ARCH_SUPPORTS
> help
> systemd-vmspawn may be used to start a virtual machine
> from an OS image. In many ways it is similar to
> --
> 2.46.0
>
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
prev parent reply other threads:[~2024-08-19 20:41 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-18 12:25 [Buildroot] [PATCH] package/systemd: account for arch dependency of vmspawn support Thomas Petazzoni via buildroot
2024-08-19 20:41 ` Yann E. MORIN [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=ZsOt8zO2Ne5rUvaf@landeda \
--to=yann.morin.1998@free.fr \
--cc=buildroot@buildroot.org \
--cc=nolange79@gmail.com \
--cc=sen@hastings.org \
--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