当前位置: 技术问答>linux和unix
请教:编译的时候出现错误parse error before `*',怎么解决,谢谢
来源: 互联网 发布时间:2015-06-09
本文导语: 我使用交叉编译器编译源程序,出现以下错误: make[1]: Entering directory `/mnt/win/f/mypro/myNF/proj-gcc/slim/package/gtk/app' m68k-elf-gcc -Wall -Wno-unknown-pragmas -O2 -DENABLE_NLS -DPACKAGE=NULL -I../ -I./../../../ -I/usr/X11R6/include -I/usr/lib/g...
我使用交叉编译器编译源程序,出现以下错误:
make[1]: Entering directory `/mnt/win/f/mypro/myNF/proj-gcc/slim/package/gtk/app'
m68k-elf-gcc -Wall -Wno-unknown-pragmas -O2 -DENABLE_NLS -DPACKAGE=NULL -I../ -I./../../../ -I/usr/X11R6/include -I/usr/lib/glib/include -I/usr/include -I/mnt/win/f/mypro/myNF/proj-gcc/slim/slim -I/mnt/win/f/mypro/myNF/proj-gcc/slim/package/gtk/app -c gx_browser_app.c -o gx_browser_app.o
gx_browser_app.c: In function `GXBrowserApp_New':
gx_browser_app.c:140: parse error before `*'
gx_browser_app.c:144: `self' undeclared (first use in this function)
gx_browser_app.c:144: (Each undeclared identifier is reported only once
gx_browser_app.c:144: for each function it appears in.)
gx_browser_app.c:164: `browser' undeclared (first use in this function)
gx_browser_app.c:266: warning: control reaches end of non-void function
make[1]: *** [gx_browser_app.o] Error 1
make[1]: Leaving directory `/mnt/win/f/mypro/myNF/proj-gcc/slim/package/gtk/app'
make: *** [libgtk] Error 2
使用GCC编译没有问题,使用交叉编译器就有问题,这是什么原因造成的?
make[1]: Entering directory `/mnt/win/f/mypro/myNF/proj-gcc/slim/package/gtk/app'
m68k-elf-gcc -Wall -Wno-unknown-pragmas -O2 -DENABLE_NLS -DPACKAGE=NULL -I../ -I./../../../ -I/usr/X11R6/include -I/usr/lib/glib/include -I/usr/include -I/mnt/win/f/mypro/myNF/proj-gcc/slim/slim -I/mnt/win/f/mypro/myNF/proj-gcc/slim/package/gtk/app -c gx_browser_app.c -o gx_browser_app.o
gx_browser_app.c: In function `GXBrowserApp_New':
gx_browser_app.c:140: parse error before `*'
gx_browser_app.c:144: `self' undeclared (first use in this function)
gx_browser_app.c:144: (Each undeclared identifier is reported only once
gx_browser_app.c:144: for each function it appears in.)
gx_browser_app.c:164: `browser' undeclared (first use in this function)
gx_browser_app.c:266: warning: control reaches end of non-void function
make[1]: *** [gx_browser_app.o] Error 1
make[1]: Leaving directory `/mnt/win/f/mypro/myNF/proj-gcc/slim/package/gtk/app'
make: *** [libgtk] Error 2
使用GCC编译没有问题,使用交叉编译器就有问题,这是什么原因造成的?
|
gx_browser_app.c:140: parse error before `*'
行的变量类型没有定义或者没有include相应的头文件
记得下次吧你的代码一起贴出来,否则很难给你回答的说
行的变量类型没有定义或者没有include相应的头文件
记得下次吧你的代码一起贴出来,否则很难给你回答的说