Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs
This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

nRF5 SDK 15.1.0 nrf_cli.c fails to build when NRF_CLI_HISTORY 0

--- ./components/libraries/cli/nrf_cli.c	2018-08-23 07:41:32.000000000 +0200
+++ ./nRF5_SDK_15.1.0_a8c0c4d/components/libraries/cli/nrf_cli.c	2018-08-31 19:07:25.882380734 +0200
@@ -1943,7 +1943,9 @@
                 {
                     if (p_cli->p_ctx->cmd_buff_len == 0)
                     {
+#if NRF_MODULE_ENABLED(NRF_CLI_HISTORY)
                         history_mode_exit(p_cli);
+#endif
                         cursor_next_line_move(p_cli);
                     }
                     else
@@ -2072,7 +2074,9 @@
                         receive_state_change(p_cli, NRF_CLI_RECEIVE_TILDE_EXP);
                         /* fall through */
                     case 'H': /* HOME Button in VT100 mode */
+#if NRF_MODULE_ENABLED(NRF_CLI_METAKEYS)
                         cursor_home_position_move(p_cli);
+#endif
                         break;
                     case '2': /* INSERT Button in ESC[n~ mode */
                         receive_state_change(p_cli, NRF_CLI_RECEIVE_TILDE_EXP);

Including the patch I'm using.

Related