0002-bluez_data_p.h-Add-missing-include-byteswap.h.patch 1.5 KB

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