fc4be10553aa61b302797563a3ebf14c72219a21
[packages/trusty/cirros-testvm.git] / cirros-testvm / src-cirros / buildroot-2015.05 / package / qt5 / qt5connectivity / 0002-bluez_data_p.h-Add-missing-include-byteswap.h.patch
1 bluez_data_p.h: Add missing "#include <byteswap.h>"
2
3 This patch has been submitted upstream:
4
5   https://bugreports.qt.io/browse/QTBUG-44421
6
7 Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
8
9 From 1e219701c61cdedf0e8cfda542ee2485f5fd059a Mon Sep 17 00:00:00 2001
10 From: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
11 Date: Wed, 11 Feb 2015 18:11:05 +0000
12 Subject: [PATCH] bluez_data_p.h: Add missing "#include <byteswap.h>"
13
14 Building qtconnectivity fails for big endian platforms because the
15 bswap_16 function is not declared. This is the error message:
16
17 In file included from bluez/hcimanager_p.h:52:0,
18                  from bluez/hcimanager.cpp:35:
19 ./bluez/bluez_data_p.h: In function 'quint16 bt_get_le16(const void*)':
20 ./bluez/bluez_data_p.h:172:60: error: 'bswap_16' was not declared in
21 this scope
22      return bswap_16(bt_get_unaligned((const quint16 *) ptr));
23
24 bswap_16 is defined in byteswap.h so we can include this file in order
25 to fix this problem.
26
27 Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
28 ---
29  src/bluetooth/bluez/bluez_data_p.h |    1 +
30  1 files changed, 1 insertions(+), 0 deletions(-)
31
32 diff --git a/src/bluetooth/bluez/bluez_data_p.h b/src/bluetooth/bluez/bluez_data_p.h
33 index 9d2d96b..64c90dd 100644
34 --- a/src/bluetooth/bluez/bluez_data_p.h
35 +++ b/src/bluetooth/bluez/bluez_data_p.h
36 @@ -48,6 +48,7 @@
37  #include <QtCore/qglobal.h>
38  #include <sys/socket.h>
39  #include <QtBluetooth/QBluetoothUuid>
40 +#include <byteswap.h>
41  
42  #define BTPROTO_L2CAP   0
43  #define BTPROTO_HCI     1
44 -- 
45 1.7.1
46