Main.qml file not found when imported the project on Mac



  • Greetings All,

    I am new in QML / QT Quick. I have made a project of QML/QT-C++ using QT-Creator (2.3.1 based on QT 4.7.4 32 bit)on Linux platform. My project is running smooth on Desktop simulator. Then I have imported the same project in QT-Creator on MAC platform and when I run the application and my output is blank screen when I ran it on Desktop simulator with following error

    file:///Users/<username>/QTProjects/<projectname>/sources/<projectname>-build-desktop-Desktop_Qt_4_7_4_for_GCC__Qt_SDK__Debug/<projectname>.app/Contents/MacOS/qml/<projectfolder>/main.qml: File not found

    Any ideas ?

    Thanks
    Farrukh Arshad.



  • I'm not sure what you mean by "Desktop Simulator".

    However you seem to build an application bundle. The qmlapplicationviewer.cpp generated by Qt Creator looks for qml files in the application bundle's resource folder.

    Check if the following lines are in your qmake project file:

    @

    Please do not modify the following two lines. Required for deployment.

    include(qmlapplicationviewer/qmlapplicationviewer.pri)
    qtcAddDeployment()
    @

    Those lines are responsible for correct deployment of qml files.

    [EDIT: code formatting, Volker]


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.