Skip to contentSkip to conversation

package/icu: icu-uc: provide -lstdc++ flag for static build

PATCH New Romain Naour 2 participants 5 messages Jul 22, 2015 – Aug 6, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 package/icu: icu-uc: provide -lstdc++ flag for static build

icu-uc.pc must provide -lstdc++ for C application linked statically with libicuuc.a.

Related to:
http://autobuild.buildroot.net/results/210/2107f9dfb39eeb6559fb4271c7af8b39aef521ca/

---
 .../icu/0005-fix-static-linking-with-icu-uc.patch  | 34 ++++++++++++++++++++++
 1 file changed, 34 insertions(+)
 create mode 100644 package/icu/0005-fix-static-linking-with-icu-uc.patch
package/icu/0005-fix-static-linking-with-icu-uc.patch new file +34 -0
new file mode 100644
index 0000000..965906b
@@ -0,0 +1,34 @@
+From ffff12fd321c7a056e796e74cc508726b0626ae0 Mon Sep 17 00:00:00 2001
+From: Romain Naour <[email protected]>
+Date: Wed, 22 Jul 2015 22:43:25 +0200
+Subject: [PATCH] fix static linking with icu-uc
+
+During static linking with a C application and libicuuc.a,
+-lstdc++ is required.
+
+Add -lstdc++ in Libs.private of icu-uc.pc.
+
+Fixes:
+http://autobuild.buildroot.net/results/210/2107f9dfb39eeb6559fb4271c7af8b39aef521ca/
+
+Signed-off-by: Romain Naour <[email protected]>
+---
+ source/Makefile.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/source/Makefile.in b/source/Makefile.in
+index 9db6c52..ca48e16 100644
+--- a/source/Makefile.in
++++ b/source/Makefile.in
+@@ -264,7 +264,7 @@ config/icu-uc.pc: config/icu.pc Makefile icudefs.mk
+ 	@echo "Description: $(PACKAGE_ICU_DESCRIPTION): Common and Data libraries" >> $@
+ 	@echo "Name: $(PACKAGE)-uc" >> $@
+ 	@echo "Libs:" '-L$${libdir}' "${ICULIBS_UC}" "${ICULIBS_DT}" >> $@
+-	@echo "Libs.private:" '$${baselibs}' >> $@
++	@echo "Libs.private:" '$${baselibs}' -lstdc++ >> $@
+ 	@echo $@ updated.
+ 
+ config/icu-i18n.pc: config/icu.pc Makefile icudefs.mk
+-- 
+2.4.3
+
Signature · 1 line
2.4.3
#1 lore raw

PATCH 2/2 package/harfbuzz: fix test-unicode static linking issue

When linking test-unicode statically, it needs $(ICU_LIBS) which contains all required flags.
Especially -lstdc++.

Fixes:
http://autobuild.buildroot.net/results/210/2107f9dfb39eeb6559fb4271c7af8b39aef521ca/

---
 .../0001-fix-static-linking-with-icu-uc.patch      | 33 ++++++++++++++++++++++
 1 file changed, 33 insertions(+)
 create mode 100644 package/harfbuzz/0001-fix-static-linking-with-icu-uc.patch
package/harfbuzz/0001-fix-static-linking-with-icu-uc.patch new file +33 -0
new file mode 100644
index 0000000..dd64393
@@ -0,0 +1,33 @@
+From 5752d3f17072aa97a056dc081e402f43e1a3ba32 Mon Sep 17 00:00:00 2001
+From: Romain Naour <[email protected]>
+Date: Wed, 22 Jul 2015 23:26:23 +0200
+Subject: [PATCH] fix static linking with icu-uc
+
+When linking test-unicode statically it needs $(ICU_LIBS)
+which contains all required flags.
+Especially -lstdc++.
+
+Fixes:
+http://autobuild.buildroot.net/results/210/2107f9dfb39eeb6559fb4271c7af8b39aef521ca/
+
+Signed-off-by: Romain Naour <[email protected]>
+---
+ test/api/Makefile.am | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/test/api/Makefile.am b/test/api/Makefile.am
+index 4ff14fa..314a09f 100644
+--- a/test/api/Makefile.am
++++ b/test/api/Makefile.am
+@@ -34,7 +34,7 @@ test_unicode_CPPFLAGS += $(GLIB_CFLAGS)
+ endif
+ if HAVE_ICU
+ test_unicode_CPPFLAGS += $(ICU_CFLAGS)
+-test_unicode_LDADD += $(top_builddir)/src/libharfbuzz-icu.la
++test_unicode_LDADD += $(top_builddir)/src/libharfbuzz-icu.la $(ICU_LIBS)
+ endif
+ 
+ 
+-- 
+2.4.3
+
Signature · 1 line
2.4.3
#2 lore raw

PATCH 2/2 package/harfbuzz: fix test-unicode static linking issue

Dear Romain Naour,

Quoted 4 lines · Romain Naour

When linking test-unicode statically, it needs $(ICU_LIBS) which contains all required flags.
Especially -lstdc++.

Quoted 8 lines

Fixes:
http://autobuild.buildroot.net/results/210/2107f9dfb39eeb6559fb4271c7af8b39aef521ca/

---
 .../0001-fix-static-linking-with-icu-uc.patch      | 33 ++++++++++++++++++++++
 1 file changed, 33 insertions(+)
 create mode 100644 package/harfbuzz/0001-fix-static-linking-with-icu-uc.patch

Applied, thanks. Please also submit upstream.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#3 lore raw

PATCH 2/2 package/harfbuzz: fix test-unicode static linking issue

Hi Thomas,

Le 23/07/2015 23:36, Thomas Petazzoni a ?crit :

Quoted 10 lines

Dear Romain Naour,

Quoted 7 lines · Romain Naour

When linking test-unicode statically, it needs $(ICU_LIBS) which contains all required flags.
Especially -lstdc++.

Fixes:
http://autobuild.buildroot.net/results/210/2107f9dfb39eeb6559fb4271c7af8b39aef521ca/

Quoted 7 lines
Quoted 5 lines
---
 .../0001-fix-static-linking-with-icu-uc.patch      | 33 ++++++++++++++++++++++
 1 file changed, 33 insertions(+)
 create mode 100644 package/harfbuzz/0001-fix-static-linking-with-icu-uc.patch

Applied, thanks. Please also submit upstream.

Applied upstream:
https://github.com/behdad/harfbuzz/pull/122

Best regards,
Romain

Quoted 3 lines

Thomas

#4 lore raw

PATCH 1/2 package/icu: icu-uc: provide -lstdc++ flag for static build

In reply to Romain Naour

Dear Romain Naour,

Quoted 11 lines · Romain Naour

icu-uc.pc must provide -lstdc++ for C application linked statically with libicuuc.a.

Related to:
http://autobuild.buildroot.net/results/210/2107f9dfb39eeb6559fb4271c7af8b39aef521ca/

---
 .../icu/0005-fix-static-linking-with-icu-uc.patch  | 34 ++++++++++++++++++++++
 1 file changed, 34 insertions(+)
 create mode 100644 package/icu/0005-fix-static-linking-with-icu-uc.patch

Applied, thanks. Please submit the patch upstream!

Thanks,

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com