Multiple definitions of tranceiver_pid using c++11

Hi all,

Im currently about to finish compatibility changes to provide compiling the default project for MSB-A2 using c++11. Now I running into a problem when linking, where transceiver_pid is defined multiple times in every file including the cc110x_ng.h

./projects/RIOT/sys/shell/commands/sc_cc110x_ng.c:33: multiple definition of `transceiver_pid' ./projects/RIOT/drivers/cc110x_ng/cc110x.c:55: multiple definition of `transceiver_pid' ./projects/RIOT/drivers/cc110x_ng/cc110x-rx.c:48: multiple definition of `transceiver_pid' ./projects/RIOT/drivers/cc110x_ng/cc110x-tx.c:32: multiple definition of `transceiver_pid' ./projects/RIOT/drivers/cc110x_ng/spi/cc110x_spi.c:50: multiple definition of `transceiver_pid' ./boards/msba2-common/drivers/msba2-cc110x.c:90: multiple definition of `transceiver_pid'

./projects/default/main.c:15: first defined here

This shouldn't happen as the #define CC1100_H protects (at least it should) the multiple inclusion of the header file.

I would like to ask if someone has an idea or hint where to look? Thanks.

Best regards, Martin

I solved the multiple definitions of trnsceiver_pid by setting the variable in cc110x_ng.h as extern. The problem was that multiple variables with the same name has been defined when included by cc110x_ng.h The compiler couldn't guarantee to distinguish between them, or treat them as 'the same' variable.

I don't now if I'm wrong cause I have no nodes providing multiple transceivers to test, but I think a similar problem could arise with such nodes.