0002-mbox-do-not-use-backtrace-if-using-uClibc-without-ba.patch 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. From 053bac34b9f0f947c58fcdf80ac03d5a6b05aa12 Mon Sep 17 00:00:00 2001
  2. From: "Yann E. MORIN" <yann.morin.1998@free.fr>
  3. Date: Mon, 7 May 2018 23:15:58 +0200
  4. Subject: [PATCH] mbox: do not use backtrace if using uClibc without backtrace
  5. support
  6. Since uClibc can be configured without support for backtrace, disable
  7. the backtrace if we are building with a uClibc that was built without
  8. backtrace.
  9. This is a bit hacky, and would greatly benefit from a test in ./configure
  10. instead, but does nicely as a quick fix for now.
  11. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
  12. Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
  13. [Bernd: rebased for 0.103.0]
  14. ---
  15. libclamav/mbox.c | 2 +-
  16. 1 file changed, 1 insertion(+), 1 deletion(-)
  17. diff --git a/libclamav/mbox.c b/libclamav/mbox.c
  18. index 71f540c0a..4851297a9 100644
  19. --- a/libclamav/mbox.c
  20. +++ b/libclamav/mbox.c
  21. @@ -91,7 +91,7 @@
  22. #include <features.h>
  23. #endif
  24. -#if __GLIBC__ == 2 && __GLIBC_MINOR__ >= 1
  25. +#if __GLIBC__ == 2 && __GLIBC_MINOR__ >= 1 && !defined(__UCLIBC__) || defined(__UCLIBC_HAS_BACKTRACE__)
  26. #define HAVE_BACKTRACE
  27. #endif
  28. #endif
  29. --
  30. 2.14.3