<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    Well I decided to try it myself and it seems that that desktop
    support is needed to be able to deploy/run your app on the
    SailfishOS emulator, otherwise your app just exits.<br>
    <br>
    I copy and pasted together this new main.cpp:<br>
    <code><br>
    #include <QApplication><br>
    #include <QGraphicsObject><br>
    #include <QDir><br>
    #include <QDeclarativeView><br>
    #include <QDeclarativeContext><br>
    #include <QDeclarativeEngine><br>
    #include <QDeclarativeComponent><br>
    <br>
    #ifdef HAS_BOOSTER<br>
    #include <MDeclarativeCache><br>
    #endif<br>
    <br>
    <br>
    <br>
    Q_DECL_EXPORT int main(int argc, char *argv[])<br>
    {<br>
        /*<br>
        QScopedPointer<QApplication>
    app(Sailfish::createApplication(argc, argv));<br>
        QScopedPointer<QDeclarativeView>
    view(Sailfish::createView("main.qml"));<br>
        <br>
        Sailfish::showView(view.data());<br>
        */<br>
        #ifdef HAS_BOOSTER<br>
            MDeclarativeCache::qApplication(argc, argv);<br>
        #else<br>
            new QApplication(argc, argv);<br>
        #endif<br>
    <br>
        QDeclarativeView *appview;<br>
        #ifdef HAS_BOOSTER<br>
            appview = MDeclarativeCache::qDeclarativeView();<br>
        #else<br>
            appview = new QDeclarativeView;<br>
        #endif<br>
        QString file = "main.qml";<br>
        QString path = QString(DEPLOYMENT_PATH);<br>
        appview->setSource(QUrl::fromLocalFile(path + file));<br>
       
    appview->setResizeMode(QDeclarativeView::SizeRootObjectToView);<br>
        appview->setAttribute(Qt::WA_OpaquePaintEvent);<br>
        appview->setAttribute(Qt::WA_NoSystemBackground);<br>
       
    appview->viewport()->setAttribute(Qt::WA_OpaquePaintEvent);<br>
       
    appview->viewport()->setAttribute(Qt::WA_NoSystemBackground);<br>
        appview->showFullScreen();<br>
    }<br>
    </code><br>
    It succesfully compiles and runs, but the Application Output area in
    the Qt Creator/Sailfish IDE gives me this:<br>
    <output><br>
    <meta name="qrichtext" content="1">
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><!--StartFragment--><span
        style=" font-family:'Monospace'; font-size:9pt; color:#141312;">Display
        on requested</span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">Qml
        debugging is enabled. Only use this in a safe environment!</span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">Using
        the meego graphics system</span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">libEGL
        warning: DRI2: failed to authenticate</span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">Warning:
        specifying an object instance for initialPage is sub-optimal -
        prefer to use a Component</span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; font-weight:600;
        color:#0606b0;">Remote application finished with exit code 0.</span><!--EndFragment--></p>
    <meta http-equiv="Content-Type" content="text/html;
      charset=ISO-8859-1">
    <style type="text/css">
p, li { white-space: pre-wrap; </style></output><br>
    <br>
    While when I run the example application (with
    sailfishapplication.cpp etc.) it gives me this:<br>
    <output><br>
    <meta name="qrichtext" content="1">
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><!--StartFragment--><span
        style=" font-family:'Monospace'; font-size:9pt; color:#141312;">Display
        on requested</span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">Qml
        debugging is enabled. Only use this in a safe environment!</span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">Using
        the meego graphics system</span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">libEGL
        warning: DRI2: failed to authenticate</span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">Warning:
        specifying an object instance for initialPage is sub-optimal -
        prefer to use a Component</span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">loaded
        the Generic plugin </span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">Loaded
        the MeeGo sensor plugin </span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">Requested
        sensor id ' "orientationsensor" ' interface not granted </span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">Requested
        sensor id ' "orientationsensor" ' interface not granted </span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">hijackWindow()
        context created for QDeclarativeView(0x6ffd9eb8) 1 </span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">QGLWindowSurface:
        Using plain widget as window surface
        QGLWindowSurface(0x702e8a48) </span></p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span
        style=" font-family:'Monospace'; font-size:9pt; color:#b00606;">Successfully
        resolved MeeGo graphics system:
        /usr/lib/qt4/plugins/graphicssystems/libqmeegographicssystem.so
      </span><!--EndFragment--></p>
    <meta http-equiv="Content-Type" content="text/html;
      charset=ISO-8859-1">
    <style type="text/css">
p, li { white-space: pre-wrap; }
</style></output><br>
    <br>
    And when I exit the application in the emulator:<br>
    <output><br>
    <span style=" font-family:'Monospace'; font-size:9pt;
      font-weight:600; color:#0606b0;">Remote application finished with
      exit code 0.</span><br>
    </output><br>
    <br>
    So basically the app isn't shown on the screen and just immediately
    exits after being started,<br>
    <br>
    Superpelican<br>
  </body>
</html>