diff options
author | Wenzong Fan <wenzong.fan@windriver.com> | 2012-08-02 09:43:02 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-08-02 15:28:38 +0100 |
commit | 1b138d167cefdcbcc969e4f9d2639cdc647945d7 (patch) | |
tree | 5bcf879abfd3762372d3549d2d0280f087a054e5 /meta/recipes-qt/qt4/files | |
parent | 438df0f1d0c5d986ef67eaf57de9a0f5fef2d7e0 (diff) | |
download | poky-1b138d167cefdcbcc969e4f9d2639cdc647945d7.tar.gz |
qt4: fix qt4-native build failure on SLED-11
This issue is that with C++ compiler process an old version of kernel
header file, coincidently that file has a variable named 'new':
* 'embedded/qkbdtty_qws.cpp' include 'linux/vt.h';
* '/usr/include/linux/vt.h' has below code on SLED-11.x:
+ unsigned int new;
On mostly hosts it has been changed to: new -> newev.
[YOCTO #2845]
(From OE-Core rev: bb4b71552da0d1f4396955f35db5819f88a7d2ae)
Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-qt/qt4/files')
-rw-r--r-- | meta/recipes-qt/qt4/files/fix_qkbdtty_qws.patch | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/meta/recipes-qt/qt4/files/fix_qkbdtty_qws.patch b/meta/recipes-qt/qt4/files/fix_qkbdtty_qws.patch new file mode 100644 index 0000000000..c2aed5ca0f --- /dev/null +++ b/meta/recipes-qt/qt4/files/fix_qkbdtty_qws.patch | |||
@@ -0,0 +1,37 @@ | |||
1 | Upstream-Status: Pending | ||
2 | |||
3 | This issue is that with C++ compiler process an old version of kernel | ||
4 | header file, coincidently that file has a variable named 'new': | ||
5 | |||
6 | * 'embedded/qkbdtty_qws.cpp' include 'linux/vt.h'; | ||
7 | * '/usr/include/linux/vt.h' has below code on SLED-11.x: | ||
8 | + unsigned int new; | ||
9 | |||
10 | On mostly hosts it has been changed to: new -> newev. | ||
11 | |||
12 | Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com> | ||
13 | ======================================= | ||
14 | diff --git a/src/gui/embedded/qkbdtty_qws.cpp b/src/gui/embedded/qkbdtty_qws.cpp | ||
15 | --- a/src/gui/embedded/qkbdtty_qws.cpp 2012-07-27 13:16:58.420198350 +0800 | ||
16 | +++ b/src/gui/embedded/qkbdtty_qws.cpp 2012-07-27 13:24:43.924191127 +0800 | ||
17 | @@ -54,8 +54,20 @@ | ||
18 | |||
19 | #if defined Q_OS_LINUX | ||
20 | # include <linux/kd.h> | ||
21 | + | ||
22 | +/* Workaround kernel headers using "new" as variable name. The problem | ||
23 | + is specific to SLED-11, other distros use "newev" rather than "new" */ | ||
24 | +#ifdef __cplusplus | ||
25 | +#warning "workaround kernel headers using new as variable name on SLED 11" | ||
26 | +#define new newev | ||
27 | +#endif | ||
28 | + | ||
29 | # include <linux/vt.h> //TODO: move vt handling somewhere else (QLinuxFbScreen?) | ||
30 | |||
31 | +#ifdef __cplusplus | ||
32 | +#undef new | ||
33 | +#endif | ||
34 | + | ||
35 | # include "qscreen_qws.h" | ||
36 | # include "qwindowsystem_qws.h" | ||
37 | # include "qapplication.h" | ||