[Qt-interest] Running Qt 4.7 applications without Qt 4.6 interfering

Thiago Macieira thiago at kde.org
Thu May 6 22:13:22 CEST 2010


Em Quinta-feira 6. Maio 2010, às 19.43.01, Nikos Chantziaras escreveu:
> On 05/06/2010 08:14 PM, Thiago Macieira wrote:
> > Em Quinta-feira 06 Maio 2010, às 17:09:55, Nikos Chantziaras escreveu:
> >> Thanks, but same result.  Btw, setting all those env vars isn't
> >> necessary since I use qmake which knows to use the correct paths.  It
> >> even sets the rpath linker flag to the correct location inside my home
> >> dir.
> >> 
> >> I believe some of the libs of Qt 4.7 is trying to dynamically load
> >> another Qt lib that isn't there, and resorts to locating it in /usr/lib.
> >> 
> >>    But unfortunately, it doesn't say which library it tries to load...
> >> 
> >> It only spits out the error message with no further context.
> > 
> > The most likely case is QtDBus. If you're on Linux, you might have KDE 4
> > installed, which installs its Oxygen style plugin. That will trigger
> > loading of QtDBus.
> > 
> > Make sure you built that library too.
> 
> Btw, now that the programs runs, I can actually use lsof and see what it
> uses.  I've come across a bit of weirdness:
> 
>    lsof /usr/lib/qt4/*.4.6.2 | grep MyAppName
> 
> This results in:
> 
>    MyAppName [bla bla] /usr/lib64/qt4/libQtSvg.so.4.6.2
> 
> How come this works and I don't get a "Cannot mix incompatible Qt
> library" error?

"Cannot mix incompatible Qt library" errors come from the use of 
QObjectPrivate. If the library doesn't use it or if you don't cause it to use 
it, the error won't appear.

I'm working on a more generic solution that would avoid this kind of problem.

-- 
Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
  Senior Product Manager - Nokia, Qt Development Frameworks
      PGP/GPG: 0x6EF45358; fingerprint:
      E067 918B B660 DBD1 105C  966C 33F5 F005 6EF4 5358
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
Url : http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20100506/fec67111/attachment.bin 


More information about the Qt-interest-old mailing list