Howto compile Qt and friends on Debian Squeeze: Difference between revisions
No edit summary |
(nominate for deletion) |
||
(6 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
= | {{Delete|reason=Outdated content.}} | ||
{{Cleanup | reason=Auto-imported from ExpressionEngine.}} | |||
[[Category:Delete]] | |||
= How to compile Qt and friends on Debian Squeeze = | |||
== 1) Debian installation == | |||
==2) This is what I did to install Qt:== | I downloaded the Debian-life dvd from the Debian website : | ||
[http://live.debian.net/project/releases/ Link ] 6.0.1: 2011-03-24 | |||
Then I booted using the life-DVD. Debian detected all the necessary drivers for my graphics card. | |||
Then I restarted and used the graphical install to install my new Linux box. | |||
I used [http://www.nongnu.org/synaptic/ synaptic] to update some packages. | |||
== 2) This is what I did to install Qt: == | |||
(I used root privileges in console with : su ) | (I used root privileges in console with : su ) | ||
I installed the latest Qt release Debian-package which will provide all the dependencies you need and settings to look into. | I installed the latest Qt release Debian-package which will provide all the dependencies you need and settings to look into. | ||
I looked into the qconfig.pro file in the mkspecs folder to check the configure options used to build the package on Debian. | |||
You don't need to install this package but it helped me to figure things out. | |||
Get all dependencies for Qt :< | Get all dependencies for Qt : | ||
<code>apt-get build-dep qt4-qmake<code> | |||
Get git:< | Get git: | ||
</code>apt-get install git-core</code> | |||
Get Git clone:< | Get Git clone: | ||
<code>git clone git://gitorious.org/qt/qt.git | |||
cd qt</code> | |||
I preferred to install in my own directory == /home/USER : | I preferred to install in my own directory == /home/USER : | ||
Configure + make + install< | Configure + make + install | ||
<code>./configure -prefix /home/USER/qtsdk | |||
-debug-and-release | |||
-qt3support | |||
-accessibility | |||
-opengl | |||
-qt-lib-jpeg | |||
-qt-lib-mng | |||
-qt-lib-png | |||
-qt-lib-tiff | |||
-system-freetype | |||
-system-zlib | |||
-nis | |||
-cups | |||
-iconv | |||
-glib | |||
-dbus | |||
-dbus-linked | |||
‑system‑nas‑sound | |||
-openssl | |||
-xshape | |||
-xsync | |||
-xrender | |||
-mitshm | |||
-fontconfig | |||
-xkb | |||
‑multimedia | |||
-xmlpatterns | |||
-multimedia | |||
-audio-backend | |||
-svg -webkit | |||
-script | |||
-scripttools | |||
-qt-sql‑psql | |||
-qt-sql‑mysql | |||
-qt-sql‑odbc | |||
make</code> | |||
I | I choose to install several database drivers (postgresql, mysql and odbc), which are not needed for everyone. [http://www.sqlite.org/ SQLite] is installed by default. | ||
Then I tested my installation and even qtdemo is up and running. Nice | I needed to compile the examples and demos separately because I've chosen my own directory to install in: | ||
<code>make install<code> | |||
Then I tested my installation and even qtdemo is up and running. Nice[[Image:|Image:]] | |||
'''Set the Environment Variables''' | '''Set the Environment Variables''' | ||
In order to use Qt, some environment variables need to be extended. | In order to use Qt, some environment variables need to be extended. | ||
PATH- to locate qmake, moc and other Qt tools | |||
This is done like this: | |||
In .profile (if your shell is bash, ksh, zsh or sh), add the following lines: | |||
</code>PATH=/home/USER/qtsdk/bin:$PATH | |||
export PATH<code> | |||
= | test it with: | ||
</code>which qmake</code> | |||
This should point to /home/USER/qtsdk/bin | |||
Hint : not a "/" at the end like in PATH=/home/USER/qtsdk/bin:$PATH | |||
That's all. Qt is now installed. | |||
== | == 3) But where is Qt Creator? == | ||
Gitorious tells me it's a separate repository, so obviously I have to install it separately : | |||
<code>git clone git://gitorious.org/qt-creator/qt-creator<code> | |||
It is recommended that you build Qt Creator not in the source directory, but in a | |||
separate directory. To do that, use the following commands: | |||
</code>mkdir $BUILD_DIRECTORY | |||
cd $BUILD_DIRECTORY | |||
qmake $SOURCE_DIRECTORY/qtcreator.pro | |||
make <code> |
Latest revision as of 20:05, 9 February 2018
This article is nominated for deletion. Reason: Outdated content. Please raise your support/opposition to this nomination in the article's discussion page. |
This article may require cleanup to meet the Qt Wiki's quality standards. Reason: Auto-imported from ExpressionEngine. Please improve this article if you can. Remove the {{cleanup}} tag and add this page to Updated pages list after it's clean. |
How to compile Qt and friends on Debian Squeeze
1) Debian installation
I downloaded the Debian-life dvd from the Debian website : Link 6.0.1: 2011-03-24
Then I booted using the life-DVD. Debian detected all the necessary drivers for my graphics card. Then I restarted and used the graphical install to install my new Linux box. I used synaptic to update some packages.
2) This is what I did to install Qt:
(I used root privileges in console with : su )
I installed the latest Qt release Debian-package which will provide all the dependencies you need and settings to look into. I looked into the qconfig.pro file in the mkspecs folder to check the configure options used to build the package on Debian. You don't need to install this package but it helped me to figure things out.
Get all dependencies for Qt :
apt-get build-dep qt4-qmake<code>
Get git:
apt-get install git-core
Get Git clone:
git clone git://gitorious.org/qt/qt.git
cd qt
I preferred to install in my own directory == /home/USER :
Configure + make + install
./configure -prefix /home/USER/qtsdk
-debug-and-release
-qt3support
-accessibility
-opengl
-qt-lib-jpeg
-qt-lib-mng
-qt-lib-png
-qt-lib-tiff
-system-freetype
-system-zlib
-nis
-cups
-iconv
-glib
-dbus
-dbus-linked
‑system‑nas‑sound
-openssl
-xshape
-xsync
-xrender
-mitshm
-fontconfig
-xkb
‑multimedia
-xmlpatterns
-multimedia
-audio-backend
-svg -webkit
-script
-scripttools
-qt-sql‑psql
-qt-sql‑mysql
-qt-sql‑odbc
make
I choose to install several database drivers (postgresql, mysql and odbc), which are not needed for everyone. SQLite is installed by default.
I needed to compile the examples and demos separately because I've chosen my own directory to install in:
make install<code>
Then I tested my installation and even qtdemo is up and running. Nice[[Image:|Image:]]
'''Set the Environment Variables'''
In order to use Qt, some environment variables need to be extended.
PATH- to locate qmake, moc and other Qt tools
This is done like this:
In .profile (if your shell is bash, ksh, zsh or sh), add the following lines:
PATH=/home/USER/qtsdk/bin:$PATH export PATH
test it with:
which qmake
This should point to /home/USER/qtsdk/bin Hint : not a "/" at the end like in PATH=/home/USER/qtsdk/bin:$PATH
That's all. Qt is now installed.
3) But where is Qt Creator?
Gitorious tells me it's a separate repository, so obviously I have to install it separately :
git clone git://gitorious.org/qt-creator/qt-creator<code>
It is recommended that you build Qt Creator not in the source directory, but in a
separate directory. To do that, use the following commands:
mkdir $BUILD_DIRECTORY
cd $BUILD_DIRECTORY
qmake $SOURCE_DIRECTORY/qtcreator.pro
make