From 5fdfe5e1b9ae596221f5de1dd6a74427084fca7a Mon Sep 17 00:00:00 2001 From: 0xFEEDC0DE64 Date: Wed, 12 May 2021 16:42:40 +0200 Subject: [PATCH] Dont prepend filename if esp-idf already does it --- cores/esp32/esp32-hal-log.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/cores/esp32/esp32-hal-log.h b/cores/esp32/esp32-hal-log.h index 6cde35c8..2fc7a067 100644 --- a/cores/esp32/esp32-hal-log.h +++ b/cores/esp32/esp32-hal-log.h @@ -73,8 +73,11 @@ extern "C" #define ARDUHAL_LOG_RESET_COLOR #endif -#define ARDUHAL_SHORT_LOG_FORMAT(letter, format) ARDUHAL_LOG_COLOR_ ## letter format ARDUHAL_LOG_RESET_COLOR "\r\n" +#if CONFIG_LOG_LOCATION +#define ARDUHAL_LOG_FORMAT(letter, format) format +#else #define ARDUHAL_LOG_FORMAT(letter, format) "[%s:%u] %s(): " format, (__builtin_strrchr(__FILE__, '/') ? __builtin_strrchr(__FILE__, '/') + 1 : __FILE__), __LINE__, __FUNCTION__ +#endif #define ARDUHAL_LOG_TAG "ARDUINO"