0003-Fix-uClibc-build-on-64bit-platforms-by-including-std.patch 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. From 4a63f267efab2ef86adbeddda45909127135d7c8 Mon Sep 17 00:00:00 2001
  2. From: Bernd Kuhls <bernd.kuhls@t-online.de>
  3. Date: Sun, 28 Jan 2018 11:57:11 +0100
  4. Subject: [PATCH] Fix uClibc build on 64bit platforms by including stdint.h
  5. Fixes an error detected by buildroot autobuilders:
  6. http://autobuild.buildroot.net/results/573/573e2268e205e10d1352fa81122d8f225fdb4575/build-end.log
  7. /home/rclinux/rc-buildroot-test/scripts/instance-1/output/host/mips64el-buildroot-linux-uclibc/sysroot/usr/include/stdint.h:122:27:
  8. error: conflicting types for 'uintptr_t'
  9. typedef unsigned long int uintptr_t;
  10. ^
  11. In file included from ../lib/ldb/tests/ldb_msg.c:17:0:
  12. ../third_party/cmocka/cmocka.h:126:28: note: previous declaration of 'uintptr_t' was here
  13. typedef unsigned int uintptr_t;
  14. The define __WORDSIZE is missing when cmocka.h decides how to
  15. define uintptr_t, this patch includes stdint.h when needed.
  16. Patch sent upstream:
  17. https://lists.samba.org/archive/samba-technical/2018-January/125306.html
  18. Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
  19. ---
  20. lib/ldb/tests/ldb_mod_op_test.c | 1 +
  21. lib/ldb/tests/ldb_msg.c | 1 +
  22. libcli/smb/test_smb1cli_session.c | 1 +
  23. 3 files changed, 3 insertions(+)
  24. diff --git a/lib/ldb/tests/ldb_mod_op_test.c b/lib/ldb/tests/ldb_mod_op_test.c
  25. index cf2288c7bce..4690594186e 100644
  26. --- a/lib/ldb/tests/ldb_mod_op_test.c
  27. +++ b/lib/ldb/tests/ldb_mod_op_test.c
  28. @@ -13,6 +13,7 @@
  29. */
  30. #include <stdarg.h>
  31. #include <stddef.h>
  32. +#include <stdint.h>
  33. #include <setjmp.h>
  34. #include <cmocka.h>
  35. diff --git a/lib/ldb/tests/ldb_msg.c b/lib/ldb/tests/ldb_msg.c
  36. index f8de418e0dc..31786a9a318 100644
  37. --- a/lib/ldb/tests/ldb_msg.c
  38. +++ b/lib/ldb/tests/ldb_msg.c
  39. @@ -13,6 +13,7 @@
  40. */
  41. #include <stdarg.h>
  42. #include <stddef.h>
  43. +#include <stdint.h>
  44. #include <setjmp.h>
  45. #include <cmocka.h>
  46. diff --git a/libcli/smb/test_smb1cli_session.c b/libcli/smb/test_smb1cli_session.c
  47. index d1e21d5431e..6a526c96b61 100644
  48. --- a/libcli/smb/test_smb1cli_session.c
  49. +++ b/libcli/smb/test_smb1cli_session.c
  50. @@ -1,5 +1,6 @@
  51. #include <stdarg.h>
  52. #include <stddef.h>
  53. +#include <stdint.h>
  54. #include <setjmp.h>
  55. #include <cmocka.h>
  56. --
  57. 2.11.0