×

Discussion Board

Results 1 to 10 of 10
  1. #1
    Nokia Developer Expert
    Join Date
    Mar 2011
    Posts
    4

    Troubles with user-selectable Qt autostart example in Qt Creator 2.2.1

    I've been trying to add user-selectable autostart functionality to my Qt app and have run into some problems. I'm using Qt Creator 2.2.1 on Windows 7 and Symbian^3 targets: C7, N8, and E7.

    I'm using the Knowledge Base article and code snippets at:
    http://www.developer.nokia.com/Commu...Qt_for_Symbian
    I know autostart with Qt is a recurring topic in these forums - I've reviewed past threads and hope I haven't missed anything! My current difficulty differs from what I've read:

    I have actually been able to build the AutoStartApp example code from the above link by following the instructions verbatim. I can then deploy the signed sis file (using Ovi Suite instead of Qt Creator as has been discussed in previous threads) and it will work. The trouble is that this only seems to work reliably if I first do a clean install of Qt Creator 2.2.1 and then immediately use that Qt Creator to open and build the downloaded AutoStartApp code. Of course that doesn't seem right...

    In any projects other than AutoStartApp, if I try to include the s60autostart directory and its associated "glue" (e.g., inclusion of s60launcher.UID3 and s60autostart.pri in the .pro as well as use of the S60AutoStart namespace in my code), then I get the compile error:

    ERROR: EPOCROOT must not include a drive letter
    BEGIN failed--compilation aborted at C:\QtSDK\Symbian\SDKs\Symbian3Qt473\epoc32\tools\/E32env.pm line 62.
    Compilation failed in require at C:\QtSDK\Symbian\SDKs\Symbian3Qt473\epoc32\tools/bldmake.pl line 36.
    BEGIN failed--compilation aborted at C:\QtSDK\Symbian\SDKs\Symbian3Qt473\epoc32\tools/bldmake.pl line 36.
    abld build ARMV5 UREL
    process_begin: CreateProcess((null), abld build ARMV5 UREL, ...) failed.
    make (e=2): The system cannot find the file specified.

    C:\QtSDK\Symbian\SDKs\Symbian3Qt473\epoc32\tools\make.exe[2]: *** [bld_launcher] Error 2
    C:\QtSDK\Symbian\SDKs\Symbian3Qt473\epoc32\tools\make.exe[2]: Leaving directory `C:/QtProjects/AnotherAutoStartApp/s60autostart/s60launcher'

    Moreover, after a certain (unknown) point following attempts at including s60autostart in other applications, I even get the above error when compiling the original (and previously working) AutoStartApp example.

    I expect that I'm missing something, but given the simplicity of the example and its accompanying instructions it seems like user-selectable autostart should just work - but it doesn't. I'll devote some more cycles to figuring this out on the weekend, but any insight or help from someone with more autostart experience would be greatly appreciated!


    A potentially relevant note:
    One of the very few differences between AutoStartApp and the Qt projects for Symbian that I've created and tried to autostart is that Qt Creator 2.2.1 auto-generates and includes deployment.pri (which does not exist in AutoStartApp) - but I'm not sure how the combination of deployment.pri and s60autostart would produce the above compile error...


    Thanks in advance for any help!
    Evan

  2. #2
    Regular Contributor
    Join Date
    Oct 2008
    Location
    Oslo, Norway
    Posts
    329

    Re: Troubles with user-selectable Qt autostart example in Qt Creator 2.2.1

    Hi,

    I've yet to test this extensively, but yeah, it will most likely have problems when trying to build to S^3. The reason is that s60launcher extension makefile has dependencies to the underlying symbian toolchain and currently supports only symbian-abld (S^1 aka S60 5th Ed), but not symbian-sbsv2 that QtSDK uses for S^3. I'll see if I can fix it.

  3. #3
    Nokia Developer Expert
    Join Date
    Mar 2011
    Posts
    4

    Re: Troubles with user-selectable Qt autostart example in Qt Creator 2.2.1

    Thank you treinio!
    Let me know if I can provide any additional info or test anything (I have plenty of S^3 phones...)
    Evan

  4. #4
    Regular Contributor
    Join Date
    Oct 2008
    Location
    Oslo, Norway
    Posts
    329

    Re: Troubles with user-selectable Qt autostart example in Qt Creator 2.2.1

    Ok,

    It's now updated. Was a bit tricky, had to resort to a number of hacks to work around problems both in the gnu make (which doesn't properly support conditionals) and the Symbian^3 SDK (which has a missing macro to make my code compile). Also, I found no simple way to propagate the used sbsv2 build configuration from the main application to the launcher, now there's a perl script that tries to pick the correct one.

    So, as you can see, it needs some testing Let me know if it works for you.

  5. #5
    Registered User
    Join Date
    Sep 2007
    Posts
    15

    Re: Troubles with user-selectable Qt autostart example in Qt Creator 2.2.1

    Hi treinio,

    Thanks! I am continuing Evan's efforts on user-selectable autostart functionality to Qt app.
    Your recent update onto s60launcher does not seem to work.
    The launcher application itself does not start at boot-up. I have verified it by putting log statements in s60launcher.cpp's StartL function (using this article)

    Based on this article tt seems that when adding the startup list resource (startuplist.rsc) in s60autostart.pri, it needs to be replaced with s60launcher.UID3 (launcher app's UID) instead of TARGET.UID3. I tried with this change too but coulldn't get it to work.

    Also, I have observed that after deploying signed sis pkg on to E7, there is no ini file under c:\system\data folder.

    So to sum it all, I am still unable to auto start my qt app on Symbian^3 device/platform.

    I think I am missing something here and would really appreciate if you can let me know what is that

    Thanks,
    - Asheesh

  6. #6
    Regular Contributor
    Join Date
    Oct 2008
    Location
    Oslo, Norway
    Posts
    329

    Re: Troubles with user-selectable Qt autostart example in Qt Creator 2.2.1

    Hi Asheesh,

    Thanks for the feedback and interest!

    Quote Originally Posted by asheesh_sri View Post
    Based on this article tt seems that when adding the startup list resource (startuplist.rsc) in s60autostart.pri, it needs to be replaced with s60launcher.UID3 (launcher app's UID) instead of TARGET.UID3. I tried with this change too but coulldn't get it to work.
    According to that doc,

    The name of the file must be changed when copied on the device. It will always be the Package UID (pUID) (as specified in the header of the PKG file) but without the 0x prefix and enclosed by square brackets ([ and ]).
    And the package UID is assumed to be the same as TARGET.UID3 as that's what qmake uses for the generated .pkg. So it should be correct, and worked for me so far.

    Quote Originally Posted by asheesh_sri View Post
    Also, I have observed that after deploying signed sis pkg on to E7, there is no ini file under c:\system\data folder.
    Correct, and there should not be one, because autostart has not yet been enabled for that application. It's defined in the .pkg only because it needs to be removed (if it exists) on uninstall.

    Can you autostart any application (without s60launcher), using instructions in the document mentioned above? This would help in resolving whether you're having a certificate issue or something related to S60AutoStart. Also check that the contents of the .pkg file look more or less sane.

  7. #7
    Registered User
    Join Date
    Sep 2007
    Posts
    15

    Re: Troubles with user-selectable Qt autostart example in Qt Creator 2.2.1

    Thanks treinio for your continuous support and replies to this post.

    Quote Originally Posted by treinio View Post

    Can you autostart any application (without s60launcher), using instructions in the document mentioned above? This would help in resolving whether you're having a certificate issue or something related to S60AutoStart. Also check that the contents of the .pkg file look more or less sane.
    I am able to auto-start app after realizing the following facts.

    1. If I let QtCreator install sis file on the phone, the application refuse to autostart.
    2. If I manually install the sis file (using Ovi Suite or copying the sis [created by qt creator] over phone and installing from there), application auto starts like charm.)

    Following steps I performed to auto-start my Qt application (based on this article)-

    1. Create a new file named E800005A.rss and add following into that

    #include <startupitem.rh>

    RESOURCE STARTUP_ITEM_INFO myapp
    {
    executable_name = "c:\\sys\\bin\\myapp.exe";
    recovery = EStartupItemExPolicyNone;
    }

    2. Add following block in the pro file
    # Define rss file for autoboot
    autoStartBlock = \
    "SOURCEPATH ." \
    "START RESOURCE E800005A.rss" \
    "END"

    MMP_RULES += autoStartBlock

    # Deploy rsc file to package.
    deployRscFile = "\"$${EPOCROOT}epoc32/data/0xE800005A.rsc\" - \
    \"!:\private\101f875a\import\\[0xE800005A].rsc\""
    deployFiles.pkg_postrules += deployRscFile
    DEPLOYMENT += deployFiles

    3. Rebuild.
    4. Sign sis and then deploy sis using Ovi Suite or manual installation.

    It seems that Startup list registration fails when the application is installed with QtCreator as mentioned by Thread A & B.

    Thanks,
    - Asheesh
    Last edited by asheesh_sri; 2011-09-12 at 22:10.

  8. #8
    Regular Contributor
    Join Date
    Oct 2008
    Location
    Oslo, Norway
    Posts
    329

    Re: Troubles with user-selectable Qt autostart example in Qt Creator 2.2.1

    Hi Asheesh,

    Good that the cause was finally found, I was not aware of this issue but indeed, this seems to be the case - I can reproduce it as well. This will be documented.

    A workaround seems to be to turn off the silent install option in QtCreator's project/run settings.

  9. #9
    Registered User
    Join Date
    Sep 2007
    Posts
    15

    Re: Troubles with user-selectable Qt autostart example in Qt Creator 2.2.1

    Thanks Treinio,

    Turning off the silent install sounds great
    Also, I will try s60launcher in next couple of days and will let you know how it goes.

    Once again thanks for your support.

    Asheesh

  10. #10
    Regular Contributor
    Join Date
    Apr 2008
    Posts
    445

    Re: Troubles with user-selectable Qt autostart example in Qt Creator 2.2.1

    Does autostart work now for you? I am trying to use the s60autostart project (http://www.developer.nokia.com/Commu...-Creator-2.2.1) but it does not work with Symbian Belle (it does work with Symbian^3 thus). I have the same problem with a pure Symbian C++ app where I use my own autostart code so I think there has something changed in Symbian Belle with the autostart functionality.
    The PIN input on device startup is deactivated.

Similar Threads

  1. Qt Creator code completion not working with Qt Mobility for Symbian
    By ceefour in forum [Archived] Qt Mobility Project
    Replies: 4
    Last Post: 2011-09-10, 05:02
  2. Replies: 1
    Last Post: 2011-01-05, 15:28
  3. Installing Qt Mobility 1.1 on Ubuntu 10.04 and using it with Qt Creator
    By tkatva in forum [Archived] Qt Mobility Project
    Replies: 3
    Last Post: 2010-12-15, 03:18
  4. Qt Mobility with Qt Creator - QTSDK-98 doesn't fix it for me
    By pzman in forum [Archived] Qt SDKs and Tools
    Replies: 2
    Last Post: 2010-09-10, 09:52
  5. Remote compiler not selectable in Qt Creator (Ubuntu 10.04)
    By josefr in forum [Archived] Qt SDKs and Tools
    Replies: 4
    Last Post: 2010-07-26, 19:42

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×