Tue, 02/17/2009 - 21:52
Forums:
Does anyone have the tutorial code from the sample/tutorial directory running on linux? I finally learned enough about automake/autoconf to get it to compile, but now I get a lot of undefines for vtable & program-name::staticMetaObject. I think they are related but don't know how to proceed.
Wed, 02/18/2009 - 18:34
Gary,
staticMetaObject() is Qt related stuff. Make sure Qt is in your build path, that you have generated moc_*.cpp files and so forth. If you are totally unfamiliar with Qt you might want to read a little bit on it (see doc.trolltech.com).
If there is a .pro file accompanying the sample you rather need to use it to build the project.
Hope this helps a bit.
Roman
---
opencascade.blogspot.com - blog on Open CASCADE
Fri, 02/20/2009 - 02:09
Thanks for the help. I have the program compiled and linked. But the menus and icons are missing. There is a res file with icons but I have not found out how to tell the program how to find them. I ordered the book "C++ GUI Programming with Qt 4, Second Edition" from the trolltech site.
Fri, 02/20/2009 - 18:59
As a quick fix you can just copy the resource file to the folder the *.exe lies in.
Sun, 02/22/2009 - 23:37
Are you using qmake? IMO, it would be difficult to get autotools to work right with Qt.
Take a look at http://doc.trolltech.com/4.4/qmake-manual.html , and especially the tutorial linked from that page.
When you have a .pro file set up, just run qmake to generate the Makefile, and then make to compile.
HTH
Mark
Sat, 02/28/2009 - 03:21
I did get the tutorial program to run using qmake, but it has two problems. I found one using gdb debugger. It was a bad .png file used for an icon. But when the program exits there is an error about a double free or corrupted memory.
Mon, 03/02/2009 - 09:57
I sometimes had this kind of error after adding to the Qt project, too. A
make clean, qmake, make
in the project usually solved this.