From: Thomas Petazzoni via buildroot <buildroot@buildroot.org>
To: Julien Olivain <ju.o@free.fr>
Cc: Marcus Folkesson <marcus.folkesson@gmail.com>, buildroot@buildroot.org
Subject: Re: [Buildroot] [PATCH 1/1] package/libgpg-error: needs MMU
Date: Mon, 12 Aug 2024 22:30:19 +0200 [thread overview]
Message-ID: <20240812223019.48ea512a@windsurf> (raw)
In-Reply-To: <20240811141356.1201929-1-ju.o@free.fr>
On Sun, 11 Aug 2024 16:13:56 +0200
Julien Olivain <ju.o@free.fr> wrote:
> libgpg-error imported code using fork() in commit [1] and enabled it
> soon after in [2]. Those commits were first included in libgpg-error
> version 1.28.
>
> For reference, the libgpg-error Buildroot package was updated to that
> version in commit [3].
>
> When Buildroot configuration has no MMU support (e.g. BR2_USE_MMU is
> not set), libgpg-error fails to build with error:
>
> /build/host/opt/ext-toolchain/arm-buildroot-uclinux-uclibcgnueabi/bin/ld.real: ./.libs/libgpg-error.a(libgpg_error_la-spawn-posix.o): in function '_gpgrt_process_spawn':
> spawn-posix.c:(.text+0x630): undefined reference to 'fork'
>
> This issue can be observed with the command:
>
> utils/test-pkg -a -p libgpg-error
>
> It will show few build failures:
>
> ...
> bootlin-armv7m-uclibc [ 6/41]: FAILED
> ...
> bootlin-m68k-5208-uclibc [ 8/41]: FAILED
> ...
>
> This commit fixes the issue by adding the package dependency on
> BR2_USE_MMU.
>
> This commit also propagates this dependency on the libgcrypt and
> libksba packages. They are requiring libgpg-error but had no
> dependency on MMU.
>
> Finally, for completeness, for all other packages requiring
> libgpg-error which already had the dependency on BR2_USE_MMU, the
> corresponding comment is updated to reflect that change. Namely: gcr,
> gnupg2, libassuan, libgpgme, libostree, netatalk, pinentry, vpnc, and
> wireshark.
Thanks for doing this, but it seems to me that you forgot a number of
packages. Basically all packages that "select BR2_PACKAGE_LIBGPG_ERROR"
need to be fixed. And then once you have this list of packages, you
need check all packages that "select" those packages, and so on
recursively. For example, you forgot package/crda, or package/libbdplus.
But in fact. BR2_USE_MMU is an architecture dependency, so simply
update:
config BR2_PACKAGE_LIBGPG_ERROR_ARCH_SUPPORTS
to add a "depends on BR2_USE_MMU". This will magically propagate it.
> Note: for simplifity, few packages already depending on
> BR2_USE_MMU but having libgpg-error as an optional dependency are not
> updated (libjcat, mutt and opkg).
Using "optional dependency" here confused me. When I hear "optional
dependency", I usually think about:
ifeq ($(BR2_PACKAGE_LIBGPG_ERROR),y)
FOOBAR_CONF_OPTS += --enable-bla
FOOBAR_DEPENDENCIES += libgpg-error
else
FOOBAR_CONF_OPTS += --disable-bla
endif
So indeed, for libjcat, it's an optional dependency and in such a case,
we really don't care as BR2_PACKAGE_LIBGPG_ERROR will only be "y" if it
can be enabled.
However, for opkg there's a suboption that selects
BR2_PACKAGE_LIBGPG_ERROR, but the main BR2_PACKAGE_OPKG option already
depends on BR2_USE_MMU. I think you should distinguish the two cases,
but the first one really isn't relevant at all in the discussion, while
the second case matters.
Could you rework your patch to simply put the dep into
BR2_PACKAGE_LIBGPG_ERROR_ARCH_SUPPORTS ?
Thanks a lot!
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
next prev parent reply other threads:[~2024-08-12 20:30 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-11 14:13 [Buildroot] [PATCH 1/1] package/libgpg-error: needs MMU Julien Olivain
2024-08-12 20:30 ` Thomas Petazzoni via buildroot [this message]
2024-09-16 8:31 ` Peter Korsgaard
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=20240812223019.48ea512a@windsurf \
--to=buildroot@buildroot.org \
--cc=ju.o@free.fr \
--cc=marcus.folkesson@gmail.com \
--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