Results 1 to 3 of 3

Thread: Qt Static Compile Error on Linux - Missing gtk.h file

  1. #1
    Join Date
    Feb 2011
    Posts
    1
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Qt Static Compile Error on Linux - Missing gtk.h file

    Hi,
    This is my first attempt at working with Qt and I need to make static executables. I'm working with Qt 4.70 on Ubuntu 10.04. I'm following the instructions on how to build Qt statically at http://doc.qt.nokia.com/4.5/deployment-x11.html

    I do the following:

    cd /opt/qtsdk-2010.05/qt
    ./configure -static -prefix /opt/qtsdk-2010.05/qt
    make sub-src

    After the make command I get an error that some gtk related files can't be found:
    ...
    In file included from ../../include/QtGui/private/qgtkstyle_p.h:1, from kernel/qguiplatformplugin.cpp:63: and how to install it
    ../../include/QtGui/private/../../../src/gui/styles/qgtkstyle_p.h:69:21: error: gtk/gtk.h: No such file or directory

    I'm guessing there is a GTK package that needs to be installed. Can someone point me to what's the package name? (assuming this is the problem of course)

    Also, I tried issuing the 'configure' command with the '-no-gtkstyle' prior to issuing the make command. I got the same results.

  2. #2
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Qt Static Compile Error on Linux - Missing gtk.h file

    The package is probably libgtk2.0-dev or something similar.

  3. #3
    Join Date
    Feb 2011
    Posts
    2
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Qt Static Compile Error on Linux - Missing gtk.h file

    hi!
    I've got (sadly) the same problem, eaven after whole day googling for solution.
    I'm using newest x64 ubuntu, and yes I've got installed gtk libraries.
    Thanks in advance for any help!

    P.S. i've found this header file (gtk.h) in my usr/include/gtk-2.0/gtk folder but that error still ocurs. How may i telll QT to look for headers there?

Similar Threads

  1. Static application missing pcap functionality
    By remy06 in forum Installation and Deployment
    Replies: 3
    Last Post: 21st May 2012, 18:33
  2. Problem with missing signals after static compiling of QT
    By LuckyBlade in forum Qt Programming
    Replies: 0
    Last Post: 28th January 2011, 20:12
  3. cannot compile QT 4.6 as static - uic3 error stops compilation
    By rucs_hack in forum Installation and Deployment
    Replies: 3
    Last Post: 27th June 2010, 05:35
  4. Replies: 0
    Last Post: 10th February 2010, 07:07
  5. Static Compile [Qt4]
    By PieaholicX in forum Newbie
    Replies: 11
    Last Post: 1st September 2006, 17:18

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.