Qt wiki will be updated on October 12th 2023 starting at 11:30 AM (EEST) and the maintenance will last around 2-3 hours. During the maintenance the site will be unavailable.

Build Qt For Linux: Difference between revisions

From Qt Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
[[Category:Developing with Qt::General]]<br />[[Category:HowTo]]<br />[[Category:Instructions]]
[[Category:Developing with Qt::General]]
[[Category:HowTo]]
[[Category:Instructions]]


'''English''' [[Build_Qt_For_Linux_Portuguese|Português]] [[Build_Qt_For_Linux_Russian|Русский]] [[Build_Qt_For_Linux_Japanese|日本語]] [[Build_Qt_For_Linux_Spanish|Spanish]] [[Build_Qt_For_Linux_Bulgarian|Български]]
'''English''' [[Build_Qt_For_Linux_Portuguese|Português]] [[Build_Qt_For_Linux_Russian|Русский]] [[Build_Qt_For_Linux_Japanese|日本語]] [[Build_Qt_For_Linux_Spanish|Spanish]] [[Build_Qt_For_Linux_Bulgarian|Български]]
Line 7: Line 9:
Qt is a very large framework, and it has many modules, configuration switches, and optional features. Faced with building it from source, it can be a challenge to figure out how to install the dependencies you need, and how to get some of the more obscure features to build!
Qt is a very large framework, and it has many modules, configuration switches, and optional features. Faced with building it from source, it can be a challenge to figure out how to install the dependencies you need, and how to get some of the more obscure features to build!


The features that you can consider as a &quot;standard minimum configuration&amp;quot; on Linux are: ZLib, JPEG, TIFF, MNG, PNG, OpenGL, GStreamer, ALSA, FreeType, FontConfig, CUPS, D-Bus, X*, OpenSSL, and SQLite.
The features that you can consider as a "standard minimum configuration" on Linux are: ZLib, JPEG, TIFF, MNG, PNG, OpenGL, GStreamer, ALSA, FreeType, FontConfig, CUPS, D-Bus, X*, OpenSSL, and SQLite.


Following is a comprehensive list of package names for the dependencies for all versions of Qt between 4.5 and trunk as of December 2010. Presently only Ubuntu package names have been included, but more distros should follow as the package names are figured out.
Following is a comprehensive list of package names for the dependencies for all versions of Qt between 4.5 and trunk as of December 2010. Presently only Ubuntu package names have been included, but more distros should follow as the package names are figured out.


The &quot;Module&amp;quot; column indicates the lowest-level module which uses the feature (i.e., if QtCore uses the feature, QtGui will not be listed). Multiple modules are only listed if they are not interdependent.
The "Module" column indicates the lowest-level module which uses the feature (i.e., if QtCore uses the feature, QtGui will not be listed). Multiple modules are only listed if they are not interdependent.


