WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Qt 4.8.1  (Read 9280 times)

Offline medvedm

  • Newbie
  • *
  • Posts: 48
Qt 4.8.1
« on: August 21, 2012, 04:03:02 PM »
Hey all-

Would someone update the qt libraries to 4.8.1, please?

M

Offline SvOlli

  • Full Member
  • ***
  • Posts: 193
  • Linux Developer
Re: Qt 4.8.1
« Reply #1 on: August 21, 2012, 06:03:05 PM »
Qt 4.8 has some differences on how to configure, which might be needed to be looked at.

Experience shows that it's rather easy to get a qt version compiled, but difficult to select the options that pleases everyone while keeping it as small as possible. In the past there have usually more than one iteration until a stable version has been assembled. I'm lacking the time to do some proper testing.

I can offer an update to 4.7.4 in an almost same configuration, using the currently deployed libraries, if that should be enough.

BTW: I'm using Qt both at the job and for private coding. The only thing that encouraged me to update Qt to a current version was using the Qt creator. For everything I code, 4.6 even would be enough. What do you need 4.8 for?

Offline medvedm

  • Newbie
  • *
  • Posts: 48
Re: Qt 4.8.1
« Reply #2 on: August 23, 2012, 09:24:13 AM »
I develop our application on an Ubuntu based distro, which recently updated to 4.8.1, and I suppose I just want the versions on my host and target to be in sync.  I thought it might induce bugs if I compile on and test on ubuntu on one version of Qt, and then when I run the program on the target use a differing version of Qt.  So I guess there isn't a specific "I need 4.8.x for this or that feature or bug fix."

I don't use much beyond QtCore QtNetwork and QTestLib, although I think I will have to write a graphical app on the target soon, which obviously will add QGui.


Offline Fazzah

  • Newbie
  • *
  • Posts: 20
Re: Qt 4.8.1
« Reply #3 on: September 07, 2012, 08:43:34 AM »
Hey SvOlli, could you please remember to include PSQL database driver this time?

Thanks.
My extensions: lcdproc-server | lcdproc-client | darkiceWIP | icecast2WIP

Offline medvedm

  • Newbie
  • *
  • Posts: 48
Re: Qt 4.8.1
« Reply #4 on: September 07, 2012, 09:05:01 AM »
Also, it looks like 4.8.2 is the latest and greatest.

I compiled it on tinycore, but I have no idea how to package it up as a .tcz, or what options should be used for tinycore (there are a million different ones in the config file).

I ended up just copying the four or so shared object files that I need into my install and backing them up (and doing ldconfig).

If there were instructions on how to package the thing up, how much testing needs be done, what configuration and compiler options need to be used (32 vs. 64 bit?) I could start getting it ready, maybe?

M

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11044
Re: Qt 4.8.1
« Reply #5 on: September 07, 2012, 10:30:55 AM »
If you just want to pack it up for personal use, it's very easy: see the wiki.

If you want to submit it instead, you'll have to sort things out with svolli, the current qt maintainer.
The only barriers that can stop you are the ones you create yourself.

Offline medvedm

  • Newbie
  • *
  • Posts: 48
Re: Qt 4.8.1
« Reply #6 on: September 07, 2012, 10:59:56 AM »
Wow, just read the wiki, I'm not sure "very easy" is the phrase I'd use.  :)


Offline jls

  • Hero Member
  • *****
  • Posts: 2135
Re: Qt 4.8.1
« Reply #7 on: September 07, 2012, 11:08:17 AM »
you could also use tc-ext-tools for packaging
dCore user

Offline vinnie

  • Hero Member
  • *****
  • Posts: 1187
  • HandMace informatic works
Re: Qt 4.8.1
« Reply #8 on: September 07, 2012, 11:34:24 AM »
Wow, just read the wiki, I'm not sure "very easy" is the phrase I'd use.  :)
If I do the task, with my poor knowledge of english, there is anyone can do it!

In broad terms you must:
- compile the package, making sure to satisfy all dependencies and checking that the prefix is set in /usr/local (to most case), this setting lies in the makefile generated (or not) with the ./configure
- install it in a working directory like /tmp/work_dir with "DESTDIR" argoument of command make install
- package it with squashfs-tools-4.x.tcz:  mksquashfs /tmp/work_dir/ package_name.tcz

It is all (for personal use, for packets destined for the repository must do other things)
Many programs compile in a different way, but the result you have to get  is that.
« Last Edit: September 07, 2012, 11:54:06 AM by vinnie »

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11044
Re: Qt 4.8.1
« Reply #9 on: September 07, 2012, 12:53:48 PM »
Wow, just read the wiki, I'm not sure "very easy" is the phrase I'd use.  :)

