Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / qt / 2011-01

Compile Pascal Qt Interface from source

12 messages · 3 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Juha Manninen

Hi

This is related to mail "Another qt IDE crash" in Lazarus-dev list. I have updated my Fedora 14 64-bit with "yum update" and now Lazarus with QT bindings crashes.

I didn't get past the beginning when trying to build it from source.

$ qmake -query
QT_INSTALL_PREFIX:/usr/lib64/qt4
QT_INSTALL_DATA:/usr/lib64/qt4
QT_INSTALL_DOCS:/usr/share/doc/qt4
QT_INSTALL_HEADERS:/usr/include
QT_INSTALL_LIBS:/usr/lib64
QT_INSTALL_BINS:/usr/lib64/qt4/bin
QT_INSTALL_PLUGINS:/usr/lib64/qt4/plugins
QT_INSTALL_IMPORTS:/usr/lib64/qt4/imports
QT_INSTALL_TRANSLATIONS:/usr/share/qt4/translations QT_INSTALL_CONFIGURATION:/etc
QT_INSTALL_EXAMPLES:/usr/lib64/qt4/examples
QT_INSTALL_DEMOS:/usr/lib64/qt4/demos
QMAKE_MKSPECS:/usr/lib64/qt4/mkspecs
QMAKE_VERSION:2.01a
QT_VERSION:4.7.1

But then
$qmake
or
$qmake -makefile
just give a help screen, as if expecting more parameters. What should I do?

Juha

Den Jean
to Juha Manninen
Juha Manninen wrote
Hi This is related to mail "Another qt IDE crash" in Lazarus-dev list.

Cannot find that thread, the lazarus ML is way too noisy can you provide an url using the archives:
http://lists.lazarus.freepascal.org/pipermail/lazarus/

I have updated my Fedora 14 64-bit with "yum update" and now Lazarus with QT bindings crashes.

perhaps related to this thread:
http://lists.lazarus.freepascal.org/pipermail/qt/2010-November/001596.html and indeed I did not release a 64 binary

the source tarfile contains a README with instructions. For the mstackrealign I wrote instructions on the webpage http://users.telenet.be/Jan.Van.hijfte/qtforfpc/fpcqt4.html

Could you first follow both instructions, repeating it here is meaningless.

If it is still is not clear, I'd like to know what in order to be able to improve the instructions.

Juha Manninen
to Den Jean
Show quoted text 6 lines
> This is related to mail "Another qt IDE crash" in Lazarus-dev list. Cannot find that thread, the lazarus ML is way too noisy can you provide an url using the archives: http://lists.lazarus.freepascal.org/pipermail/lazarus/

It was in the developers' list. I guess you don't have access to it. Anyway, there I mentioned that my Lazarus crashes and there is no 64-bit version of the QT4.7 compatible interface.
Zeljko mentioned I must compile the interface myself.

Show quoted text 7 lines
I have updated my Fedora 14 64-bit with "yum update" and now Lazarus with QT bindings crashes. perhaps related to this thread: http://lists.lazarus.freepascal.org/pipermail/qt/2010-November/001596.html and indeed I did not release a 64 binary

This tells to download the 32-bit binary.

the source tarfile contains a README with instructions. For the mstackrealign I wrote instructions on the webpage http://users.telenet.be/Jan.Van.hijfte/qtforfpc/fpcqt4.html

Ok, I must have been tired when trying it. I was in the "src" directory and didn't figure out I must do "cd ..". I have built and installed the lib now. An idea for improvement:
Add the mstackrealign line in Qt4Pas.pro and comment it out by default. Also this test should be changed or removed:

!equals(QT_MAJOR_VERSION,4)|!equals(QT_MINOR_VERSION,5) { message("This pascal binding should be used for 4.5.3 and current Qt is" $$QT_VERSION)
}

The lib is installed but my Lazarus still will send another mail, wait...

Regards,
Juha
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus.freepascal.org/pipermail/qt/attachments/20110130/0c011d9c/attachment.html>

Juha Manninen
to Juha Manninen

I don't think this is about mstackrealign.
I copied here the backtrace of a crash which happens right after starting Lazarus. A GTK2 version works fine.

Something to do with QToolButton::popup...

I have built and installed the QT4.7 compatible interface, rebooted the machine and even deleted the dir ~/.lazarus to make sure it is not a Lazarus config issue.
I don't know why the backtrace lists "oxygen.so".
I have changed KDE theme to Plastik some time ago. This may be related to Fedora update which sometimes needs tweaking.

Juha

---

Program received signal SIGSEGV, Segmentation fault. QToolButton::popupMode (this=0x0) at widgets/qtoolbutton.cpp:1054 1054 return d->popupMode;
Missing separate debuginfos, [...]

