[Qt-interest] Cannot link against shared lib in Harmattan

Srikanth srikanthsombhatla at gmail.com
Mon Jan 2 09:13:55 CET 2012


Hi,

I am linking against a lib which is part of the same project as the app.
Every thing is created using Qt Creator, so that template for lib is using
target = /usr/lib and mentioning INSTALLS += target.

Thanks,
Srikanth

On Sat, Dec 31, 2011 at 4:30 PM, <qt-interest-request at qt.nokia.com> wrote:

> Send Qt-interest mailing list submissions to
>        qt-interest at qt.nokia.com
>
> To subscribe or unsubscribe via the World Wide Web, visit
>        http://lists.qt.nokia.com/mailman/listinfo/qt-interest
> or, via email, send a message with subject or body 'help' to
>        qt-interest-request at qt.nokia.com
>
> You can reach the person managing the list at
>        qt-interest-owner at qt.nokia.com
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Qt-interest digest..."
>
> Today's Topics:
>
>   1. Re: Cannot link against shared lib in Harmattan
>      (Christian Kandeler)
>   2. Problems with custom URL schemes support in QWebView
>      (Sergei Stolyarov)
>   3. Printing widget's content (not render) (jani at wbsources.com)
>   4. Re: Problems with custom URL schemes support in   QWebView
>      (Sergei Stolyarov)
>
>
> ---------- Forwarded message ----------
> From: Christian Kandeler <christian.kandeler at nokia.com>
> To: qt-interest at qt.nokia.com
> Cc:
> Date: Fri, 30 Dec 2011 13:55:34 +0100
> Subject: Re: [Qt-interest] Cannot link against shared lib in Harmattan
> On 12/30/2011 08:37 AM, ext Srikanth wrote:
>
>> I am unable to link my app with my custom shared lib ( not a system lib
>> ) when building for Harmattan. It fails at deployment step. Since
>> linking against my custom lib is a very basic part of development, I am
>> surprised that Qt on Harmattan did not receive the love.
>>
>>      dpkg-shlibdeps: failure: couldn't find library libmylib.so.1
>>      needed by debian/bigtest/opt/hell/bin/**hell (its RPATH is '').
>>
>
> What exactly are you doing? Is the library part of the same project as the
> app? In that case, you probably forgot to add it to the INSTALLS list or
> you are deploying it to a non-standard place (in which case you need RPATH,
> as the error message hints at).
>
>
> Christian
>
>
>
> ---------- Forwarded message ----------
> From: Sergei Stolyarov <sergei.stolyarov at regolit.com>
> To: qt-interest at qt.nokia.com
> Cc:
> Date: Fri, 30 Dec 2011 22:28:28 +0700
> Subject: [Qt-interest] Problems with custom URL schemes support in QWebView
> Hello.
>
> I’m trying to add support for custom URL scheme to QWebView. I’ve
> found tutorial that explains this in details: create new class derived
> from QNetworkAccessManager, create new QNetworkReply-derived class
> etc. Ok, I followed that guide and wrote simple project, but for some
> reasons QWebView doesn’t display data I’m sending back in the reply,
> just white empty page. My point is I already have all needed data for
> custom url at the moment of Reply instance creation, and I don’t
> perform any actual network requests.
>
> The simple demo project I created is available here (
> http://dl.dropbox.com/u/11629166/tmp/sample.zip )
>
> >From debug marks I see that my data successfully sent back to caller,
> but webpage displays nothing.
>
> Here are some code fragments:
>
>
> Reply::Reply(const QUrl & url)
>    : QNetworkReply()
> {
>    qDebug() << "gen reply";
>    open(ReadOnly | Unbuffered);
>
>    content = QByteArray('t', 1000); // fill with character 't'
>    setHeader(QNetworkRequest::ContentTypeHeader,
>                    QVariant("text/html; charset=UTF-8"));
>
>    setHeader(QNetworkRequest::ContentLengthHeader,
>                    QVariant(content.size()));
>    offset = 0;
>
>    QTimer::singleShot(0, this, SIGNAL(metaDataChanged()));
>    QTimer::singleShot(0, this, SIGNAL(readyRead()));
>    QTimer::singleShot(0, this, SIGNAL(finished()));
> }
>
>
>
> qint64 Reply::readData(char *data, qint64 maxSize)
> {
>    if (offset < content.size()) {
>        qint64 number = qMin(maxSize, content.size() - offset);
>        memcpy(data, content.constData() + offset, number);
>        qDebug() << "fetching content";
>        offset += number;
>        return number;
>    } else
>        return -1;
> }
>
> --
> Sergei Stolyarov
>
>
>
> ---------- Forwarded message ----------
> From: jani at wbsources.com
> To: qt-interest at qt.nokia.com
> Cc:
> Date: Sat, 31 Dec 2011 01:19:31 +0100
> Subject: [Qt-interest] Printing widget's content (not render)
> Hello,
>
> I had a problem with printing, especially scaling the fonts from screen's
> resolution to printer's resolution.
> During I set up an example to illustrate what I am tried to solve I found
> the solution as well, but did not want to waste my time, I decided to post
> here the example of printing a widget's content on my way.
>
> I am using this kind of approach to print invoices and other basic stuff,
> but not by rendering the widget into a pixmap. That is not elegant.
>
> Also it is very nice to use Qt designer itself to create printable content.
>
> If anybody knows better solution for this, please share with me.
>
> BR, Jani.
>
>
> ---------- Forwarded message ----------
> From: Sergei Stolyarov <sergei.stolyarov at regolit.com>
> To: qt-interest at qt.nokia.com
> Cc:
> Date: Sat, 31 Dec 2011 12:56:32 +0700
> Subject: Re: [Qt-interest] Problems with custom URL schemes support in
> QWebView
> Just found a solution: I was missing required parent call inside
> bytesAvailable() implementation. So this article
> http://doc.qt.nokia.com/qq/32/qq32-webkit-protocols.html is not
> completely correct.
>
> On Fri, Dec 30, 2011 at 10:28 PM, Sergei Stolyarov
> <sergei.stolyarov at regolit.com> wrote:
> > Hello.
> >
> > I’m trying to add support for custom URL scheme to QWebView. I’ve
> > found tutorial that explains this in details: create new class derived
> > from QNetworkAccessManager, create new QNetworkReply-derived class
> > etc. Ok, I followed that guide and wrote simple project, but for some
> > reasons QWebView doesn’t display data I’m sending back in the reply,
> > just white empty page. My point is I already have all needed data for
> > custom url at the moment of Reply instance creation, and I don’t
> > perform any actual network requests.
> >
> > The simple demo project I created is available here (
> > http://dl.dropbox.com/u/11629166/tmp/sample.zip )
> >
> > From debug marks I see that my data successfully sent back to caller,
> > but webpage displays nothing.
> >
> > Here are some code fragments:
> >
> >
> > Reply::Reply(const QUrl & url)
> >    : QNetworkReply()
> > {
> >    qDebug() << "gen reply";
> >    open(ReadOnly | Unbuffered);
> >
> >    content = QByteArray('t', 1000); // fill with character 't'
> >    setHeader(QNetworkRequest::ContentTypeHeader,
> >                    QVariant("text/html; charset=UTF-8"));
> >
> >    setHeader(QNetworkRequest::ContentLengthHeader,
> >                    QVariant(content.size()));
> >    offset = 0;
> >
> >    QTimer::singleShot(0, this, SIGNAL(metaDataChanged()));
> >    QTimer::singleShot(0, this, SIGNAL(readyRead()));
> >    QTimer::singleShot(0, this, SIGNAL(finished()));
> > }
> >
> >
> >
> > qint64 Reply::readData(char *data, qint64 maxSize)
> > {
> >    if (offset < content.size()) {
> >        qint64 number = qMin(maxSize, content.size() - offset);
> >        memcpy(data, content.constData() + offset, number);
> >        qDebug() << "fetching content";
> >        offset += number;
> >        return number;
> >    } else
> >        return -1;
> > }
> >
> > --
> > Sergei Stolyarov
>
>
>
> --
> Sergei Stolyarov
>
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at qt.nokia.com
> http://lists.qt.nokia.com/mailman/listinfo/qt-interest
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20120102/26b16ec4/attachment.html 


More information about the Qt-interest-old mailing list