Skip to contentSkip to conversation

Fix valgrind support for Cortex A5 systems

Buildroot New Mike Williams 2 participants 5 messages Sep 30, 2014

lore
Share & tools
lore
#0 lore raw

This adds configuration support in buildroot to allow valgrind on A5 systems, and also patches valgrind to correctly detect the host toolchain from buildroot as compatible.

#1 lore raw

PATCH 1/2 valgrind: allow building on Cortex A5

---
 package/valgrind/Config.in | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
package/valgrind/Config.in +3 -3
index fd5649b..49ff1b1 100644
@@ -1,8 +1,8 @@
 config BR2_PACKAGE_VALGRIND
 	bool "valgrind"
-	depends on BR2_i386 || BR2_x86_64 || BR2_cortex_a8 || \
-		   BR2_cortex_a9 || BR2_powerpc || BR2_mips || \
-		   BR2_mipsel || BR2_mips64 || BR2_mips64el
+	depends on BR2_i386 || BR2_x86_64 || BR2_cortex_a5 || \
+		   BR2_cortex_a8 || BR2_cortex_a9 || BR2_powerpc || \
+		   BR2_mips || BR2_mipsel || BR2_mips64 || BR2_mips64el
 	help
 	  Tool for debugging and profiling Linux programs.
 
Signature · 1 line
1.9.1
#2 lore raw

PATCH 1/2 valgrind: allow building on Cortex A5

Dear Mike Williams,

Quoted 11 lines · Mike Williams
---
 package/valgrind/Config.in | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
package/valgrind/Config.in +0 -0
index fd5649b..49ff1b1 100644
@@ -1,8 +1,8 @@
 config BR2_PACKAGE_VALGRIND

package/valgrind/Config.in line 8

Quoted 10 lines
package/valgrind/Config.in +3 -3
 	bool "valgrind"
-	depends on BR2_i386 || BR2_x86_64 || BR2_cortex_a8 || \
-		   BR2_cortex_a9 || BR2_powerpc || BR2_mips || \
-		   BR2_mipsel || BR2_mips64 || BR2_mips64el
+	depends on BR2_i386 || BR2_x86_64 || BR2_cortex_a5 || \
+		   BR2_cortex_a8 || BR2_cortex_a9 || BR2_powerpc || \
+		   BR2_mips || BR2_mipsel || BR2_mips64 || BR2_mips64el
 	help
 	  Tool for debugging and profiling Linux programs.
 

For good measure, could you also add Cortex A7, A12 and A15 to the list? If you do this, then you can resend the updated patch with my

Thanks!

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 valgrind: Add patch to fix ARM host detection

In reply to Mike Williams
---
 ...-0003-Add-patch-to-fix-ARM_host-detection.patch | 26 ++++++++++++++++++++++
 1 file changed, 26 insertions(+)
 create mode 100644 package/valgrind/valgrind-0003-Add-patch-to-fix-ARM_host-detection.patch
package/valgrind/valgrind-0003-Add-patch-to-fix-ARM_host-detection.patch new file +26 -0
new file mode 100644
index 0000000..b5338d7
@@ -0,0 +1,26 @@
+From 21152a9ec6cfcc2bdade8488bab21ed43a088f97 Mon Sep 17 00:00:00 2001
+From: Mike Williams <[email protected]>
+Date: Tue, 30 Sep 2014 15:51:24 -0400
+Subject: [PATCH] valgrind: Add patch to fix ARM host detection
+
+Signed-off-by: Mike Williams <[email protected]>
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index 2aeed78..b280ee2 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -212,7 +212,7 @@ case "${host_cpu}" in
+         ARCH_MAX="s390x"
+         ;;
+ 
+-     armv7*)
++     arm*)
+ 	AC_MSG_RESULT([ok (${host_cpu})])
+ 	ARCH_MAX="arm"
+ 	;;
+-- 
+1.9.1
+
Signature · 1 line
1.9.1
#4 lore raw

PATCH 2/2 valgrind: Add patch to fix ARM host detection

Dear Mike Williams,

Quoted 5 lines · Mike Williams
---
 ...-0003-Add-patch-to-fix-ARM_host-detection.patch | 26 ++++++++++++++++++++++
 1 file changed, 26 insertions(+)
 create mode 100644 package/valgrind/valgrind-0003-Add-patch-to-fix-ARM_host-detection.patch

This patch is not needed. You simply need to adjust the logic at
http://git.buildroot.net/buildroot/tree/package/valgrind/valgrind.mk#n15
to also cover Cortex-A5 and other Cortex-A variants.

Thanks,

Thomas

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