You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by vi...@apache.org on 2019/03/14 01:37:34 UTC
[mynewt-core] 01/01: sys/console: conditional specify log dependency
This is an automated email from the ASF dual-hosted git repository.
vipulrahane pushed a commit to branch console_ignore_fix
in repository https://gitbox.apache.org/repos/asf/mynewt-core.git
commit c52ca568137490f6cd63ed412aa9217e4a750f63
Author: Vipul Rahane <vr...@gmail.com>
AuthorDate: Wed Mar 13 18:36:53 2019 -0700
sys/console: conditional specify log dependency
---
sys/console/full/pkg.yml | 2 ++
sys/console/full/src/console.c | 2 ++
2 files changed, 4 insertions(+)
diff --git a/sys/console/full/pkg.yml b/sys/console/full/pkg.yml
index 361cbbe..b6258f4 100644
--- a/sys/console/full/pkg.yml
+++ b/sys/console/full/pkg.yml
@@ -30,6 +30,8 @@ pkg.deps.CONSOLE_UART:
- "@apache-mynewt-core/hw/drivers/uart"
pkg.deps.CONSOLE_RTT:
- "@apache-mynewt-core/hw/drivers/rtt"
+pkg.deps.LOG_CONSOLE:
+ - "@apache-mynewt-core/sys/log/full"
pkg.apis: console
pkg.init:
diff --git a/sys/console/full/src/console.c b/sys/console/full/src/console.c
index ae5a10d..e70b2ab 100644
--- a/sys/console/full/src/console.c
+++ b/sys/console/full/src/console.c
@@ -679,7 +679,9 @@ console_handle_char(uint8_t byte)
static struct os_event *ev;
static struct console_input *input;
static char prev_endl = '\0';
+#if MYNEWT_VAL(LOG_CONSOLE)
struct log *log;
+#endif
if (!lines_queue) {
return 0;