kumquat-buildroot/package/libgpg-error/Config.in
Julien Olivain 3b655b9cb1 package/libgpg-error: needs MMU
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 dependency on BR2_USE_MMU
in BR2_PACKAGE_LIBGPG_ERROR_ARCH_SUPPORTS. Doing so will
automatically propagates this dependency to all packages using
libgpg-error (and thus, already depending on this _ARCH_SUPPORTS).

Fixes:
http://autobuild.buildroot.org/results/dbc82ba08e6a30c2f558c8c36ad7eeb0e3cab090/
http://autobuild.buildroot.org/results/074a803de0f48cd86b9135cca50f136cccf1bcea/
http://autobuild.buildroot.org/results/4c1966a71020af31c1dc1b0a13a3928c84e75874/
...and many others.

[1] https://git.gnupg.org/cgi-bin/gitweb.cgi?p=libgpg-error.git;a=commitdiff;h=8f41cc23b12485404203be5881aaaadb78696b4d
[2] https://git.gnupg.org/cgi-bin/gitweb.cgi?p=libgpg-error.git;a=commitdiff;h=1865c0ba1769b407a3c504f1ab0a4278704a9fc1
[3] 692d191c8b

Signed-off-by: Julien Olivain <ju.o@free.fr>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
(cherry picked from commit fee74a7a9f535f782626ccf0e4d88b623333fe1c)
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2024-09-16 10:27:50 +02:00

65 lines
1.8 KiB
Plaintext

config BR2_PACKAGE_LIBGPG_ERROR_ARCH_SUPPORTS
bool
# see src/syscfg/
default y if \
BR2_aarch64 || BR2_aarch64_be || \
BR2_arm || BR2_armeb || \
BR2_i386 || BR2_mips || \
BR2_mipsel || BR2_mips64 || \
BR2_mips64el || BR2_m68k || \
BR2_nios2 || BR2_or1k || \
BR2_powerpc || BR2_powerpc64 || \
BR2_powerpc64le || BR2_RISCV_64 || \
BR2_RISCV_32 || BR2_s390x || \
BR2_sh4 || BR2_sh4eb || \
BR2_sh4a || BR2_sh4aeb || \
BR2_sparc || BR2_sparc64 || \
BR2_x86_64
depends on BR2_USE_MMU # fork()
config BR2_PACKAGE_LIBGPG_ERROR
bool "libgpg-error"
depends on BR2_PACKAGE_LIBGPG_ERROR_ARCH_SUPPORTS
help
Libgpg-error is a small library with error codes and
descriptions shared by most GnuPG related software.
https://www.gnupg.org/related_software/libgpg-error
config BR2_PACKAGE_LIBGPG_ERROR_SYSCFG
string
default "aarch64-unknown-linux-gnu" \
if BR2_aarch64 || BR2_aarch64_be
default "arm-unknown-linux-gnueabi" \
if BR2_arm || BR2_armeb
default "i686-pc-linux-gnu" \
if BR2_i386
default "mips-unknown-linux-gnu" \
if BR2_mips || BR2_mipsel
default "mips64el-unknown-linux-gnuabi64" \
if BR2_mips64 || BR2_mips64el
default "m68k-unknown-linux-gnu" \
if BR2_m68k
default "nios2-unknown-linux-gnu" \
if BR2_nios2
default "or1k-unknown-linux-gnu" \
if BR2_or1k
default "powerpc-unknown-linux-gnu" \
if BR2_powerpc
default "powerpc64-unknown-linux-gnu" \
if BR2_powerpc64 || BR2_powerpc64le
default "riscv32-unknown-linux-gnu" \
if BR2_RISCV_32
default "riscv64-unknown-linux-gnu" \
if BR2_RISCV_64
default "s390x-unknown-linux-gnu" \
if BR2_s390x
default "sh4-unknown-linux-gnu" \
if BR2_sh4 || BR2_sh4eb || BR2_sh4a || BR2_sh4aeb
default "sparc-unknown-linux-gnu" \
if BR2_sparc
default "sparc64-unknown-linux-gnu" \
if BR2_sparc64
default "x86_64-unknown-linux-gnu" \
if BR2_x86_64