public inbox for buildroot@busybox.net
 help / color / mirror / Atom feed
From: Andreas Ziegler <br025@umbiko.net>
To: Shubham Chakraborty <chakrabortyshubham66@gmail.com>
Cc: buildroot@buildroot.org, thomas.petazzoni@bootlin.com,
	romain.naour@gmail.com
Subject: Re: [Buildroot] [PATCH v4] Extend the existing patch to also add -lstdc++ to the Libs field, fixing static linking issues with libicuuc.a.
Date: Sat, 28 Mar 2026 05:30:55 +0000	[thread overview]
Message-ID: <cfbf28f28bc1485cfd2245db5120f739@umbiko.net> (raw)
In-Reply-To: <20260327094348.193822-1-chakrabortyshubham66@gmail.com>

Hi Shubham,

Applying this patch now works, build fails, please see below ...

On 2026-03-27 09:43, Shubham Chakraborty wrote:
> This combines the previous 0003 and 0004 changes into a
> single patch, following review feedback from Andreas.

Your previous commit messages were more descriptive. Also 0004 never 
existed in the Buildroot sources ...

> 
> Signed-off-by: Shubham Chakraborty <chakrabortyshubham66@gmail.com>---
> ---
> Changes v3 -> v4:
>   - Clean up patch to remove deleted 0004 patch file
>   - Ensure only 0003 patch is modified; no extra files or deletions
>   - Remove any rebase or history artifacts that caused previous patch 
> failures
> ---
>  .../0003-fix-static-linking-with-icu-uc.patch | 20 +++++++++++++++----
>  1 file changed, 16 insertions(+), 4 deletions(-)
> 
> diff --git a/package/icu/0003-fix-static-linking-with-icu-uc.patch 
> b/package/icu/0003-fix-static-linking-with-icu-uc.patch
> index 36a3d1f696..c58f2700ee 100644
> --- a/package/icu/0003-fix-static-linking-with-icu-uc.patch
> +++ b/package/icu/0003-fix-static-linking-with-icu-uc.patch
> @@ -13,14 +13,26 @@ 
> http://autobuild.buildroot.net/results/210/2107f9dfb39eeb6559fb4271c7af8b39aef52
> 
>  Signed-off-by: Romain Naour <romain.naour@openwide.fr>
>  ---
> - source/Makefile.in | 2 +-
> - 1 file changed, 1 insertion(+), 1 deletion(-)
> +This patch currently addresses linking against stdc++ for 
> shared-library
> +builds. Add -lstdc++ to the static build flags also, to fix 'undefined
> +reference' errors when linking programs like xmlcatalog (libxml2)
> +with musl static toolchains.
> +
> +Upstream: Inactive-Upstream [Buildroot specific]
> +Signed-off-by: Shubham Chakraborty <chakrabortyshubham66@gmail.com>
> +---
> + source/Makefile.in | 4 ++--
> + 1 file changed, 2 insertions(+), 2 deletions(-)
> 
>  diff -git icu.orig/source/Makefile.in icu/source/Makefile.in
>  --- icu.orig/source/Makefile.in	2025-03-13 19:31:23.000000000 +0100
>  +++ icu/source/Makefile.in	2025-09-22 08:56:36.791792784 +0200
> -@@ -279,7 +279,7 @@
> - 	@echo "Libs:" '-L$${libdir}' "${ICULIBS_UC}" "${ICULIBS_DT}" 
> '$${baselibs}' >> $@
> +@@ -276,10 +276,10 @@ config/icu-uc.pc: config/icu.pc Makefile 
> icudefs.mk
> +       @echo "Description: $(PACKAGE_ICU_DESCRIPTION): Common and Data 
> libraries" >> $@
> +       @echo "Name: $(PACKAGE)-uc" >> $@

There are eight space characters in the resulting patch, the icu 
Makefile uses one tab. The build fails with:

Applying 0003-fix-static-linking-with-icu-uc.patch using patch:
patching file source/Makefile.in
Hunk #1 FAILED at 276.
1 out of 1 hunk FAILED -- saving rejects to file source/Makefile.in.rej

> + ifeq ($(ENABLE_SHARED),)
> +-	@echo "Libs:" '-L$${libdir}' "${ICULIBS_UC}" "${ICULIBS_DT}" 
> '$${baselibs}' >> $@
> ++	@echo "Libs:" '-L$${libdir}' "${ICULIBS_UC}" "${ICULIBS_DT}" 
> '$${baselibs}' -lstdc++ >> $@
>   else
>   	@echo "Libs:" '-L$${libdir}' "${ICULIBS_UC}" >> $@
>  -	@echo "Libs.private:" "${ICULIBS_DT}" '$${baselibs}' >> $@
> --
> 2.53.0

Kind regards,
Andreas
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

  reply	other threads:[~2026-03-28  5:31 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-03 16:28 [Buildroot] [PATCH] package/icu: fix static linking with icu-uc for musl static toolchains Shubham Chakraborty
2026-03-03 18:21 ` [Buildroot] [PATCH v2] " Shubham Chakraborty
2026-03-26 11:36   ` [Buildroot] [PATCH v3] package/icu: fix static linking with icu-uc Shubham Chakraborty
2026-03-27  4:27     ` Andreas Ziegler
2026-03-27  9:50       ` Shubham Chakraborty
2026-03-27  9:43     ` [Buildroot] [PATCH v4] Extend the existing patch to also add -lstdc++ to the Libs field, fixing static linking issues with libicuuc.a Shubham Chakraborty
2026-03-28  5:30       ` Andreas Ziegler [this message]
2026-03-28  8:16         ` Shubham Chakraborty
2026-03-28  7:47       ` [Buildroot] [PATCH v5] icu: fix static linking by adding -lstdc++ to pkg-config Shubham Chakraborty
2026-03-29  6:33         ` Andreas Ziegler

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=cfbf28f28bc1485cfd2245db5120f739@umbiko.net \
    --to=br025@umbiko.net \
    --cc=buildroot@buildroot.org \
    --cc=chakrabortyshubham66@gmail.com \
    --cc=romain.naour@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