qtwebengine: backport patches to fix ARM build failures

Signed-off-by: Jonathan Liu <net147@gmail.com>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
This commit is contained in:
Jonathan Liu
2014-10-16 15:44:05 +11:00
committed by Martin Jansa
parent 01f1ab8ee8
commit 264f20883c
7 changed files with 107 additions and 6 deletions

View File

@@ -1,7 +1,7 @@
From c2defbfe5946a6c483e3f9df37fb16bdffeffc31 Mon Sep 17 00:00:00 2001
From a6802bc4528205a9d3839a1f22d4fca32154f5f0 Mon Sep 17 00:00:00 2001
From: Simon Busch <morphis@gravedo.de>
Date: Fri, 20 Jun 2014 09:09:12 +0200
Subject: [PATCH 1/3] Use ninja supplied by environment variable NINJA_PATH
Subject: [PATCH 1/6] Use ninja supplied by environment variable NINJA_PATH
Signed-off-by: Simon Busch <morphis@gravedo.de>
---

View File

@@ -1,7 +1,7 @@
From 32f3b53d0b5861ac3e277552b04a579d8bd16558 Mon Sep 17 00:00:00 2001
From 7266e333c6568fec1e2ebbf0c2d68c4025397b2d Mon Sep 17 00:00:00 2001
From: Martin Jansa <Martin.Jansa@gmail.com>
Date: Mon, 30 Jun 2014 20:08:17 +0200
Subject: [PATCH 2/3] functions.prf: Don't match QMAKE_EXT_CPP or QMAKE_EXT_H
Subject: [PATCH 2/6] functions.prf: Don't match QMAKE_EXT_CPP or QMAKE_EXT_H
anywhere in patch, but at the end
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>

View File

@@ -1,7 +1,7 @@
From b0e844967728edf814d611bb1c69d320a8a6c64d Mon Sep 17 00:00:00 2001
From 8e540a678a796d78ff9a98986d747afbca7f63be Mon Sep 17 00:00:00 2001
From: Martin Jansa <Martin.Jansa@gmail.com>
Date: Tue, 1 Jul 2014 15:58:16 +0200
Subject: [PATCH 3/3] functions.prf: Try to add _moc suffix
Subject: [PATCH 3/6] functions.prf: Try to add _moc suffix
* otherwise moc generated files have the same basename and do_configure fails with:
core_generated.gyp:QtWebEngineCore#target has several files with the same basename:

View File

