×

Discussion Board

Page 1 of 3 123 LastLast
Results 1 to 15 of 35
  1. #1
    Registered User
    Join Date
    Mar 2003
    Posts
    22

    Question Accessing ShareUI on Harmattan/MeeGo ?

    I am looking to add social sharing into our applications but cannot figure out how to access the sharing API from Qt/QML.

    The sharing UI feature is documented here:
    http://www.developer.nokia.com/swipe...s/Sharing.html
    The key differentiator is that any app or service could handle the share request.

    The MeeGo open source project hosts the sharing libraries here:
    http://meego.gitorious.org/meego-sharing-framework

    I have tried to adapt some of the examples in the git repository, but they all rely on importing ShareUI ie

    #include <ShareUI/Item>

    which I cannot resolve.

    I can see that the SharingUI libs are built into the SDK on this path:
    <Qt SDK Root>/Madde/sysroots/harmattan-arm-sysroot/usr/include/ShareUI
    but I do not see the ShareUI dir in the same location on the N950.

    Any advice on this would be most appreciated.

    Thanks,

    Maciej

  2. #2
    Super Contributor
    Join Date
    Oct 2009
    Posts
    4,326

    Re: Accessing ShareUI on Harmattan/MeeGo ?

    Quote Originally Posted by mac1ej View Post
    I have tried to adapt some of the examples in the git repository, but they all rely on importing ShareUI ie

    #include <ShareUI/Item>

    which I cannot resolve.
    Why? Are you using pkg-config?

    Quote Originally Posted by mac1ej View Post
    I can see that the SharingUI libs are built into the SDK on this path:
    <Qt SDK Root>/Madde/sysroots/harmattan-arm-sysroot/usr/include/ShareUI
    but I do not see the ShareUI dir in the same location on the N950.
    These are development files (needed for compilation) are not need on the device for execution.

  3. #3
    Registered User
    Join Date
    Mar 2003
    Posts
    22

    Re: Accessing ShareUI on Harmattan/MeeGo ?

    Is your question why I cannot resolve #include <ShareUI/Item>? I assume that I cannot because my project is not correctly configured, that I need something like:

    CONFIG += share-ui

    in my .pro file (the above does not help by the way) or the correct equivalent.

    I am not using pkg-config, should I be? Its wiki page seems like it might be helpful:

    http://en.wikipedia.org/wiki/Pkg-config

    As far as the libraries on the device, I am questioning whether the ShareUI libs are available on the hardware. I noticed that

    <Qt SDK Root>/Madde/sysroots/harmattan-nokia-arm-sysroot

    seems like a closer approximation of the file system on the N950 and I spotted the following libs

    /usr/lib/libmaemomeegotouchshareuiinterface.<shared objects and version numbers>



    Any advice on getting Harmattan/MeeGo's sharing feature linked up working?

    Best,

    Maciej

  4. #4
    Super Contributor
    Join Date
    Oct 2009
    Posts
    4,326

    Re: Accessing ShareUI on Harmattan/MeeGo ?

    http://www.developer.nokia.com/Commu...fig_with_qmake
    Name of the library is libshare-ui and name of .pc files are
    share-ui-plugin.pc, share-widgets.pc, share-ui-common.pc

  5. #5
    Registered User
    Join Date
    Mar 2003
    Posts
    22

    Re: Accessing ShareUI on Harmattan/MeeGo ?

    Thanks for your responses, but I am still missing something fundamental.

    If I check out this project:

    http://meego.gitorious.org/~jussini/...ui-declarative

    open up the top level (or any level actually) .pro file and add

    # share lib setup
    CONFIG += libshare-ui
    PKGCONFIG += share-ui-plugins share-widgets share-ui-common

    to the .pro file then it still does not link the ShareUI or compile. The error is

    ../../share-ui-declarative/libshare-ui-declarative/src/itemcontainer.cpp:26:33: error: ShareUI/ItemContainer: No such file or directory

    I am tempted to copy in a ShareUI directory, but I still think it should link without any placeholders in the file system.

    Maybe compiling one of the MeeGo sharing framework projects is irrelevant? I was hoping to wrap up the sharing API in QML components and that seems to be accomplished by those projects.

    Will try pulling in a SharedUI dir and then try importing the ShareUI in my hello world project.

  6. #6
    Registered User
    Join Date
    Mar 2003
    Posts
    22

    Re: Accessing ShareUI on Harmattan/MeeGo ?

    Quick follow up, tried the following with no success:

    1. In a hello world project try to:

    #include <ShareUI/Item>

    while having the following in the .pro file:

    # share lib setup
    CONFIG += libshare-ui
    PKGCONFIG += share-ui-plugins share-widgets share-ui-common

    which does not link up

    2. Copy in a ShareUI folder

    This is one of the outer rings of dependency hell, the ShareUI links but then wants thumbnailer/Thumbnailer for which I do not have a stub package.


    Going to try the 'go out to lunch' option now, might get some ideas..

  7. #7
    Super Contributor
    Join Date
    Oct 2009
    Posts
    4,326

    Re: Accessing ShareUI on Harmattan/MeeGo ?

    libshare-ui has 3 qmake configurations: share-widgets, share-ui-plugin, share-ui-common.
    There is no libshare-ui configuration.
    Also there is no share-ui-plugins.pc.

  8. #8
    Registered User
    Join Date
    Mar 2003
    Posts
    22

    Re: Accessing ShareUI on Harmattan/MeeGo ?

    Tried this again and still no success, my main/cpp looks like:

    #include <QtGui/QApplication>
    #include <QtDeclarative>
    #include <ShareUI/Item>

    int main(int argc, char *argv[])
    {
    QApplication app(argc, argv);
    QDeclarativeView view;
    view.setSource(QUrl("qrc:/qml/main.qml"));
    view.showFullScreen();
    return app.exec();
    }

    and I have added the following to my .pro file:

    # share ui setup
    CONFIG += share-widget share-ui-plugin share-ui-common
    PKGCONFIG += share-widget share-ui-plugin share-ui-common

    The ShareUI lib still will not link. Error is

    ../sharebear/main.cpp:3: fatal error: ShareUI/Item: No such file or directory

    Where sharebear is the name of my hello world project. Seems like this should be simple, but it is not documented anywhere.

    Any advice would be appreciated!

    Thanks,

    Maciej

  9. #9
    Super Contributor
    Join Date
    Oct 2009
    Posts
    4,326

    Re: Accessing ShareUI on Harmattan/MeeGo ?

    Could you please show full content of the project file?

  10. #10
    Super Contributor
    Join Date
    Mar 2009
    Posts
    1,024

    Re: Accessing ShareUI on Harmattan/MeeGo ?

    You forgot to add link_pkgconfig to the CONFIG var:

    CONFIG += link_pkgconfig

  11. #11
    Registered User
    Join Date
    Mar 2003
    Posts
    22

    Re: Accessing ShareUI on Harmattan/MeeGo ?

    Thanks for your replies! Still no luck!

    Does the order of CONFIG entries matter?

    I have posted up my hello-world project on github: https://github.com/matyjas/share-bear

    You can see the full content of the .pro file here : https://github.com/matyjas/share-bea.../sharebear.pro

    Looking forward to any further comments!

  12. #12
    Super Contributor
    Join Date
    Oct 2009
    Posts
    4,326

    Re: Accessing ShareUI on Harmattan/MeeGo ?

    Sometimes it helps to read error messages
    Code:
    [sbox-arm: ~/matyjas-share-bear-6b73654] > qmake
    Package share-widget was not found in the pkg-config search path.
    Perhaps you should add the directory containing `share-widget.pc'
    to the PKG_CONFIG_PATH environment variable
    No package 'share-widget' found
    Package share-widget was not found in the pkg-config search path.
    Perhaps you should add the directory containing `share-widget.pc'
    to the PKG_CONFIG_PATH environment variable
    No package 'share-widget' found
    Package share-widget was not found in the pkg-config search path.
    Perhaps you should add the directory containing `share-widget.pc'
    to the PKG_CONFIG_PATH environment variable
    No package 'share-widget' found
    [sbox-arm: ~/matyjas-share-bear-6b73654] > dpkg -L libshare-ui-dev | grep pc
    /usr/lib/pkgconfig/share-ui-plugin.pc
    /usr/lib/pkgconfig/share-widgets.pc
    /usr/lib/pkgconfig/share-ui-common.pc

  13. #13
    Registered User
    Join Date
    Mar 2003
    Posts
    22

    Re: Accessing ShareUI on Harmattan/MeeGo ?

    I have tried setting PKG_CONFIG_PATH in my .zshrc as well as the Projects/Build Environment section of Qt Creator, but still get the same error. My setting looks like:

    export PKG_CONFIG_PATH=/Users/maciej/QtSDK1.1/Madde/sysroots/harmattan-arm-sysroot/usr/lib/pkgconfig/

    or the equivalent in the Build Environment section. Does not seem to make any difference. Here is some interesting output:

    [13:04:42] maciej:~ $ mad pkg-config share-widgets
    Package share-widgets was not found in the pkg-config search path.
    No package 'share-widgets' found
    [13:05:01] maciej:~ $ echo $PKG_CONFIG_PATH
    /Users/maciej/QtSDK1.1/Madde/sysroots/harmattan-arm-sysroot/usr/lib/pkgconfig/
    [13:05:12] maciej:~ $


    Where/how should I be setting PKG_CONFIG_PATH? Ideally, I would like to set it in my .pro file so I can share the configuration with my team.

    Thanks!
    Last edited by mac1ej; 2011-07-06 at 13:07.

  14. #14
    Super Contributor
    Join Date
    Oct 2009
    Posts
    4,326

    Re: Accessing ShareUI on Harmattan/MeeGo ?

    Quote Originally Posted by mac1ej View Post
    I have tried setting PKG_CONFIG_PATH in my .zshrc as well as the Projects/Build Environment section of Qt Creator, but still get the same error. My setting looks like:

    export PKG_CONFIG_PATH=/Users/maciej/QtSDK1.1/Madde/sysroots/harmattan-arm-sysroot/usr/lib/pkgconfig/

    or the equivalent in the Build Environment section. Does not seem to make any difference.

    Where/how should I be setting PKG_CONFIG_PATH? Ideally, I would like to set it in my .pro file so I can share the configuration with my team.

    Thanks!
    Are you trolling here?

  15. #15
    Registered User
    Join Date
    Mar 2003
    Posts
    22

    Re: Accessing ShareUI on Harmattan/MeeGo ?

    Not trolling, really trying to solve this, have gone to great lengths to figure this out and I appreciate your responses so far. I do not think I am the only one struggling with this and I fully intend to document this once it is resolved.

    Also see my output from the command line:

    [13:04:42] maciej:~ $ mad pkg-config share-widgets
    Package share-widgets was not found in the pkg-config search path.
    No package 'share-widgets' found
    [13:05:01] maciej:~ $ echo $PKG_CONFIG_PATH
    /Users/maciej/QtSDK1.1/Madde/sysroots/harmattan-arm-sysroot/usr/lib/pkgconfig/
    [13:05:12] maciej:~ $

Similar Threads

  1. Grab Volume Keys on Harmattan
    By mzanetti1 in forum Nokia N9
    Replies: 5
    Last Post: 2011-10-25, 22:25
  2. MeeGo on BeagleBoard xm
    By ketan_kamat in forum Nokia N9
    Replies: 1
    Last Post: 2011-06-23, 15:57
  3. Resources on Harmattan
    By goshakkk in forum Nokia N9
    Replies: 5
    Last Post: 2011-06-23, 13:57
  4. Meego on N900
    By waelfarouk in forum Nokia N9
    Replies: 3
    Last Post: 2011-06-23, 13:47
  5. Replies: 2
    Last Post: 2010-10-22, 23:35

Posting Permissions

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