Hello,
I am using nordic sdk and working with C files.
But i would like to work on with C++ files as well.
How will i modify the makefile so that it can build both C and C++ can you show me an example ? Thanks
Hello,
I am using nordic sdk and working with C files.
But i would like to work on with C++ files as well.
How will i modify the makefile so that it can build both C and C++ can you show me an example ? Thanks
Hi,
Here is a makefile that is made for the ble_app_template example for PCA10028:
You also have to add #extern "C" {}
around everything that talks to the C-domain from cpp. Main.c have to be changed to main.cpp. Here is the ble_app_template project with the ledwrapper Torbjørn made:
Hi,
Here is a makefile that is made for the ble_app_template example for PCA10028:
You also have to add #extern "C" {}
around everything that talks to the C-domain from cpp. Main.c have to be changed to main.cpp. Here is the ble_app_template project with the ledwrapper Torbjørn made:
thanks it works fine now :)
@olba , what is the diffrence if i use arm-none-eabi-g++ instead ?
None that I know of.
I am trying to get this template to compile using sdk 12.3. Gives me this error arm-none-eabi-gcc.exe: error: /cygdrive/d/src/nRF5_SDK_12.3.0_d7731ad/nRF5_SDK_1 2.3.0_d7731ad/components/libraries/button/app_button.c: No such file or director y Can someone help me out in fixing this?
If you still have this issue, I'd recommend creating a new case, as this one is quite old.