This is an old revision of the document!
= Other Qt Pages =
= Compiling Qt under (k)ubuntu =
<source lang=“bash”> ./configure -no-phonon -no-webkit -no-opengl -openssl </source>
<source lang=“bash”> (g)make install sudo (g)make install </source>
If you only want the Qt libraries, and none of the tools or examples, you can save time by using the following command lines <source lang=“bash”> ./configure -no-phonon -no-webkit -no-opengl -openssl -nomake examples -nomake demos (g)make sudo (g)make install </source>
= Compiling Qt under Windows/Visual Studio =
<source lang=“bash”> OPENSSL_PATH = C:\build\openssl-0.9.8g PATH += C:\build\qt-win-opensource-src-4.4.0\bin QMAKESPEC = win32-msvc2005 </source>
<source lang=“bash”> C:\Program Files\Microsoft DirectX SDK (November 2007)\Utilities\Bin\dx_setenv.cmd </source>
<source lang=“bash”> cd c:\build\qt-win-opensource-src-4.4.0\ configure.exe -debug-and-release -phonon -webkit -direct3d -openssl -I C:\build\Include -L C:\build\Lib </source>
Check the beginning of the output of configure, and ensure all selected options have been correctly enabled)
<source lang=“bash”> nmake </source>
<source lang=“text”> ; Qt Integration QObject =classname=<staticMetaObject.d.stringdata,s> superclassname=<staticMetaObject.d.superdata→d.stringdata,s> QList<*>=size=<d→end,i> QLinkedList<*>=size=<d→end,i> QString=<d→data,su> size=<d→size,u> QByteArray=<d→data,s> size=<d→size,u> QUrl =<d→encodedOriginal.d→data,s> QUrlInfo =<d→name.d→data,su> QPoint =x=<xp> y=<yp> QPointF =x=<xp> y=<yp> QRect =x1=<x1> y1=<y1> x2=<x2> y2=<y2> QRectF =x=<xp> y=<yp> w=<w> h=<h> QSize =width=<wd> height=<ht> QSizeF =width=<wd> height=<ht> QMap<*> =size=<d→size> QVector<*> =size=<d→size> QHash<*> =size=<d→size> QVarLengthArray<*> =size=<s> data=<ptr> QFont =family=<d→request.family.d→data,su> size=<d→request.pointSize, f> QDomNode =name=<impl→name.d→data,su> value=<impl→value.d→data,su> </source>
= Making a project with qmake =
<source lang=“bash”> qmake -project -t app -o projectname.pro </source> (In the current version of qmake, the template does not always get correctly applied, it can be fixed with the template below).
<source lang=“text”>
TEMPLATE = app
TARGET = myproject DEPENDPATH += .
QT += network
CONFIG += warn_on thread CONFIG -= embed_manifest_exe
win32:CONFIG += console
HEADERS += main.h SOURCES += main.cpp </source>
Once the .pro file is made, and indeed every time it is changed, use the following commandline to generate the Visual Studio project files <source lang=“bash”> qmake -tp vc </source>
The project can then be opened in visual studio and compiled as ususal