Since you already had it compiled, it would be a one-liner command to package it to a squashfs. Yeah, I think that is easy :)

Setting up the directory structure, if you don't have the sources anymore to use DESTDIR, is a couple commands more, though.
The only barriers that can stop you are the ones you create yourself.

Offline SvOlli

  • Full Member
  • ***
  • Posts: 193
  • Linux Developer
Re: Qt 4.8.1
« Reply #10 on: September 07, 2012, 07:26:51 PM »
And you should also consider slicing things up, so that an application that does only use Qt for ui display does not need to load the webbrowser components also to the harddisk.

You should also make sure that you recompile Qt Creator, since it is tightly bound to the current Qt version for a look inside the classes when running the debugger.

Offline Fazzah

  • Newbie
  • *
  • Posts: 20
Re: Qt 4.8.1
« Reply #11 on: November 12, 2012, 09:09:51 AM »
*sigh*,

problems again.

I have a fresh NFS install of TinyCore. Installed Qt/PyQt, and python throws an "Illegal instruction". This is the code I'm testing:

Code: (python) [Select]
import sys

from PyQt4.QtCore import *
from PyQt4.QtGui import *
from PyQt4.QtSql import *

app = QApplication(sys.argv)
app.setApplicationName('test')

db = QSqlDatabase.addDatabase("QPSQL")
db.setHostName("server")
db.setDatabaseName("mydb")
db.setUserName("user")
db.setPassword("pass")
db.open()

model = QSqlRelationalTableModel()
model.setTable('employees')
model.select()


view = QTableView()
view.setModel(model)

view.show()

sys.exit()

At first, I thought it's a SQL libs related problem, but after snipping most of the code it seems that the error appears in the first call to initialized app.

Ideas, anyone?
My extensions: lcdproc-server | lcdproc-client | darkiceWIP | icecast2WIP

Offline SvOlli

  • Full Member
  • ***
  • Posts: 193
  • Linux Developer
Re: Qt 4.8.1
« Reply #12 on: November 12, 2012, 02:46:36 PM »
"Illegal instruction" occurs then a code is compiled/optimized for a more advanced architecture than it's running on (e.g. running code compiled with optimization for i686 (like the "Core" architectures) but it's running on a i486. So the output of
Code: [Select]
cat /proc/cpuinfo would be helpful.

First you need to identify the code that causes this trouble. I'd start with running the code in gdb, once that error occurs it will reenter the gdb command-line mode, and type
Code: [Select]
bt there. With a bit of luck one can see the call-stack of the code that crashed, which can be hopefully used to identify the component in question.

Theoretically, it can be any starting with libc and end with the python vm itself, and any library used in between. Since most of the tcz have grown rather stable, I'd point first to the one less used. My first guess would be PyQt.

My tczs are compiled using the CFLAGS "-march=i486 -mtune=i686" , which generate code that runs on a i486 but will use i686 optimizations only when they are supported.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11623
Re: Qt 4.8.1
« Reply #13 on: November 12, 2012, 05:03:06 PM »
Hi SvOlli
Quote
"Illegal instruction" occurs then a code is compiled/optimized for a more advanced architecture than it's running on (e.g. running code compiled with optimization for i686 (like the "Core" architectures) but it's running on a i486.
That statement seems to suggest that Core is compiled for i686 and above. Core and its extensions are supposed
to be compiled just like your tczs (-march=i486 -mtune=i686) and be 486 compatible.

Offline Fazzah

  • Newbie
  • *
  • Posts: 20
Re: Qt 4.8.1
« Reply #14 on: November 12, 2012, 05:35:16 PM »
Thank you both, i'll check tomorrow at work and provide updates.

Oh, and Sv0lli, thanks for the PSQL plugin!

Another thing, now it's getting weird.

I made a fresh install of Core in Virtualbox at home. The same settings, the same extensions. And PyQt works...
So, since a VBox is i686, and my Via Epia on which I'm installing the problematic Core is i486, then one of the extensions is broken. I asked PyQt/sip maintainer about the compilation options, yet to hear an answer.

Meanwhile:

GDB shows that SIGILL is thrown from sip.so, so we have a suspect.

« Last Edit: November 13, 2012, 05:56:49 AM by Fazzah »
My extensions: lcdproc-server | lcdproc-client | darkiceWIP | icecast2WIP