{|
{|
Line 121: Line 123:
|&amp;#8209;egl, &amp;#8209;opengl&amp;amp;nbsp;es[1&amp;amp;#124;1cl&amp;amp;#124;2]
|&amp;#8209;egl, &amp;#8209;opengl&amp;amp;nbsp;es[1&amp;amp;#124;1cl&amp;amp;#124;2]
|X
|X
|X<ref>Need to pass &amp;#8209;DMESA_EGL_NO_X11_HEADERS to &quot;configure&amp;quot; when building Qt/Embedded. Possibly this could be done via .qmake.cache?
|X<ref>Need to pass &amp;#8209;DMESA_EGL_NO_X11_HEADERS to "configure" when building Qt/Embedded. Possibly this could be done via .qmake.cache?
</ref>
</ref>
|X
|X
Line 158: Line 160:
|X
|X
|-
|-
|GStreamer<ref>Need to pass &quot;$(pkg&amp;amp;#8209;config gstreamer&amp;amp;#8209;interfaces&amp;amp;#8209;0.10 gstreamer&amp;amp;#8209;video&amp;amp;#8209;0.10 gstreamer&amp;amp;#8209;base&amp;amp;#8209;0.10 &amp;#8209;&amp;#8209;cflags&amp;amp;#8209;only&amp;amp;#8209;I)&quot; to &quot;configure&amp;quot;.
|GStreamer<ref>Need to pass "$(pkg&amp;amp;#8209;config gstreamer&amp;amp;#8209;interfaces&amp;amp;#8209;0.10 gstreamer&amp;amp;#8209;video&amp;amp;#8209;0.10 gstreamer&amp;amp;#8209;base&amp;amp;#8209;0.10 &amp;#8209;&amp;#8209;cflags&amp;amp;#8209;only&amp;amp;#8209;I)" to "configure".
</ref>
</ref>
|Phonon
|Phonon

Revision as of 08:59, 25 February 2015


English Português Русский 日本語 Spanish Български

Build Qt for Linux

Qt is a very large framework, and it has many modules, configuration switches, and optional features. Faced with building it from source, it can be a challenge to figure out how to install the dependencies you need, and how to get some of the more obscure features to build!

The features that you can consider as a "standard minimum configuration" on Linux are: ZLib, JPEG, TIFF, MNG, PNG, OpenGL, GStreamer, ALSA, FreeType, FontConfig, CUPS, D-Bus, X*, OpenSSL, and SQLite.

Following is a comprehensive list of package names for the dependencies for all versions of Qt between 4.5 and trunk as of December 2010. Presently only Ubuntu package names have been included, but more distros should follow as the package names are figured out.

The "Module" column indicates the lowest-level module which uses the feature (i.e., if QtCore uses the feature, QtGui will not be listed). Multiple modules are only listed if they are not interdependent.

Dependency Module Configure switch Qt/X11? Qt/Embedded? Qt 4.5 Qt 4.6 Qt 4.7 Qt 4.8 (trunk)
ZLib QtCore &#8209;[qt&amp;#124;system]&#8209;zlib X X X X X X
JPEG QtCore &#8209;[qt&amp;#124;system]&#8209;libjpeg X X X X X X
TIFF QtCore &#8209;[qt&amp;#124;system]&#8209;libtiff X X X X X X
MNG QtCore &#8209;[qt&amp;#124;system]&#8209;libmng X X X X X X
PNG QtCore &#8209;[qt&amp;#124;system]&#8209;libpng X X X X X X
OpenGL QtOpenGL &#8209;opengl X X X X X
OpenGL ES 1 QtOpenGL &#8209;opengl&amp;nbsp;es1 X X X[1] X X X
OpenGL ES 1 CL QtOpenGL &#8209;opengl&amp;nbsp;es1cl X X X[2] X X X
OpenGL ES 2 QtOpenGL &#8209;opengl&amp;nbsp;es2 X X X[3] X X X
EGL QtOpenGL &#8209;egl, &#8209;opengl&amp;nbsp;es[1&amp;#124;1cl&amp;#124;2] X X[4] X X X X
OpenVG QtOpenVG &#8209;openvg X X X X X
ShivaVG QtOpenVG &#8209;openvg X X X X X
DirectFB QtGui &#8209;[qt&amp;#124;plugin]&#8209;gfx&amp;#8209;directfb X X X X X
GStreamer[5] Phonon &#8209;phonon X X X X X X
PulseAudio Phonon &#8209;phonon&amp;#8209;backend X X X X X
ALSA QtMultimedia &#8209;multimedia X X X X X
NAS Sound QtGui &#8209;system&amp;#8209;nas&amp;#8209;sound X X X X X
FreeType QtGui &#8209;freetype X X X X X X
FontConfig QtGui &#8209;fontconfig X X X X X
tslib QtGui &#8209;[qt&amp;#124;plugin]&#8209;mouse&amp;#8209;tslib X X X X X
Cups QtGui &#8209;cups X X X X X X
D&amp;#8209;Bus QtDBus &#8209;dbus[&#8209;linked] X X X X X X
ICD QtNetwork &#8209;icd X X X X
GLib QtCore &#8209;glib X X X X X X
GTK QtGui &#8209;gtkstyle X X X X X
X11 QtGui none X X X X X
XShape QtGui &#8209;xshape X X X X X
XCursor QtGui &#8209;xcursor X X X X X
XFixes QtGui &#8209;xfixes X X X X X
XRandr QtGui &#8209;xrandr X X X X X
XRender QtGui, QtWebKit &#8209;xrender X X X X X
XVideo Phonon, QtMultimedia &#8209;xvideo X X X X X
Xinerama QtGui &#8209;xinerama X X X X X
XInput QtGui &#8209;xinput X X X X X
Session management QtGui &#8209;sm X X X X X
OpenSSL QtNetwork, QtWebKit &#8209;openssl[&#8209;linked] X X X X X X
Interbase QtSql &#8209;[qt&amp;#124;plugin]&#8209;sql&amp;#8209;ibase X X X X X X
MySQL QtSql &#8209;[qt&amp;#124;plugin]&#8209;sql&amp;#8209;mysql X X X X X X
ODBC QtSql &#8209;[qt&amp;#124;plugin]&#8209;sql&amp;#8209;odbc X X X X X X
PostgreSQL QtSql &#8209;[qt&amp;#124;plugin]&#8209;sql&amp;#8209;psql X X X X X X
SQLite 2 QtSql &#8209;[qt&amp;#124;plugin]&#8209;sql&amp;#8209;sqlite2 X X X X X X
SQLite 3 QtSql &#8209;[qt&amp;#124;plugin]&#8209;sql&amp;#8209;sqlite X X X X X X
TDS QtSql &#8209;[qt&amp;#124;plugin]&#8209;sql&amp;#8209;tds X X X X X X
Dependency Ubuntu Lucid Ubuntu Maverick
ZLib zlib1g&amp;#8209;dev zlib1g&amp;#8209;dev
JPEG libjpeg62&amp;#8209;dev libjpeg62&amp;#8209;dev
TIFF libtiff4&amp;#8209;dev libtiff4&amp;#8209;dev
MNG libmng&amp;#8209;dev libmng&amp;#8209;dev
PNG libpng12&amp;#8209;dev libpng12&amp;#8209;dev
OpenGL mesa&amp;#8209;common&amp;#8209;dev, libglu1&amp;#8209;mesa&amp;#8209;dev mesa&amp;#8209;common&amp;#8209;dev, libglu1&amp;#8209;mesa&amp;#8209;dev
OpenGL ES 1 none libgles1&amp;#8209;mesa&amp;#8209;dev[6]
OpenGL ES 1 CL none libgles1&amp;#8209;mesa&amp;#8209;dev
OpenGL ES 2 none libgles2&amp;#8209;mesa&amp;#8209;dev
EGL none libgles2&amp;#8209;mesa&amp;#8209;dev or libegl1&amp;#8209;mesa&amp;#8209;dev
OpenVG none libopenvg1&amp;#8209;mesa&amp;#8209;dev
ShivaVG none none
DirectFB libdirectfb&amp;#8209;dev libdirectfb&amp;#8209;dev
GStreamer libgstreamer0.10&amp;#8209;dev, libgstreamer&amp;#8209;plugins&amp;#8209;base0.10&amp;#8209;dev libgstreamer0.10&amp;#8209;dev, libgstreamer&amp;#8209;plugins&amp;#8209;base0.10&amp;#8209;dev
PulseAudio libpulse&amp;#8209;dev libpulse&amp;#8209;dev
NAS Sound libaudio&amp;#8209;dev libaudio&amp;#8209;dev
ALSA libasound2&amp;#8209;dev libasound2&amp;#8209;dev
FreeType libfreetype6&amp;#8209;dev libfreetype6&amp;#8209;dev
FontConfig libfontconfig1&amp;#8209;dev libfontconfig1&amp;#8209;dev
tslib libts&amp;#8209;dev libts&amp;#8209;dev
Cups libcups2&amp;#8209;dev libcups2&amp;#8209;dev
D&amp;#8209;Bus libdbus&amp;#8209;1&amp;#8209;dev libdbus&amp;#8209;1&amp;#8209;dev
ICD none none
GLib libglib2.0&amp;#8209;dev libglib2.0&amp;#8209;dev
GTK libgtk2.0&amp;#8209;dev libgtk2.0&amp;#8209;dev
X11 libx11&amp;#8209;dev, libxext&amp;#8209;dev libx11&amp;#8209;dev, libxext&amp;#8209;dev
XCursor libxcursor&amp;#8209;dev libxcursor&amp;#8209;dev
XFixes libxfixes&amp;#8209;dev libxfixes&amp;#8209;dev
XRandr libxrandr&amp;#8209;dev libxrandr&amp;#8209;dev
XRender libxrender&amp;#8209;dev libxrender&amp;#8209;dev
XVideo libxv&amp;#8209;dev libxv&amp;#8209;dev
Xinerama libxinerama&amp;#8209;dev libxinerama&amp;#8209;dev
XInput libxi&amp;#8209;dev libxi&amp;#8209;dev
Session management libsm&amp;#8209;dev libsm&amp;#8209;dev
OpenSSL libssl&amp;#8209;dev libssl&amp;#8209;dev
Interbase firebird2.1&amp;#8209;dev firebird2.5&amp;#8209;dev or firebird2.1&amp;#8209;dev
MySQL libmysqlclient&amp;#8209;dev libmysqlclient&amp;#8209;dev
ODBC unixodbc&amp;#8209;dev or libiodbc2&amp;#8209;dev[7] unixodbc&amp;#8209;dev or libiodbc2&amp;#8209;dev[8]
PostgreSQL libpq&amp;#8209;dev libpq&amp;#8209;dev
SQLite 2 libsqlite0&amp;#8209;dev libsqlite0&amp;#8209;dev
SQLite 3 libsqlite3&amp;#8209;dev libsqlite3&amp;#8209;dev
TDS freetds&amp;#8209;dev[6] freetds&amp;#8209;dev[6]
  1. Though supported, I have not been able to figure out how to buid this option in Qt 4.5.
  2. Though supported, I have not been able to figure out how to buid this option in Qt 4.5.
  3. Though supported, I have not been able to figure out how to buid this option in Qt 4.5.
  4. Need to pass &#8209;DMESA_EGL_NO_X11_HEADERS to "configure" when building Qt/Embedded. Possibly this could be done via .qmake.cache?
  5. Need to pass "$(pkg&amp;#8209;config gstreamer&amp;#8209;interfaces&amp;#8209;0.10 gstreamer&amp;#8209;video&amp;#8209;0.10 gstreamer&amp;#8209;base&amp;#8209;0.10 &#8209;&#8209;cflags&amp;#8209;only&amp;#8209;I)" to "configure".
  6. This also requires a provider of libGLES_CM.so.
  7. Using libiodbc2 instead of unixodbc is supported starting in Qt 4.6.
  8. Using libiodbc2 instead of unixodbc is supported starting in Qt 4.6.