Zephyr: Support C++ builds

Some of the Zephyr include files need to be C++, not C based. The 'extern "C"'
wrapper in include/coap3/coap.h means that all #include are treated as being C.

Remove 'extern "C"' wrapper from include/coap3/coap.h and add wrapper to
include files after #include and before any function / structure definitions.

Add in a C++ build test for CI.
This commit is contained in:
Jon Shallow authored and Jon Shallow committed 2025-08-21 12:17:41 +01:00
1 parent 7dff177f29
commit ea01661faf
68 files changed
+582 -29

No files matched your search

+1 -1
View File
@@ -165,7 +165,7 @@ jobs:
- uses: actions/checkout@v4
- name: setup
run: |
sudo apt-get update && sudo apt-get install -y libc6-dev-i386
sudo apt-get update && sudo apt-get install -y libc6-dev-i386 lib32stdc++-13-dev
- name: compile
run: |
make -C examples/${{matrix.OS}} EXTRA_CFLAGS=-Werror