[oe-commits] [meta-openembedded] 35/38: ne10: Fix build errors on cortex-a7 cpus
git at git.openembedded.org
git at git.openembedded.org
Mon Apr 24 09:03:25 UTC 2017
This is an automated email from the git hooks/post-receive script.
martin_jansa pushed a commit to branch master
in repository meta-openembedded.
commit 0e27972d970fc7ef24fc8a79805e09b71dfeef00
Author: Khem Raj <raj.khem at gmail.com>
AuthorDate: Wed Apr 19 10:16:33 2017 -0700
ne10: Fix build errors on cortex-a7 cpus
GCC7 warns and errors about incompatible cmdline switches
for mcpu and march
Signed-off-by: Khem Raj <raj.khem at gmail.com>
---
.../ne10/0001-Dont-specify-march-explicitly.patch | 38 ++++++++++++++++++++++
meta-oe/recipes-support/ne10/ne10_1.2.1.bb | 3 +-
2 files changed, 40 insertions(+), 1 deletion(-)
diff --git a/meta-oe/recipes-support/ne10/ne10/0001-Dont-specify-march-explicitly.patch b/meta-oe/recipes-support/ne10/ne10/0001-Dont-specify-march-explicitly.patch
new file mode 100644
index 0000000..a8fea82
--- /dev/null
+++ b/meta-oe/recipes-support/ne10/ne10/0001-Dont-specify-march-explicitly.patch
@@ -0,0 +1,38 @@
+From 66d332e4b631eef800c6f62cd347b164ee3b59d4 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem at gmail.com>
+Date: Wed, 19 Apr 2017 10:11:21 -0700
+Subject: [PATCH] Dont specify -march explicitly
+
+it assumes armv7-a for all armv7 based machines but that may
+not be true e.g. machines based on armv7ve and cortexa-7
+it causes conflicts in OE builds because it specifies -march
+in recipes anyway so this is redundant in CMakeLists.txt
+
+Fixes
+
+| cc1: warning: switch -mcpu=cortex-a7 conflicts with -march=armv7-a switch
+| cc1: warning: switch -mcpu=cortex-a7 conflicts with -march=armv7-a switch
+
+Signed-off-by: Khem Raj <raj.khem at gmail.com>
+---
+ CMakeLists.txt | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 68da920..a4b94b9 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -138,8 +138,8 @@ if(ANDROID_PLATFORM)
+ ${CMAKE_C_FLAGS}")
+ elseif(GNULINUX_PLATFORM)
+ if("${NE10_TARGET_ARCH}" STREQUAL "armv7")
+- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mthumb -march=armv7-a -mfpu=vfp3 -funsafe-math-optimizations")
+- set(CMAKE_ASM_FLAGS "${CMAKE_C_FLAGS} -mthumb -march=armv7-a -mfpu=neon")
++ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mthumb -mfpu=vfp3 -funsafe-math-optimizations")
++ set(CMAKE_ASM_FLAGS "${CMAKE_C_FLAGS} -mthumb -mfpu=neon")
+ # Turn on asm optimization for Linux on ARM v7.
+ set(NE10_ASM_OPTIMIZATION on)
+ endif()
+--
+2.12.2
+
diff --git a/meta-oe/recipes-support/ne10/ne10_1.2.1.bb b/meta-oe/recipes-support/ne10/ne10_1.2.1.bb
index 951086f..e5b50ce 100644
--- a/meta-oe/recipes-support/ne10/ne10_1.2.1.bb
+++ b/meta-oe/recipes-support/ne10/ne10_1.2.1.bb
@@ -6,7 +6,8 @@ SECTION = "libs"
SRC_URI = "git://github.com/projectNe10/Ne10.git \
file://0001-CMakeLists.txt-Remove-mthumb-interwork.patch \
-"
+ file://0001-Dont-specify-march-explicitly.patch \
+ "
SRCREV = "18c4c982a595dad069cd8df4932aefb1d257591f"
S = "${WORKDIR}/git"
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Openembedded-commits
mailing list