RayCxggg opened a new issue, #3070:
URL: https://github.com/apache/mynewt-core/issues/3070

   Hi,
   
   I'm trying to build the BLE sample following the [Set up a bare bones NimBLE 
application](https://mynewt.apache.org/latest/tutorials/ble/ble_bare_bones.html).
 I'm working on Ubuntu 20.04 with WSL2.
   
   There is one step in the doc to add following configuration in syscfg.yml:
   ```
   syscfg.vals:
       BLE_HCI_TRANSPORT: builtin
   ```
   
   When I ran `newt build ble_tgt`, the following error appeared:
   ```
   Building target targets/ble_tgt
   Error: Override of defunct settings detected:
       BLE_HCI_TRANSPORT: see doc/transport.md
   
   Setting history (newest -> oldest):
       BLE_HCI_TRANSPORT: [apps/ble_app:builtin, 
@apache-mynewt-nimble/nimble/transport:]
   ```
   It seems that the `BLE_HCI_TRANSPORT` has been removed(the tutorial is 
outdated), but I can't find where `doc/transport.md` is.
   
   So I temporarily removed the config in syscfg.yml, but then I got another 
error while building:
   ```
   Error: repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c: In 
function 'value_to_pretty':
   repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:334:33: error: 
expected ')' before 'PRIu64'
     334 |             if (fprintf(out, "%" PRIu64, val) < 0)
         |                                 ^~~~~~~
         |                                 )
   repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:334:31: error: 
spurious trailing '%' in format [-Werror=format=]
     334 |             if (fprintf(out, "%" PRIu64, val) < 0)
         |                               ^
   repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:343:38: error: 
expected ')' before 'PRIu64'
     343 |                 if (fprintf(out, "-%" PRIu64, val) < 0)
         |                                      ^~~~~~~
         |                                      )
   repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:343:36: error: 
spurious trailing '%' in format [-Werror=format=]
     343 |                 if (fprintf(out, "-%" PRIu64, val) < 0)
         |                                    ^
   repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:390:29: error: 
expected ')' before 'PRIu64'
     390 |         if (fprintf(out, "%" PRIu64 "(", tag) < 0)
         |                             ^~~~~~~
         |                             )
   repos/apache-mynewt-core/encoding/tinycbor/src/cborpretty.c:390:27: error: 
spurious trailing '%' in format [-Werror=format=]
     390 |         if (fprintf(out, "%" PRIu64 "(", tag) < 0)
         |                           ^
   cc1: all warnings being treated as errors
   ```
   It seems to be a C standard problem which is related to the compiler. The 
arm-none-eabi-gcc version I'm using is 9.2.1, and I don't know which version is 
required. The 
[doc](https://mynewt.apache.org/latest/get_started/native_install/cross_tools.html#installing-the-arm-toolchain-for-linux)
 suggests a 4.9.3 version gcc. Should I downgrade to an old version?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@mynewt.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to