2014-03-12 12:08 AM
2014-03-12 08:49 AM
Hi
''error: expected '=', ',', ';', 'asm' or '__attribute__' before 'void'
'' The compiler is saying that it has come across something it does not understand and has lost track of the current 'line'/statement. It is something in the ''core_cmInstr.h
'' header file. I usually see this when there is a variable type (eg uint32_t) that the compiler does not know about. (uint32_t is not a built in type in C, it is sometimes defined in stdint.h but this depends on the environment!)2014-03-12 03:18 PM
To be honest i have no idea where are the actual variables that the compiler cannot find defined...
I have attached the file you mentioned. I tried defining __GNU__ (but the compiler said its a redefinition and then tried __thumb__, but that havent helped. May i ask you for some further help? ________________ Attachments : core_cmInstr.h : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006HzrG&d=%2Fa%2F0X0000000bQR%2FozxfjW4bf0VYFKiQC1WuMo3EX98zP8ETY48mvgEYPq4&asPdf=false2014-03-12 04:11 PM
You'd want to look at RiDE or Atollic projects, and review the defines, and paths they use.
2014-03-13 12:49 AM
''
error: expected '=', ',', ';', 'asm' or '__attribute__' before 'void'
'' I came across similiar problems when the toolchain is not properly defined/identified during the build process. Looking at those core_xxx.h files, they contain macros and intrinsics, enclosed in #ifdefs for several different toolchains like Keil MDK, IAR, and gcc (with differing syntax).2014-03-13 02:25 AM
I don't knwo how you can fix it in the build system you are using, but '-ansi' option on the command line is the root of your problem. Kick it away.
2014-04-27 11:11 PM
I have removed the ''-ansi'' option, now the error is different:
A:\Dropbox\programowanie\slickedit\stm32nuc>A: & cd A:\Dropbox\programowanie\slickedit\stm32nucA:\Dropbox\programowanie\slickedit\stm32nuc>echo VSLICKERRORPATH=''A:\Dropbox\programowanie\slickedit\stm32nuc''VSLICKERRORPATH=''A:\Dropbox\programowanie\slickedit\stm32nuc''A:\Dropbox\programowanie\slickedit\stm32nuc>''C:\Program Files\SlickEditV18.0.1 x64\win\vsbuild'' -signal 49643 -command make -f ''makefile'' rebuild CFG=Debug VSLICKERRORPATH=''A:\Dropbox\programowanie\slickedit\stm32nuc''make -f makefile rebuild CFG=Debug rm -f Debug/stm32nuc.exerm -f Debug/main.o Debug/startup_stm32f10x_md.o Debug/stm32f1xx_it.o Debug/system_stm32f10x.o arm-none-eabi-gcc -c ''-DSTM32F10X_LD'' -g -c -mthumb -mcpu=cortex-m3 -mfix-cortex-m3-ldrd -o ''Debug/main.o'' -IA:/Dropbox/programowanie/slickedit/stm32nuc/ -IA:/Dropbox/programowanie/slickedit/stm32nuc/inc -IA:/Dropbox/programowanie/slickedit/stm32nuc/Include -IA:/Dropbox/programowanie/slickedit/stm32nuc/src -IA:/Dropbox/programowanie/slickedit/stm32nuc/stm32f1xx main.carm-none-eabi-gcc -x assembler-with-cpp -c -mcpu=cortex-m3 -ggdb ''-DSTM32F10X_LD'' -o ''Debug/startup_stm32f10x_md.o'' -IA:/Dropbox/programowanie/slickedit/stm32nuc/ -IA:/Dropbox/programowanie/slickedit/stm32nuc/inc -IA:/Dropbox/programowanie/slickedit/stm32nuc/Include -IA:/Dropbox/programowanie/slickedit/stm32nuc/src -IA:/Dropbox/programowanie/slickedit/stm32nuc/stm32f1xx ''startup_stm32f10x_md.s''startup_stm32f10x_md.s:1:0: error: target CPU does not support ARM mode ;******************** (C) COPYRIGHT 2013 STMicroelectronics ******************** ^make.EXE: *** [Debug/startup_stm32f10x_md.o] Error 1
This is the first line of my startup while