@@ -0,0 +1,34 @@
From c99aed6ef28c4ac9c00024a40222331c0e682d28 Mon Sep 17 00:00:00 2001
From: Andras Becsi <andras.becsi@digia.com>
Date: Thu, 18 Sep 2014 18:22:37 +0200
Subject: [PATCH 4/6] Set arm_tune to empty string if mtune flag is not set by
toolchain
Since the default arm_tune option applied by chromium is not
recognized by our gcc toolchain set arm_tune to empty string
to prevent chromium from setting a default. Our toolchains
set the arm version which already implies the corresponding
mtune option anyway.
Change-Id: I0291bd4f0e5706597d37f914e4eeefbd75397bbf
Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
---
src/core/gyp_run.pro | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/core/gyp_run.pro b/src/core/gyp_run.pro
index ed592e1..4845af2 100644
--- a/src/core/gyp_run.pro
+++ b/src/core/gyp_run.pro
@@ -47,7 +47,7 @@ cross_compile {
!isEmpty(MARCH): GYP_ARGS += "-D arm_arch=\"$$MARCH\""
MTUNE = $$extractCFlag("-mtune=.*")
- !isEmpty(MTUNE): GYP_ARGS += "-D arm_tune=\"$$MTUNE\""
+ GYP_ARGS += "-D arm_tune=\"$$MTUNE\""
MFLOAT = $$extractCFlag("-mfloat-abi=.*")
!isEmpty(MFLOAT): GYP_ARGS += "-D arm_float_abi=\"$$MFLOAT\""
--
2.1.1

View File

@@ -0,0 +1,30 @@
From 1331c66c937f1c3e10e193932db2037dc38434e9 Mon Sep 17 00:00:00 2001
From: Jonathan Liu <net147@gmail.com>
Date: Wed, 15 Oct 2014 17:02:16 +1100
Subject: [PATCH 5/6] Fix ARM NEON detection for -mfpu=neon-vfpv4
Upstream-Status: Backport
Change-Id: I972d3560d6aa2640a2702f219cf802d2476b1c6e
Reviewed-by: Andras Becsi <andras.becsi@digia.com>
Signed-off-by: Jonathan Liu <net147@gmail.com>
---
src/core/gyp_run.pro | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/core/gyp_run.pro b/src/core/gyp_run.pro
index 4845af2..66e97f4 100644
--- a/src/core/gyp_run.pro
+++ b/src/core/gyp_run.pro
@@ -64,7 +64,7 @@ cross_compile {
# If the toolchain does not explicitly specify to use NEON instructions
# we use arm_neon_optional for ARMv7 and newer and let chromium decide
# about the mfpu option.
- contains(MFPU, "neon"): GYP_ARGS += "-D arm_fpu=\"$$MFPU\" -D arm_neon=1"
+ contains(MFPU, "neon")|contains(MFPU, "neon-vfpv4"): GYP_ARGS += "-D arm_fpu=\"$$MFPU\" -D arm_neon=1"
else:!lessThan(MARMV, 7): GYP_ARGS += "-D arm_neon=0 -D arm_neon_optional=1"
else: GYP_ARGS += "-D arm_fpu=\"$$MFPU\" -D arm_neon=0 -D arm_neon_optional=0"
}
--
2.1.1

View File

@@ -0,0 +1,34 @@
From d242c15eb961fbdee69c0a0989cd100d174a25db Mon Sep 17 00:00:00 2001
From: Jonathan Liu <net147@gmail.com>
Date: Wed, 15 Oct 2014 17:01:06 +1100
Subject: [PATCH 6/6] Include QMAKE_CC when extracting C compiler flags
This fixes cross-compile settings detection for cross-compilation
environments where the C compiler cross-compilation flags are set in
CC/QMAKE_CC instead of CFLAGS/QMAKE_CFLAGS (e.g. OpenEmbedded).
Upstream-Status: Backport
Change-Id: I0a7b0f6c47a00775ec18073a16359c8351363285
Reviewed-by: Andras Becsi <andras.becsi@digia.com>
Signed-off-by: Jonathan Liu <net147@gmail.com>
---
tools/qmake/mkspecs/features/functions.prf | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/qmake/mkspecs/features/functions.prf b/tools/qmake/mkspecs/features/functions.prf
index 78b1190..37dd615 100644
--- a/tools/qmake/mkspecs/features/functions.prf
+++ b/tools/qmake/mkspecs/features/functions.prf
@@ -14,7 +14,7 @@ defineReplace(getConfigDir) {
}
defineReplace(extractCFlag) {
- CFLAGS = $$QMAKE_CFLAGS
+ CFLAGS = $$QMAKE_CC $$QMAKE_CFLAGS
!isEmpty(ANDROID_TARGET_CFLAGS): CFLAGS = $$ANDROID_TARGET_CFLAGS
OPTION = $$find(CFLAGS, $$1)
OPTION = $$split(OPTION, =)
--
2.1.1

View File

@@ -14,6 +14,9 @@ SRC_URI += " \
file://0001-Use-ninja-supplied-by-environment-variable-NINJA_PAT.patch \
file://0002-functions.prf-Don-t-match-QMAKE_EXT_CPP-or-QMAKE_EXT.patch \
file://0003-functions.prf-Try-to-add-_moc-suffix.patch \
file://0004-Set-arm_tune-to-empty-string-if-mtune-flag-is-not-se.patch \
file://0005-Fix-ARM-NEON-detection-for-mfpu-neon-vfpv4.patch \
file://0006-Include-QMAKE_CC-when-extracting-C-compiler-flags.patch \
file://0001-chromium-Drop-build-time-only-dependency-on-x11-libr.patch \
file://0002-chromium-Strip-unwanted-echo-compiling-prefix-from-C.patch \
file://0003-chromium-base.gypi-include-atomicops_internals_x86_gcc.cc-whe.patch \