Skip to contentSkip to conversation

package/icu: Fix nios2 build

PATCH Superseded Bernd Kuhls 2 participants 6 messages Aug 3, 2019

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 package/icu: Fix nios2 build

Fixes:
http://autobuild.buildroot.net/results/91e/91eaec34708d91f8a05af189243be0b7cabce31b/

---
 .../icu/0006-ICU-20751-Fix-nios2-build.patch  | 36 +++++++++++++++++++
 1 file changed, 36 insertions(+)
 create mode 100644 package/icu/0006-ICU-20751-Fix-nios2-build.patch
package/icu/0006-ICU-20751-Fix-nios2-build.patch new file +36 -0
new file mode 100644
index 0000000000..3b67df5bdb
@@ -0,0 +1,36 @@
+From bfce346962841732f27f629c4f4661faa778f330 Mon Sep 17 00:00:00 2001
+From: Bernd Kuhls <[email protected]>
+Date: Sat, 3 Aug 2019 08:05:35 +0200
+Subject: [PATCH] ICU-20751 Fix nios2 build
+
+Solves build error
+
+In file included from double-conversion.h:42:0,
+                 from number_decimalquantity.cpp:19:
+double-conversion-utils.h:119:2: error: #error Target architecture was not detected as supported by Double-Conversion.
+ #error Target architecture was not detected as supported by Double-Conversion.
+
+detected by buildroot autobuilders:
+http://autobuild.buildroot.net/results/91e/91eaec34708d91f8a05af189243be0b7cabce31b/
+
+[Bernd: Fixed path]
+Signed-off-by: Bernd Kuhls <[email protected]>
+---
+ source/i18n/double-conversion-utils.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/source/i18n/double-conversion-utils.h b/source/i18n/double-conversion-utils.h
+index 1e44fcaa0e..0cf993929f 100644
+--- a/source/i18n/double-conversion-utils.h
++++ b/source/i18n/double-conversion-utils.h
+@@ -95,6 +95,7 @@ int main(int argc, char** argv) {
+     defined(__ARMEL__) || defined(__avr32__) || defined(_M_ARM) || defined(_M_ARM64) || \
+     defined(__hppa__) || defined(__ia64__) || \
+     defined(__mips__) || \
++    defined(__nios2__) || \
+     defined(__powerpc__) || defined(__ppc__) || defined(__ppc64__) || \
+     defined(_POWER) || defined(_ARCH_PPC) || defined(_ARCH_PPC64) || \
+     defined(__sparc__) || defined(__sparc) || defined(__s390__) || \
+-- 
+2.20.1
+
Signature · 1 line
2.20.1
#1 lore raw

PATCH 2/2 package/icu: Fix xtensa build

Fixes:
http://autobuild.buildroot.net/results/e6c/e6c6f826d8280f2bef923b3327d2a9a13ce2f7e1/

---
 .../icu/0007-ICU-20751-Fix-xtensa-build.patch | 35 +++++++++++++++++++
 1 file changed, 35 insertions(+)
 create mode 100644 package/icu/0007-ICU-20751-Fix-xtensa-build.patch
package/icu/0007-ICU-20751-Fix-xtensa-build.patch new file +35 -0
new file mode 100644
index 0000000000..494eeb1dc5
@@ -0,0 +1,35 @@
+From 8bb098a8d887939bf8eb41998c6ddfa847c12665 Mon Sep 17 00:00:00 2001
+From: Bernd Kuhls <[email protected]>
+Date: Sat, 3 Aug 2019 08:25:02 +0200
+Subject: [PATCH] ICU-20751 Fix xtensa build
+
+Solves build error
+In file included from double-conversion.h:42:0,
+                 from number_decimalquantity.cpp:19:
+double-conversion-utils.h:119:2: error: #error Target architecture was not detected as supported by Double-Conversion.
+ #error Target architecture was not detected as supported by Double-Conversion.
+
+detected by buildroot autobuilders:
+http://autobuild.buildroot.net/results/e6c/e6c6f826d8280f2bef923b3327d2a9a13ce2f7e1/
+
+[Bernd: Fixed path]
+Signed-off-by: Bernd Kuhls <[email protected]>
+---
+ source/i18n/double-conversion-utils.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/source/i18n/double-conversion-utils.h b/source/i18n/double-conversion-utils.h
+index 1e44fcaa0e..79816c7e05 100644
+--- a/source/i18n/double-conversion-utils.h
++++ b/source/i18n/double-conversion-utils.h
+@@ -103,6 +103,7 @@ int main(int argc, char** argv) {
+     defined(__AARCH64EL__) || defined(__aarch64__) || defined(__AARCH64EB__) || \
+     defined(__riscv) || \
+     defined(__or1k__) || defined(__arc__) || \
++    defined(__XTENSA__) || \
+     defined(__EMSCRIPTEN__)
+ #define DOUBLE_CONVERSION_CORRECT_DOUBLE_OPERATIONS 1
+ #elif defined(__mc68000__) || \
+-- 
+2.20.1
+
Signature · 1 line
2.20.1
#2 lore raw

PATCH 1/2 package/icu: Fix nios2 build

In reply to Bernd Kuhls

Hello,

Thanks for looking into these.

Quoted 15 lines · On Sat, 3 Aug 2019 08:31:34 +0200 Bernd Kuhls <[email protected]> wrote:

Fixes:
http://autobuild.buildroot.net/results/91e/91eaec34708d91f8a05af189243be0b7cabce31b/

---
 .../icu/0006-ICU-20751-Fix-nios2-build.patch  | 36 +++++++++++++++++++
 1 file changed, 36 insertions(+)
 create mode 100644 package/icu/0006-ICU-20751-Fix-nios2-build.patch
package/icu/0006-ICU-20751-Fix-nios2-build.patch new file +0 -0
new file mode 100644
index 0000000000..3b67df5bdb

package/icu/0006-ICU-20751-Fix-nios2-build.patch line 4

Quoted 4 lines
package/icu/0006-ICU-20751-Fix-nios2-build.patch new file +4 -0
@@ -0,0 +1,36 @@
+From bfce346962841732f27f629c4f4661faa778f330 Mon Sep 17 00:00:00 2001
+From: Bernd Kuhls <[email protected]>
+Date: Sat, 3 Aug 2019 08:05:35 +0200
+Subject: [PATCH] ICU-20751 Fix nios2 build

What is ICU-20751 ? It's not clear if the patch comes from upstream or not, since you are the author of patch.

Indeed, I see the nios2 and xtensa fixes are not the same, so I guess they have a different double conversion behavior, but how did you figure this out ?

If it's an upstream fix, could you share a link to it ?

Thanks!

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
#3 lore raw

PATCH 1/2 package/icu: Fix nios2 build

Hi Thomas,

Am Sat, 03 Aug 2019 08:46:52 +0200 schrieb Thomas Petazzoni:

Quoted 2 lines

What is ICU-20751 ? It's not clear if the patch comes from upstream or not, since you are the author of patch.

ICU-20751 is the name of my bug report:
https://unicode-org.atlassian.net/browse/ICU-20751

The project mandats that patch subjects start with the name of the ticket:
http://site.icu-project.org/repository/gitdev
"Always prefix your commit statements with the Jira ticket number using this pattern (including the space after the number; note: no colon):
ICU-23456 what I changed"

Quoted 3 lines

Indeed, I see the nios2 and xtensa fixes are not the same, so I guess they have a different double conversion behavior, but how did you figure this out ?

Yes, the fix is the same, I split it into two pull requests, but they patch the same part of the long ifdef statement and the project allows:
"You can have multiple pull requests per ticket."

Quoted 1 line

If it's an upstream fix, could you share a link to it ?

No, the patches are authored by me and sent upstream as pull requests. Ah, and here is the point: I forgot to add the pull request URL to the patches, sorry, sent v2.

Regards, Bernd

#4 lore raw

PATCH 1/2 package/icu: Fix nios2 build

Hello,

Quoted 16 lines · On Sat, 03 Aug 2019 09:12:35 +0200 Bernd Kuhls <[email protected]> wrote:

Hi Thomas,

Am Sat, 03 Aug 2019 08:46:52 +0200 schrieb Thomas Petazzoni:

Quoted 2 lines

What is ICU-20751 ? It's not clear if the patch comes from upstream or not, since you are the author of patch.

ICU-20751 is the name of my bug report:
https://unicode-org.atlassian.net/browse/ICU-20751

The project mandats that patch subjects start with the name of the ticket:
http://site.icu-project.org/repository/gitdev
"Always prefix your commit statements with the Jira ticket number using this pattern (including the space after the number; note: no colon):
ICU-23456 what I changed"

Quoted 7 lines
Quoted 3 lines

Indeed, I see the nios2 and xtensa fixes are not the same, so I guess they have a different double conversion behavior, but how did you figure this out ?

Yes, the fix is the same, I split it into two pull requests, but they patch the same part of the long ifdef statement and the project allows:
"You can have multiple pull requests per ticket."

Thanks for sending the v2, but you did not reply to my question about how you figure out what was the correct value for nios2 and xtensa, since neither of these architectures are supported by double-conversion upstream.

Thanks,

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
#5 lore raw

PATCH 1/2 package/icu: Fix nios2 build

Hi Thomas,

Am Sat, 03 Aug 2019 10:16:55 +0200 schrieb Thomas Petazzoni:

Quoted 4 lines

Thanks for sending the v2, but you did not reply to my question about how you figure out what was the correct value for nios2 and xtensa, since neither of these architectures are supported by double conversion upstream.

sent v3 for nios, tested double-conversion using qemu:
http://patchwork.ozlabs.org/patch/1141493/

Xtensa has no host-qemu support so I can not test it:
http://lists.busybox.net/pipermail/buildroot/2019-August/255940.html

Regards, Bernd