(gdb) bt
#0 QToolButton::popupMode (this=0x0) at widgets/qtoolbutton.cpp:1054 #1 0x00007ffff13b5e2d in ?? () from /usr/lib64/kde4/plugins/styles/oxygen.so #2 0x00007ffff13b734a in ?? () from /usr/lib64/kde4/plugins/styles/oxygen.so #3 0x00007ffff139b9cb in ?? () from /usr/lib64/kde4/plugins/styles/oxygen.so #4 0x00000000009563ae in DRAWELEMENT (this=0x7ffff7fe64c0, DC=140737149745216, DETAILS=..., R=..., CLIPRECT=0x0) at qtthemes.pas:245 #5 0x000000000092b024 in DRAWDROPDOWNARROW (parentfp=0x7fffffffaa50, OWNERDETAILS=..., DROPDOWNBUTTONRECT=...) at include/toolbutton.inc:167 #6 0x000000000092a9cc in PAINT (this=0x7fffee809350) at include/toolbutton.inc:343
#7 0x00000000008beda7 in WMPAINT (this=0x7fffee809350, MESSAGE=...) at include/graphiccontrol.inc:64
#8 0x00000000006e0209 in SYSTEM_TOBJECT_$__DISPATCH$formal () #9 0x00000000008becd0 in ?? ()
#10 0x00007fffee809350 in ?? ()
#11 0x0000000000000001 in ?? ()
#12 0x000000000000000f in ?? ()
#13 0x00007fffffffac48 in ?? ()
#14 0x00007fffee809350 in ?? ()
#15 0x0000000000000007 in ?? ()
#16 0x0000000000000000 in ?? ()

zeljko
to Juha Manninen
Juha Manninen wrote
I don't think this is about mstackrealign. I copied here the backtrace of a crash which happens right after starting Lazarus. A GTK2 version works fine.

If you don't have bindings compiled with -mstackrealign , you'll get crashes with QT_NATIVE_DIALOGS and with TQtCustomControl on scrollbars (like TSynEdit, TTreeView etc).
I don't know if we need some more switches for 64 bit.

Show quoted text 9 lines
Something to do with QToolButton::popup... I have built and installed the QT4.7 compatible interface, rebooted the machine and even deleted the dir ~/.lazarus to make sure it is not a Lazarus config issue. I don't know why the backtrace lists "oxygen.so". I have changed KDE theme to Plastik some time ago. This may be related to Fedora update which sometimes needs tweaking.

1. I have Fedora 14 + full updated (32bit) and everything works fine.
2. Your debug information is not complete. To get *really understandable* debug info you have to install debuginfo packages.From your debug information nothing can be seen.

zeljko

Juha Manninen
to zeljko

zeljko kirjoitti sunnuntai 30 tammikuu 2011 16:22:21:

1. I have Fedora 14 + full updated (32bit) and everything works fine. 2. Your debug information is not complete. To get *really understandable* debug info you have to install debuginfo packages.From your debug information nothing can be seen.

Ok, I got it working. I had installed KDE and QT from a testing repository. It was working until now but then something broke. I disabled it and run "yum distribution-synchronization" and now Lazarus works. I will not use testing repository in future.

Den Jean, do you want me to send the new 64-bit interface libs to you, for others to download?

Juha

Den Jean
to Juha Manninen
Juha Manninen wrote
Ok, I got it working. I had installed KDE and QT from a testing repository. It was working until now but then something broke. I disabled it and run "yum distribution-synchronization" and now Lazarus works. I will not use testing repository in future.

I installed a 64bit linux but cannot reproduce the crash for the moment (oxygen theme,QT_NATIVE_DIALOGS,Qt 4.7.1 etc...)

Den Jean, do you want me to send the new 64-bit interface libs to you, for others to download?

not necessary anymore,thx, will first find out why I cannot get LD_LIBRARY_PATH to work as expected.

zeljko
to Den Jean
Den Jean wrote 14 lines
On Monday 31 January 2011 01:45:24 Juha Manninen wrote: > Ok, I got it working. I had installed KDE and QT from a testing > repository. It was working until now but then something broke. > I disabled it and run "yum distribution-synchronization" and now Lazarus > works. I will not use testing repository in future. I installed a 64bit linux but cannot reproduce the crash for the moment (oxygen theme,QT_NATIVE_DIALOGS,Qt 4.7.1 etc...) > Den Jean, do you want me to send the new 64-bit interface libs to you, > for others to download? not necessary anymore,thx, will first find out why I cannot get LD_LIBRARY_PATH to work as expected.

Because 64 bit libs must exist in /usr/lib64 ?

Juha Manninen
to Den Jean: I installed a 64bit linux but cannot reproduce the crash for the moment (oxygen…

Den Jean kirjoitti maanantai 31 tammikuu 2011 21:59:11:

Show quoted text 8 lines
On Monday 31 January 2011 01:45:24 Juha Manninen wrote: > Ok, I got it working. I had installed KDE and QT from a testing > repository. It was working until now but then something broke. > I disabled it and run "yum distribution-synchronization" and now Lazarus > works. I will not use testing repository in future. I installed a 64bit linux but cannot reproduce the crash for the moment (oxygen theme,QT_NATIVE_DIALOGS,Qt 4.7.1 etc...)

It may be difficult to reproduce. I used the following [kde-testing] Fedora repo. It used to work but one update broke something and Lazarus crashed. All KDE programs worked as before though.
QT was updated to 4.7.1.something. Maybe it had a new experimental feature.

"oxygen.so" in the backtrace still buzzles me because I had used KDE theme Plastik for many days instead of Oxygen. Their window appearance differs so much that they can't be confused.

Juha

[kde-testing]
name=kde-testing
mirrorlist=http://apt.kde-redhat.org/apt/kde-redhat/fedora/mirrors-testing

Den Jean
to zeljko: Because 64 bit libs must exist in /usr/lib64 ?
zeljko wrote
Because 64 bit libs must exist in /usr/lib64 ?

well of course, but as my distro does not have
packages for Qt 4.7.1, I compile Qt 4.7.1 and set
a LD_LIBRARY_PATH to the version I am building
a binding against. In 32bit this works, in 64
ld does not use LD_LIBRARY_PATH. I verified
this with make ... OPT="-k ' --verbose '"
Using OPT="-k '-LMyQtPath'" it works.