You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by an...@apache.org on 2018/12/18 08:56:55 UTC

[mynewt-core] branch master updated: hw/drivers/lps33thw: Fix CLI build

This is an automated email from the ASF dual-hosted git repository.

andk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-core.git


The following commit(s) were added to refs/heads/master by this push:
     new 64f1d31  hw/drivers/lps33thw: Fix CLI build
64f1d31 is described below

commit 64f1d31b7d7e16bac0b2b80320b6ae2178402dee
Author: Andrzej Kaczmarek <an...@codecoup.pl>
AuthorDate: Mon Dec 17 21:37:35 2018 +0100

    hw/drivers/lps33thw: Fix CLI build
    
    Broken by another build fix (4a82c33c) so fixing again. Now it should
    build fine with and without bus driver...
---
 hw/drivers/sensors/lps33thw/src/lps33thw_shell.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/hw/drivers/sensors/lps33thw/src/lps33thw_shell.c b/hw/drivers/sensors/lps33thw/src/lps33thw_shell.c
index 03154ce..bbe30ff 100644
--- a/hw/drivers/sensors/lps33thw/src/lps33thw_shell.c
+++ b/hw/drivers/sensors/lps33thw/src/lps33thw_shell.c
@@ -123,6 +123,7 @@ lps33thw_shell_cmd(int argc, char **argv)
         return lps33thw_shell_help();
     }
 
+#if MYNEWT_VAL(BUS_DRIVER_PRESENT)
     if (!g_sensor_itf.si_dev) {
         g_sensor_itf.si_dev = os_dev_open(MYNEWT_VAL(LPS33THW_SHELL_NODE_NAME),
                                           0, NULL);
@@ -133,6 +134,7 @@ lps33thw_shell_cmd(int argc, char **argv)
             return 0;
         }
     }
+#endif
 
     /* Read pressure */
     if (argc > 1 && strcmp(argv[1], "rp") == 0) {