您好我是Blackberry 10开发的新手,在尝试编译我的第一个“Hello World”应用程序后,该应用程序默认使用该程序包,我在控制台中收到以下错误。我正在运行Windows 8 64位。 请注意,我没有对ndk附带的默认“Hello World”模板进行任何更改。
以下是我的main.cpp文件的内容:
// Default empty project template
#include <bb/cascades/Application>
#include <QLocale>
#include <QTranslator>
#include "applicationui.hpp"
// include JS Debugger / CS Profiler enabler
// this feature is enabled by default in the debug build only
#include <Qt/qdeclarativedebug.h>
using namespace bb::cascades;
Q_DECL_EXPORT int main(int argc, char **argv)
{
// this is where the server is started etc
Application app(argc, argv);
// localization support
QTranslator translator;
QString locale_string = QLocale().name();
QString filename = QString( "MyApp_%1" ).arg( locale_string );
if (translator.load(filename, "app/native/qm")) {
app.installTranslator( &translator );
}
new ApplicationUI(&app);
// we complete the transaction started in the app constructor and start the client event loop here
return Application::exec();
// when loop is exited the Application deletes the scene which deletes all its children (per qt rules for children)
}
这是控制台输出:
../precompiled.h:1:0: fatal error: can't open "C:\Users\Tich Kames\AppData\Local\Temp\2qccKaF3bb\precompiled.s" for writing: Invalid argument
make[2]: Leaving directory `C:/Users/Tich Kames/ndk-10.1.0-workspace/MyApp/arm'
compilation terminated.
cc: C:/bbndk/host_10_1_0_132/win32/x86/usr/lib/gcc/arm-unknown-nto-qnx8.0.0eabi/4.6.3/cc1plus caught signal 1
make[1]: Leaving directory `C:/Users/Tich Kames/ndk-10.1.0-workspace/MyApp/arm'
make[2]: *** [o.le-v7-g/.obj/MyApp.gch/c++] Error 1
make[1]: *** [debug] Error 2
make: *** [Device-Debug] Error 2
答案 0 :(得分:1)
正如tkames所承认的那样,问题来自工作区和临时路径中的空格。