U-Boot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] sandbox: solve undefined reference to pthread_kill symbol
@ 2025-06-03 15:13 Raymond Mao
  2025-06-03 15:47 ` Tom Rini
  0 siblings, 1 reply; 10+ messages in thread
From: Raymond Mao @ 2025-06-03 15:13 UTC (permalink / raw)
  To: u-boot
  Cc: Raymond Mao, Tom Rini, Simon Glass, Heinrich Schuchardt,
	Ilias Apalodimas, Marek Vasut, Peter Robinson, Jerome Forissier,
	Richard Henderson, Adriano Cordova, Michal Simek, Casey Connolly,
	Sughosh Ganu, Rasmus Villemoes, Jonathan Humphreys, Sam Edwards,
	Prasad Kummari

This patch is to solve the sandbox building error:
$ make O=build-sandbox -s sandbox_defconfig
$ make O=build-sandbox -s -j2
/usr/bin/ld: /tmp/u-boot.27rzOu.ltrans58.ltrans.o: undefined reference to symbol 'pthread_kill@@GLIBC_2.2.5'
/usr/bin/ld: /lib/x86_64-linux-gnu/libpthread.so.0: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
[...]

Signed-off-by: Raymond Mao <raymond.mao@linaro.org>
---
 arch/sandbox/config.mk | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/sandbox/config.mk b/arch/sandbox/config.mk
index dd9b7473fa9..9a61e803a57 100644
--- a/arch/sandbox/config.mk
+++ b/arch/sandbox/config.mk
@@ -3,7 +3,7 @@
 
 PLATFORM_CPPFLAGS += -D__SANDBOX__ -U_FORTIFY_SOURCE
 PLATFORM_CPPFLAGS += -fPIC -ffunction-sections -fdata-sections
-PLATFORM_LIBS += -lrt
+PLATFORM_LIBS += -lrt -lpthread
 SDL_CONFIG ?= sdl2-config
 
 # Define this to avoid linking with SDL, which requires SDL libraries
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2025-06-04 15:37 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-06-03 15:13 [PATCH] sandbox: solve undefined reference to pthread_kill symbol Raymond Mao
2025-06-03 15:47 ` Tom Rini
2025-06-03 18:00   ` Raymond Mao
2025-06-03 19:23     ` Tom Rini
2025-06-03 21:00       ` Raymond Mao
2025-06-04 10:03         ` Anshul Dalal
2025-06-04 13:56           ` Tom Rini
2025-06-04 15:03             ` Patrice CHOTARD
2025-06-04 15:12               ` Tom Rini
2025-06-04 15:37             ` Raymond Mao

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox