* [Buildroot] [PATCH 1/3] dmalloc: Force arm mode instead of Thumb1 mode
@ 2015-01-20 11:24 Richard Genoud
2015-01-20 11:24 ` [Buildroot] [PATCH 2/3] alsa-lib: " Richard Genoud
` (2 more replies)
0 siblings, 3 replies; 11+ messages in thread
From: Richard Genoud @ 2015-01-20 11:24 UTC (permalink / raw)
To: buildroot
dmalloc has some assembly that doesn't exist in thumb1 mode.
So, force arm mode for dmalloc.
Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
---
package/dmalloc/dmalloc.mk | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/package/dmalloc/dmalloc.mk b/package/dmalloc/dmalloc.mk
index 581ec4075681..f87ae1709aec 100644
--- a/package/dmalloc/dmalloc.mk
+++ b/package/dmalloc/dmalloc.mk
@@ -14,6 +14,7 @@ DMALLOC_LICENSE_FILES = dmalloc.h.1
DMALLOC_INSTALL_STAGING = YES
DMALLOC_CONF_OPTS = --enable-shlib
+DMALLOC_CFLAGS = $(TARGET_CFLAGS)
ifeq ($(BR2_INSTALL_LIBSTDCPP),y)
DMALLOC_CONF_OPTS += --enable-cxx
@@ -27,6 +28,15 @@ else
DMALLOC_CONF_OPTS += --disable-threads
endif
+# dmalloc has some assembly function that are not present in thumb1 mode:
+# Error: lo register required -- `str lr,[sp,#4]'
+# so, we desactivate thumb mode
+ifeq ($(BR2_ARM_INSTRUCTIONS_THUMB),y)
+DMALLOC_CFLAGS += -marm
+endif
+
+DMALLOC_CONF_ENV = CFLAGS="$(DMALLOC_CFLAGS)"
+
define DMALLOC_POST_PATCH
$(SED) 's/^ac_cv_page_size=0$$/ac_cv_page_size=12/' $(@D)/configure
$(SED) 's/(ld -/($${LD-ld} -/' $(@D)/configure
--
2.0.0
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [Buildroot] [PATCH 2/3] alsa-lib: Force arm mode instead of Thumb1 mode
2015-01-20 11:24 [Buildroot] [PATCH 1/3] dmalloc: Force arm mode instead of Thumb1 mode Richard Genoud
@ 2015-01-20 11:24 ` Richard Genoud
2015-02-02 17:20 ` Arnout Vandecappelle
2015-01-20 11:24 ` [Buildroot] [PATCH 3/3] qt: " Richard Genoud
2015-01-25 19:31 ` [Buildroot] [PATCH 1/3] dmalloc: " Thomas Petazzoni
2 siblings, 1 reply; 11+ messages in thread
From: Richard Genoud @ 2015-01-20 11:24 UTC (permalink / raw)
To: buildroot
alsa-lib has some assembly that doesn't exist in thumb1 mode.
So, force arm mode for alsa-lib.
Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
---
package/alsa-lib/alsa-lib.mk | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/package/alsa-lib/alsa-lib.mk b/package/alsa-lib/alsa-lib.mk
index 16d184ea0e80..1740cc6728c6 100644
--- a/package/alsa-lib/alsa-lib.mk
+++ b/package/alsa-lib/alsa-lib.mk
@@ -54,6 +54,13 @@ ifeq ($(BR2_avr32),y)
ALSA_LIB_CFLAGS += -DAVR32_INLINE_BUG
endif
+# alsa-lib has some assembly function that are not present in thumb1 mode.
+# so, we desactivate thumb mode
+# (would be better to fix alsa-lib)
+ifeq ($(BR2_ARM_INSTRUCTIONS_THUMB),y)
+ALSA_LIB_CFLAGS += -marm
+endif
+
ifeq ($(BR2_PACKAGE_ALSA_LIB_PYTHON),y)
ALSA_LIB_CONF_OPTS += \
--with-pythonlibs=-lpython$(PYTHON_VERSION_MAJOR) \
--
2.0.0
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [Buildroot] [PATCH 3/3] qt: Force arm mode instead of Thumb1 mode
2015-01-20 11:24 [Buildroot] [PATCH 1/3] dmalloc: Force arm mode instead of Thumb1 mode Richard Genoud
2015-01-20 11:24 ` [Buildroot] [PATCH 2/3] alsa-lib: " Richard Genoud
@ 2015-01-20 11:24 ` Richard Genoud
2015-02-02 17:35 ` Arnout Vandecappelle
2015-02-02 20:42 ` Peter Korsgaard
2015-01-25 19:31 ` [Buildroot] [PATCH 1/3] dmalloc: " Thomas Petazzoni
2 siblings, 2 replies; 11+ messages in thread
From: Richard Genoud @ 2015-01-20 11:24 UTC (permalink / raw)
To: buildroot
Qt has some assembly that doesn't exist in thumb1 mode.
So, force arm mode for Qt
Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
---
package/qt/qt.mk | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/package/qt/qt.mk b/package/qt/qt.mk
index 255d6d2ab0e4..80605ca514d5 100644
--- a/package/qt/qt.mk
+++ b/package/qt/qt.mk
@@ -52,6 +52,14 @@ endif
endif
+# Qt has some assembly function that are not present in thumb1 mode:
+# Error: selected processor does not support Thumb mode `swp r3,r7,[r4]'
+# so, we desactivate thumb mode
+ifeq ($(BR2_ARM_INSTRUCTIONS_THUMB),y)
+QT_CFLAGS += -marm
+QT_CXXFLAGS += -marm
+endif
+
ifeq ($(BR2_PACKAGE_QT_QT3SUPPORT),y)
QT_CONFIGURE_OPTS += -qt3support
else
--
2.0.0
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [Buildroot] [PATCH 1/3] dmalloc: Force arm mode instead of Thumb1 mode
2015-01-20 11:24 [Buildroot] [PATCH 1/3] dmalloc: Force arm mode instead of Thumb1 mode Richard Genoud
2015-01-20 11:24 ` [Buildroot] [PATCH 2/3] alsa-lib: " Richard Genoud
2015-01-20 11:24 ` [Buildroot] [PATCH 3/3] qt: " Richard Genoud
@ 2015-01-25 19:31 ` Thomas Petazzoni
2015-01-26 11:07 ` Richard Genoud
2 siblings, 1 reply; 11+ messages in thread
From: Thomas Petazzoni @ 2015-01-25 19:31 UTC (permalink / raw)
To: buildroot
Dear Richard Genoud,
On Tue, 20 Jan 2015 12:24:37 +0100, Richard Genoud wrote:
> dmalloc has some assembly that doesn't exist in thumb1 mode.
> So, force arm mode for dmalloc.
>
> Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
> ---
> package/dmalloc/dmalloc.mk | 10 ++++++++++
> 1 file changed, 10 insertions(+)
Applied, thanks.
Are you actually using an ARMv4/ARMv5 Thumb system?
Maybe this is a configuration we should add to our autobuilders, since
it's currently not even build-tested.
Thanks,
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Buildroot] [PATCH 1/3] dmalloc: Force arm mode instead of Thumb1 mode
2015-01-25 19:31 ` [Buildroot] [PATCH 1/3] dmalloc: " Thomas Petazzoni
@ 2015-01-26 11:07 ` Richard Genoud
2015-01-26 11:20 ` Thomas Petazzoni
0 siblings, 1 reply; 11+ messages in thread
From: Richard Genoud @ 2015-01-26 11:07 UTC (permalink / raw)
To: buildroot
2015-01-25 20:31 GMT+01:00 Thomas Petazzoni
<thomas.petazzoni@free-electrons.com>:
> Dear Richard Genoud,
>
> On Tue, 20 Jan 2015 12:24:37 +0100, Richard Genoud wrote:
>> dmalloc has some assembly that doesn't exist in thumb1 mode.
>> So, force arm mode for dmalloc.
>>
>> Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
>> ---
>> package/dmalloc/dmalloc.mk | 10 ++++++++++
>> 1 file changed, 10 insertions(+)
>
> Applied, thanks.
>
> Are you actually using an ARMv4/ARMv5 Thumb system?
I tried to use it to know if it saves some place on my RFS, but as Qt
has the same kind of problem with Thumb1, it didn't make a big
difference.
(my platform is a sam9g35, so ARMv5)
But if I continue to have spaces problem, I will reconsider using
thumb1, and maybe try to patch the Qt assembly to make it Thumb1
compliant instead of adding " -marm"
> Maybe this is a configuration we should add to our autobuilders, since
> it's currently not even build-tested.
That may be a good idea since I may not be the only potential user :)
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Buildroot] [PATCH 1/3] dmalloc: Force arm mode instead of Thumb1 mode
2015-01-26 11:07 ` Richard Genoud
@ 2015-01-26 11:20 ` Thomas Petazzoni
0 siblings, 0 replies; 11+ messages in thread
From: Thomas Petazzoni @ 2015-01-26 11:20 UTC (permalink / raw)
To: buildroot
Dear Richard Genoud,
On Mon, 26 Jan 2015 12:07:42 +0100, Richard Genoud wrote:
> > Are you actually using an ARMv4/ARMv5 Thumb system?
> I tried to use it to know if it saves some place on my RFS, but as Qt
> has the same kind of problem with Thumb1, it didn't make a big
> difference.
> (my platform is a sam9g35, so ARMv5)
> But if I continue to have spaces problem, I will reconsider using
> thumb1, and maybe try to patch the Qt assembly to make it Thumb1
> compliant instead of adding " -marm"
Ok.
> > Maybe this is a configuration we should add to our autobuilders, since
> > it's currently not even build-tested.
> That may be a good idea since I may not be the only potential user :)
Indeed. We also have more autobuilder instances nowadays, so adding a
few more configurations should be fine.
Thanks,
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Buildroot] [PATCH 2/3] alsa-lib: Force arm mode instead of Thumb1 mode
2015-01-20 11:24 ` [Buildroot] [PATCH 2/3] alsa-lib: " Richard Genoud
@ 2015-02-02 17:20 ` Arnout Vandecappelle
2015-02-02 17:29 ` Peter Korsgaard
2015-02-02 17:32 ` Arnout Vandecappelle
0 siblings, 2 replies; 11+ messages in thread
From: Arnout Vandecappelle @ 2015-02-02 17:20 UTC (permalink / raw)
To: buildroot
On 20/01/15 12:24, Richard Genoud wrote:
> alsa-lib has some assembly that doesn't exist in thumb1 mode.
> So, force arm mode for alsa-lib.
>
> Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
However, I can't find the assembly that you refer to. And of course
this problem only becomes apparent at runtime.
Regards,
Arnout
> ---
> package/alsa-lib/alsa-lib.mk | 7 +++++++
> 1 file changed, 7 insertions(+)
>
> diff --git a/package/alsa-lib/alsa-lib.mk b/package/alsa-lib/alsa-lib.mk
> index 16d184ea0e80..1740cc6728c6 100644
> --- a/package/alsa-lib/alsa-lib.mk
> +++ b/package/alsa-lib/alsa-lib.mk
> @@ -54,6 +54,13 @@ ifeq ($(BR2_avr32),y)
> ALSA_LIB_CFLAGS += -DAVR32_INLINE_BUG
> endif
>
> +# alsa-lib has some assembly function that are not present in thumb1 mode.
> +# so, we desactivate thumb mode
> +# (would be better to fix alsa-lib)
> +ifeq ($(BR2_ARM_INSTRUCTIONS_THUMB),y)
> +ALSA_LIB_CFLAGS += -marm
> +endif
> +
> ifeq ($(BR2_PACKAGE_ALSA_LIB_PYTHON),y)
> ALSA_LIB_CONF_OPTS += \
> --with-pythonlibs=-lpython$(PYTHON_VERSION_MAJOR) \
--
Arnout Vandecappelle arnout at mind be
Senior Embedded Software Architect +32-16-286500
Essensium/Mind http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint: 7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Buildroot] [PATCH 2/3] alsa-lib: Force arm mode instead of Thumb1 mode
2015-02-02 17:20 ` Arnout Vandecappelle
@ 2015-02-02 17:29 ` Peter Korsgaard
2015-02-02 17:32 ` Arnout Vandecappelle
1 sibling, 0 replies; 11+ messages in thread
From: Peter Korsgaard @ 2015-02-02 17:29 UTC (permalink / raw)
To: buildroot
>>>>> "Arnout" == Arnout Vandecappelle <arnout@mind.be> writes:
> On 20/01/15 12:24, Richard Genoud wrote:
>> alsa-lib has some assembly that doesn't exist in thumb1 mode.
>> So, force arm mode for alsa-lib.
>>
>> Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
> Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
> However, I can't find the assembly that you refer to. And of course
> this problem only becomes apparent at runtime.
Me neither. It builds fine here in thumb1 mode. Richard, what problem
did you see exactly?
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Buildroot] [PATCH 2/3] alsa-lib: Force arm mode instead of Thumb1 mode
2015-02-02 17:20 ` Arnout Vandecappelle
2015-02-02 17:29 ` Peter Korsgaard
@ 2015-02-02 17:32 ` Arnout Vandecappelle
1 sibling, 0 replies; 11+ messages in thread
From: Arnout Vandecappelle @ 2015-02-02 17:32 UTC (permalink / raw)
To: buildroot
On 02/02/15 18:20, Arnout Vandecappelle wrote:
> On 20/01/15 12:24, Richard Genoud wrote:
>> alsa-lib has some assembly that doesn't exist in thumb1 mode.
>> So, force arm mode for alsa-lib.
>>
>> Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
> Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
>
> However, I can't find the assembly that you refer to. And of course
> this problem only becomes apparent at runtime.
Actually, it should lead to a build failure. So I really don't see
why this patch would be needed.
Regards,
Arnout
--
Arnout Vandecappelle arnout at mind be
Senior Embedded Software Architect +32-16-286500
Essensium/Mind http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint: 7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Buildroot] [PATCH 3/3] qt: Force arm mode instead of Thumb1 mode
2015-01-20 11:24 ` [Buildroot] [PATCH 3/3] qt: " Richard Genoud
@ 2015-02-02 17:35 ` Arnout Vandecappelle
2015-02-02 20:42 ` Peter Korsgaard
1 sibling, 0 replies; 11+ messages in thread
From: Arnout Vandecappelle @ 2015-02-02 17:35 UTC (permalink / raw)
To: buildroot
On 20/01/15 12:24, Richard Genoud wrote:
> Qt has some assembly that doesn't exist in thumb1 mode.
> So, force arm mode for Qt
>
> Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
Tested-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Acked-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
It fails when the patch is not applied even on the most minimal
config. It succeeds with the patch applied.
Regards,
Arnout
> ---
> package/qt/qt.mk | 8 ++++++++
> 1 file changed, 8 insertions(+)
>
> diff --git a/package/qt/qt.mk b/package/qt/qt.mk
> index 255d6d2ab0e4..80605ca514d5 100644
> --- a/package/qt/qt.mk
> +++ b/package/qt/qt.mk
> @@ -52,6 +52,14 @@ endif
>
> endif
>
> +# Qt has some assembly function that are not present in thumb1 mode:
> +# Error: selected processor does not support Thumb mode `swp r3,r7,[r4]'
> +# so, we desactivate thumb mode
> +ifeq ($(BR2_ARM_INSTRUCTIONS_THUMB),y)
> +QT_CFLAGS += -marm
> +QT_CXXFLAGS += -marm
> +endif
> +
> ifeq ($(BR2_PACKAGE_QT_QT3SUPPORT),y)
> QT_CONFIGURE_OPTS += -qt3support
> else
--
Arnout Vandecappelle arnout at mind be
Senior Embedded Software Architect +32-16-286500
Essensium/Mind http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint: 7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
^ permalink raw reply [flat|nested] 11+ messages in thread
* [Buildroot] [PATCH 3/3] qt: Force arm mode instead of Thumb1 mode
2015-01-20 11:24 ` [Buildroot] [PATCH 3/3] qt: " Richard Genoud
2015-02-02 17:35 ` Arnout Vandecappelle
@ 2015-02-02 20:42 ` Peter Korsgaard
1 sibling, 0 replies; 11+ messages in thread
From: Peter Korsgaard @ 2015-02-02 20:42 UTC (permalink / raw)
To: buildroot
>>>>> "Richard" == Richard Genoud <richard.genoud@gmail.com> writes:
> Qt has some assembly that doesn't exist in thumb1 mode.
> So, force arm mode for Qt
> Signed-off-by: Richard Genoud <richard.genoud@gmail.com>
Committed, thanks.
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2015-02-02 20:42 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-20 11:24 [Buildroot] [PATCH 1/3] dmalloc: Force arm mode instead of Thumb1 mode Richard Genoud
2015-01-20 11:24 ` [Buildroot] [PATCH 2/3] alsa-lib: " Richard Genoud
2015-02-02 17:20 ` Arnout Vandecappelle
2015-02-02 17:29 ` Peter Korsgaard
2015-02-02 17:32 ` Arnout Vandecappelle
2015-01-20 11:24 ` [Buildroot] [PATCH 3/3] qt: " Richard Genoud
2015-02-02 17:35 ` Arnout Vandecappelle
2015-02-02 20:42 ` Peter Korsgaard
2015-01-25 19:31 ` [Buildroot] [PATCH 1/3] dmalloc: " Thomas Petazzoni
2015-01-26 11:07 ` Richard Genoud
2015-01-26 11:20 ` Thomas Petazzoni
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.