<?xml version="1.0" encoding="iso-8859-1"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <!-- /tmp/qt-4.2.1-harald-1161357942206/qt-x11-opensource-src-4.2.1/doc/src/emb-install.qdoc --> <head> <title>Qt 4.2: Installing Qtopia Core</title> <link rel="contents" href="qtopiacore.html" /> <link href="classic.css" rel="stylesheet" type="text/css" /> </head> <body> <table border="0" cellpadding="0" cellspacing="0" width="100%"> <tr> <td align="left" valign="top" width="32"><a href="http://www.trolltech.com/products/qt"><img src="images/qt-logo.png" align="left" width="32" height="32" border="0" /></a></td> <td width="1"> </td><td class="postheader" valign="center"><a href="index.html"><font color="#004faf">Home</font></a> · <a href="classes.html"><font color="#004faf">All Classes</font></a> · <a href="mainclasses.html"><font color="#004faf">Main Classes</font></a> · <a href="groups.html"><font color="#004faf">Grouped Classes</font></a> · <a href="modules.html"><font color="#004faf">Modules</font></a> · <a href="functions.html"><font color="#004faf">Functions</font></a></td> <td align="right" valign="top" width="230"><a href="http://www.trolltech.com"><img src="images/trolltech-logo.png" align="right" width="203" height="32" border="0" /></a></td></tr></table><p> [<a href="qtopiacore.html">Qtopia Core</a>] </p> <h1 align="center">Installing Qtopia Core<br /><small></small></h1> <ul><li><a href="#step-1-installing-the-license-file-commercial-editions-only">Step 1: Installing the License File (commercial editions only)</a></li> <li><a href="#step-2-unpacking-the-archive">Step 2: Unpacking the Archive</a></li> <li><a href="#step-3-building-the-library">Step 3: Building the Library</a></li> <li><a href="#step-4-adjusting-the-environment-variables">Step 4: Adjusting the Environment Variables</a></li> <li><a href="#step-5-enabling-framebuffer-support">Step 5: Enabling Framebuffer Support</a></li> </ul> <p>Note that the installation procedure is written for Linux, and may need to be modified for other platforms.</p> <a name="step-1-installing-the-license-file-commercial-editions-only"></a> <h2>Step 1: Installing the License File (commercial editions only)</h2> <p>If you have the commercial edition of Qtopia Core, the first step is to install your license file as <tt>$HOME/.qt-license</tt>.</p> <p>For the open source version you do not need a license file.</p> <a name="step-2-unpacking-the-archive"></a> <h2>Step 2: Unpacking the Archive</h2> <p>First uncompress the archive in the preferred location, then unpack it:</p> <pre> cd <anywhere> gunzip qtopia-core-commercial-src-4.2.1.tar.gz tar xf qtopia-core-commercial-src-4.2.1.tar</pre> <p>This document assumes that the archive is unpacked in the following directory:</p> <pre> ~/qtopia-core-commercial-src-4.2.1</pre> <a name="step-3-building-the-library"></a> <h2>Step 3: Building the Library</h2> <p>Before building the Qtopia Core library, run the <tt>./configure</tt> script to configure the library for your deployment architecture.</p> <p>By default, Qtopia Core is configured for installation in the <tt>/usr/local/Trolltech/QtopiaCore-4.2.1</tt> directory, but this can be changed by using the <tt>-prefix</tt> option. Alternatively, the <tt>-prefix-install</tt> option can be used to specify a "local" installation within the source directory.</p> <pre> cd ~/qtopia-core-commercial-src-4.2.1 ./configure -embedded [architecture]</pre> <p>The configuration system is designed to allow platform-specific options to be added, typical architectures are x86 and arm. To get a list of all available options, type <tt>./configure -help</tt>. In general, all Linux systems which have framebuffer support can use the "linux-generic-g++" platform. The configuration system also supports cross-compilers. For example, to build on Linux/x86 for the Linux/MIPSEL target, pass <tt>mips</tt> as parameter to the <tt>configure</tt> script's <tt>-embedded</tt> option.</p> <p>To create the library and compile all the demos, examples, tools, and tutorials, type:</p> <pre> make</pre> <p>On some systems the <tt>make</tt> utility is called differently, e.g. <tt>gmake</tt>. The <tt>configure</tt> script tells you which make utility to use.</p> <p>If you did not configure Qtopia Core using the <tt>-prefix-install</tt> option, you need to install the library, demos, examples, tools, and tutorials in the appropriate place. To do this, type:</p> <pre> su -c "make install"</pre> <p>and enter the root password.</p> <p>Only a small number of configurations are predefined. You can create your own custom configuration by adding new files to the <tt>mkspecs/qws/</tt> directory, using existing similar configurations as a starting point.</p> <a name="step-4-adjusting-the-environment-variables"></a> <h2>Step 4: Adjusting the Environment Variables</h2> <p>In order to use Qtopia Core, the <tt>PATH</tt> variable must be extended to locate <tt>qmake</tt>, <tt>moc</tt> and other Qtopia Core tools, and the <tt>LD_LIBRARY_PATH</tt> must be extended for compilers that do not support <tt>rpath</tt>.</p> <p>To set the <tt>PATH</tt> variable, add the following lines to your <tt>.profile</tt> file if your shell is bash, ksh, zsh or sh:</p> <pre> PATH=/usr/local/Trolltech/QtopiaCore-4.2.1/bin:$PATH export PATH</pre> <p>In case your shell is csh or tcsh, add the following line to the <tt>.login</tt> file instead:</p> <pre> setenv PATH /usr/local/Trolltech/QtopiaCore-4.2.1/bin:$PATH</pre> <p>If you use a different shell, please modify your environment variables accordingly.</p> <p>For compilers that do not support <tt>rpath</tt> you must also extended the <tt>LD_LIBRARY_PATH</tt> environment variable to include <tt>/usr/local/Trolltech/QtopiaCore-4.2.1/lib</tt>. Note that on Linux with GCC, this step is not needed.</p> <a name="step-5-enabling-framebuffer-support"></a> <h2>Step 5: Enabling Framebuffer Support</h2> <p>Qtopia Core applications write directly to the framebuffer, eliminating the need for the X Window System and saving memory. The final step in the installation procedure is to enable the framebuffer support.</p> <p>For development and debugging, the Qtopia Core platform provides a virtual framebuffer as well as the option of running Qtopia Core as a VNC server. For a description of how to install the virtual framebuffer and how to use the VNC protocol, please consult the documentation at:</p> <ul> <li><a href="qtopiacore-qvfb.html">The Virtual Framebuffer</a></li> <li><a href="qtopiacore-vnc.html">The VNC Protocol</a></li> </ul> <p>Note that the virtual framebuffer requires a Qt/X11 installation. See <a href="install-x11.html">Installing Qt/X11</a> for details.</p> <p>No particular actions are required to enable the framebuffer on target devices: The Linux framebuffer is enabled by default on all modern Linux distributions. For information on older versions, see <a href="http://en.tldp.org/HOWTO/Framebuffer-HOWTO.html">http://en.tldp.org/HOWTO/Framebuffer-HOWTO.html</a>.</p> <p>To test that the Linux framebuffer is set up correctly, and that the device permissions are correct, use the program provided by the <a href="qtopiacore-testingframebuffer.html">Testing the Linux Framebuffer</a> document.</p> <p>That's all. Qtopia Core is now installed.</p> <p><table width="100%" align="center" cellpadding="2" cellspacing="1" border="0"> <tr valign="top" class="odd"><td><b>Customizing the Qtopia Core Library</b><p>When building embedded applications on low-powered devices, reducing the memory and CPU requirements is important.</p> <p>A number of options tuning the library's performance are available. But the most direct way of saving resources is to fine-tune the set of Qt features that is compiled. It is also possible to make use of accelerated graphics hardware.</p> <ul> <li><a href="qtopiacore-features.html">Fine-Tuning Features</a></li> <li><a href="qtopiacore-performance.html">Performance Tuning</a></li> <li><a href="qtopiacore-accel.html">Adding an Accelerated Graphics Driver</a></li> </ul> <p>In addition, it is possible to specify the <a href="qtopiacore-pointer.html">pointer handling</a> as well as the <a href="qtopiacore-charinput.html">character input</a> and <a href="qtopiacore-fonts.html">font formats</a>.</p> </td></tr> </table></p> <p> [<a href="qtopiacore.html">Qtopia Core</a>] </p> <p /><address><hr /><div align="center"> <table width="100%" cellspacing="0" border="0"><tr class="address"> <td width="30%">Copyright © 2006 <a href="trolltech.html">Trolltech</a></td> <td width="40%" align="center"><a href="trademarks.html">Trademarks</a></td> <td width="30%" align="right"><div align="right">Qt 4.2.1</div></td> </tr></table></div></address></body> </html>