Stm32 redefinition of typedef 'thread_t'

ChibiOS public support forum for topics related to the STMicroelectronics STM32 family of micro-controllers.

Moderator: RoccoMarco

Post Reply
zamek
Posts: 14
Joined: Sat Mar 23, 2013 6:39 pm

Stm32 redefinition of typedef 'thread_t'

Post by zamek »

Hi All,

I upgraded to the new HEAD from git repository and I cannot compile my projects.
And I checked demos, in demos/STM32/RT-STM32F407-DISCOVERY:

make clean
make

Compiling chcore.c
In file included from ../../../os/rt/include/ch.h:76:0,
from ../../../os/rt/ports/ARMCMx/chcore.c:29:
../../../os/rt/include/chschd.h:76:23: error: redefinition of typedef 'thread_t'
../../../os/rt/include/ch.h:67:23: note: previous declaration of 'thread_t' was here
../../../os/common/ports/ARMCMx/compilers/GCC/rules.mk:203: recipe for target 'build/obj/chcore.o' failed
make: *** [build/obj/chcore.o] Error 1

And I checked all tests of STM32 the result is the same.

Thx
Zamek
User avatar
Giovanni
Site Admin
Posts: 14892
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: Stm32 redefinition of typedef 'thread_t'

Post by Giovanni »

Hi,

What compiler are you using? I tested using GCC, Keil and IAR and there are no warning about the re-declaration.

Giovanni
zamek
Posts: 14
Joined: Sat Mar 23, 2013 6:39 pm

Re: Stm32 redefinition of typedef 'thread_t'

Post by zamek »

Hi Giovanni,

Thx for your replay, I used Debian Linux, with arm-non-eabi-gcc 4.5.2 from CodeSourcery.
After I uninstall it and install gcc-arm-none-eabi package from Debian repository it works well.

thx for your help.

Zamek
User avatar
Giovanni
Site Admin
Posts: 14892
Joined: Wed May 27, 2009 8:48 am
Has thanked: 1202 times
Been thanked: 996 times

Re: Stm32 redefinition of typedef 'thread_t'

Post by Giovanni »

Hi,

Thanks, I think that the duplication should go anyway, I will update the code.

Giovanni
Post Reply