Error while trying to create a static version of Qt
Page |
1 |
./configure worked
Now i’m trying to make, but i got this error about GTK.
- 1.
- 2.
- from kernel/qguiplatformplugin.cpp:63:
- 3.
- ../../include/QtGui/private/../../../src/gui/styles/qgtkstyle_p.h:69: fatal error: gtk/gtk.h: No such file or directory
- 4.
- compilation terminated.
- 5.
- make[1]: *** [.obj/release-static/qguiplatformplugin.o] Error 1
- 6.
- 7.
- make: *** [sub-gui-make_default-ordered] Error 2
22 replies
I’m using Linux Ubuntu.
I have Qt Creator installed, and i’m trying to follow this: http://doc.qt.nokia.com/4.5/deployment-x11.html tutorial to release a static linked version of my application.
The ./configure part went ok.
Then i’ve had the problem i’ve posted earlier, which i’ve solved it by putting the absolute path to gtk.h in that header.
Now, i have another problem.
- In file included from /usr/include/gtk-2.0/gdk/gdk.h:32,
- from /usr/include/gtk-2.0/gtk/gtk.h:32,
- from kernel/qguiplatformplugin.cpp:63:
- /usr/include/gtk-2.0/gdk/gdkapplaunchcontext.h:30: fatal error: gio/gio.h: No such file or directory
- compilation terminated.
- make[1]: *** [.obj/release-static/qguiplatformplugin.o] Error 1
- make: *** [sub-gui-make_default-ordered] Error 2
This gio.h thing …
And also to repeat just another time (and you didn’t answer the respective question):
If you compile Qt manually, then please do so with the stand alone framework sources (Qt download page [qt.nokia.com], go LGPL, Qt: Framework Only on the right side, the introductory paragraph has the links to a zip or a tar.gz).
Recompiling from the installed SDK is very known to cause problem, please avoid this!
And also to repeat just another time (and you didn’t answer the respective question):If you compile Qt manually, then please do so with the stand alone framework sources (Qt download page [qt.nokia.com], go LGPL, Qt: Framework Only on the right side, the introductory paragraph has the links to a zip or a tar.gz).
Recompiling from the installed SDK is very known to cause problem, please avoid this!
Hi Pufo, recompiling is typically not a major issue. However, you might want to follow Volker’s advice.
Yes ! It worked GREAT using Volker’s advice.
My binary is 14 MB and in ldd the Qt libraries aren’t listed anymore.
Another question:
What is the best choice to distribuite the software, now that i’ve compiled it?
Should i create a .deb pack ?
If i’ve compiled on my Ubuntu machine ( 2.6.35-22-generic ) someone with Slackware or another distribution would be able to run it ?
You must log in to post a reply. Not a member yet? Register here!




