root@ubuntu:/home/vv3/qt5/appok/kok# /home/clark/QtEnv/QtEmbedded-5.9.1-arm/bin/qmake kok.pro
root@ubuntu:/home/vv3/qt5/appok/kok# ls
kok.pro main.o mainwindow.o moc_predefs.h
kok.pro.user mainwindow.cpp mainwindow.ui ui_mainwindow.h
main.cpp mainwindow.h Makefile
root@ubuntu:/home/vv3/qt5/appok/kok# make
make: *** No rule to make target `../../../../clark/QtEnv/QtEmbedded-5.9.1-arm/bin/moc', needed by `moc_mainwindow.cpp'. Stop.
root@ubuntu:/home/vv3/qt5/appok/kok#
离线
qmake要遍历一次源码, 发现 Q_OBJECT 关键字要生成 moc_xxxx.cpp 文件,
看起来貌似 moc_xxxx.cpp 没有生成,
你用x86的qmake, make 试一次,看有没有问题, 然后再一步一步判断出在哪里?
晕哥,我有buildroot-2017.08.1/output/build/qt5base-5.9.1/bin/qmake的qmake行成的Makefile可以编译通,但是我又用自己交叉编译的qt-5.9.1/bin/qmake行成的Makefile也编译不通过
root@ubuntu:/home/vv3/qt5/appok/kok# make
make: *** No rule to make target `../../../../clark/QtEnv/QtEmbedded-5.9.1-arm/bin/moc', needed by `moc_mainwindow.cpp'. Stop.
离线