Qt4 and QtGSI in ROOT v 5.22.00

Hello,

I am trying to write a package using Qt4 and ROOT. I have some minimal Qt4 code that compiles and runs. It does not yet include any ROOT stuff. If I compile this code with -lQtGSI, I get an error message:

when I try to run the executable. (Note that libqt-mt.so.3 is a Qt3 library.) The error message goes away if I append the Qt3 library to LD_LIBRARY_PATH, but then the program crashes.

I am linking against /afs/cern.ch/sw/lcg/app/releases/ROOT/5.22.00/slc4_ia32_gcc34/root/lib/libQtGSI.so. I have confirmed with ldd that the executable compiled with -lQtGSI depends on libqt-mt.so.3, and that the executable compiled without -lQtGSI does not depend on libqt-mt.so.3.

It has been posted that ROOT versions higher than 5.21.06 support only Qt4. The problem I am experiencing suggests that there may still be some dependence on Qt3. I would appreciate it if someone could check this.

Hi,

That’s weird… I’ll check and let you know.
Edited:
Looking at the make log, it seems to be the right configuration (Qt4.4.2):
g++ -shared -Wl,-soname,libQtGSI.so -m32 -O2 -o lib/libQtGSI.so gui/qtgsi/src/TQApplication.o gui/qtgsi/src/TQCanvasImp.o gui/qtgsi/src/TQCanvasMenu.o gui/qtgsi/src/TQRootApplication.o gui/qtgsi/src/TQRootCanvas.o gui/qtgsi/src/TQRootDialog.o gui/qtgsi/src/TQRootGuiFactory.o gui/qtgsi/src/G__QtGSI.o gui/qtgsi/src/moc_TQCanvasMenu.o gui/qtgsi/src/moc_TQRootApplication.o gui/qtgsi/src/moc_TQRootCanvas.o gui/qtgsi/src/moc_TQRootDialog.o -Llib -lGui -lGpad -L/afs/cern.ch/sw/lcg/external/qt/4.4.2/slc4_ia32_gcc34/lib -lQtCore -lQtGui -lQt3Support -lQtOpenGL -lQtSvg -lQtXml -Llib -lCore -lCint

I’ll give it a try it next week (I will be away until then)

Cheers, Bertrand.

You can try QtRoot from BNL.
root.bnl.gov/QtRoot/How2Install4Unix.html
It supports GSI interface as well
root.bnl.gov/QtRoot/htmldoc/TQRootCanvas.html

[quote=“hulya”][quote]…/i686-slc4-gcc34-dbg/trp: error while loading shared libraries: libqt-mt.so.3: cannot open shared object file: No such file or directory[/quote]. . .
I am linking against /afs/cern.ch/sw/lcg/app/releases/ROOT/5.22.00/slc4_ia32_gcc34/root/lib/libQtGSI.so. I have confirmed with ldd that the executable compiled with -lQtGSI depends on libqt-mt.so.3, and that the executable compiled without -lQtGSI does not depend on libqt-mt.so.3. [/quote]
libQtGSI.so library is Qt4-based library:

ldd /afs/cern.ch/sw/lcg/app/releases/ROOT/5.22.00/slc4_ia32_gcc34/root/lib/libQtGSI.so linux-gate.so.1 => (0xffffe000) libGui.so => not found libGpad.so => not found libQtCore.so.4 => not found libQtGui.so.4 => not found libQt3Support.so.4 => not found libQtOpenGL.so.4 => not found libQtSvg.so.4 => not found libQtXml.so.4 => not found libCore.so => not found libCint.so => not found libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0xf7eca000) libm.so.6 => /lib/tls/libm.so.6 (0xf7ea7000) libgcc_s.so.1 => /lib/libgcc_s.so.1 (0xf7e9d000) libc.so.6 => /lib/tls/libc.so.6 (0xf7d6e000) /lib/ld-linux.so.2 (0x56555000)
It has no Qt3 dependency. Can you show how you built your application? I suspect :unamused: there were Qt3 utilities on your :bulb: PATH and your build process used some of them

Thank you very much for your help. The problem was indeed with LD_LIBRARY_PATH. The program needs to use the ATLAS TDAQ paths, and one of the essential directories in this path includes links to older ROOT libraries (version 5.18.00f).

*/afs/cern.ch/atlas/project/tdaq/cmt/dqm-common/ dqm-common-00-07-01/external/i686-slc4-gcc34-dbg/lib