错误一、config.status: error: cannot find input file: `xmetadataretriever/Makefile.in'
configure: creating ./config.status
config.status: creating Makefile
config.status: error: cannot find input file: `xmetadataretriever/Makefile.in'
Makefile:648: recipe for target '/mnt/hdd_6t/liuxueneng/releaseH3/h3_tina/out/h3-p1nor/compile_dir/target/libcedarx/.configured_yyy' failed
make[3]: *** [/mnt/hdd_6t/liuxueneng/releaseH3/h3_tina/out/h3-p1nor/compile_dir/target/libcedarx/.configured_yyy] Error 1
make[3]: Leaving directory '/mnt/hdd_6t/liuxueneng/releaseH3/h3_tina/package/allwinner/tina_multimedia'
package/Makefile:192: recipe for target 'package/allwinner/tina_multimedia/compile' failed
make[2]: *** [package/allwinner/tina_multimedia/compile] Error 2
make[2]: Leaving directory '/mnt/hdd_6t/liuxueneng/releaseH3/h3_tina'
原因:Autoconf配置生成Makefile.in需要Makefile.am,如果Makefile.am出现错误(格式,语法)则会出现该错误,
出问题的Makefile.am不一定是xmetadataretriever/Makefile.am
config.status: error: cannot find input file: `xmetadataretriever/Makefile.in'
此次出问题的Makefile.am是demoH264Player
include $(top_srcdir)/Makefile.inc bin_PROGRAMS = demoH264Player demoH264Player_SOURCES = ./demoH264Player.cpp \
./h264FileRead.c \ demoH264Player_CFLAGS = $(CFLAGS_CDXG)
demoH264Player_CPPFLAGS = $(CPPFLAGS_CDXG)
SOURCES 文件列表的时候最后一个文件的换行符连接符需要去掉,改成如下
demoH264Player_SOURCES = ./demoH264Player.cpp \
./h264FileRead.c
不过在Android.mk里面如果最后跟一个空行这样子是可以正常编译的。
问题二 error: expression cannot be used as a function
typedef定义的函数类型已经是一个指针类型,如果再增加指针方式定义函数,调用的时候会出现如上报错。
PlayerCallback *mMediaPlayStatusCB;
然后使用
mMediaPlayStatusCB(....);
则会出现如上错误,正确定义如下:
PlayerCallback mMediaPlayStatusCB;
错误三、will be initialized after [-Wreorder]
类构造函数的成员初始化列表必须按照成员申明的书序初始化
错误四、invalid use of non stactic member function
类成员函数设置成回调必须是静态函数。