| Version 23 (modified by mveljko78, 2 years ago) (diff) |
|---|
Common requirements
In order to build QuteCom, you need to install several components:
- A C++ compiler
- CMake >= 2.4.4.
- Qt >= 4.2 with support for STL, exceptions and RTTI.
- Boost >= 1.33 with support for:
- unit tests
- threading
- serialization
- program options
- signals
- date time
- GLib >= 2.10.3
There are also some platform specific requirements listed below.
Specific requirements for GNU/Linux
The default compiler is gcc 4.0.
GCC 4.1 and Boost 1.33.x do not play nicely together, so if your version of Boost is 1.33.x you should not use GCC 4.1. See this mailing list post http://dev.openwengo.com/pipermail/wengophone-devel/2006-December/004731.html for more information. If GCC 4.0 is not available on your distro, you can use GCC 3.4.
Other components:
- OpenSSL >= 0.9.8a
- GNU TLS >= 1.2.9
- uuid >= 1.38, from the e2fsprogs project.
- libxml2 >= 2.6.24
- Speex >= 1.1.12 (i)
- libavcodec >= cvs20060823, from the FFmpeg project. (i)
- PortAudio >= 19 (i)
- ALSA >= 1.0.11
- libsndfile >= 1.0.12
- libsamplerate >= 0.1.2
- libcurl >= 7.16.1 (i)
- libosip >= 3.0.1 (i)
(i) We provide internal copies of the source code for these libraries if you don't have them on your system.
Note that these version numbers are version we know works correctly. If you build and run QuteCom successfully with an older version, please let us know.
Notes for Ubuntu Natty
To build QuteCom from a stock Ubuntu Natty install, I needed to install the following packages:
sudo apt-get install mercurial libboost-dev libboost-thread-dev libboost-serialization-dev \
libboost-program-options-dev libboost-date-time-dev libboost-signals-dev \
libsamplerate0-dev libasound2-dev libxss-dev libcurl4-openssl-dev \
libavcodec-dev libavformat-dev libavutil-dev libswscale-dev libx264-dev \
libsndfile1-dev libspeex-dev libv4l-dev
hg clone http://hg.qutecom.org/qutecom-3.0
cd qutecom-3.0/build
cmake -DCMAKE_BUILD_TYPE=Debug ..
make
The libraries up to libx264 were required to get cmake to complete, and libsndfile, libspeex and libv4l were required during compile time.
I also had some compile time errors which required some small changes:
- The header file linux/videodev.h is no longer present in the kernel headers in version 2.6.38. I made the following (hacky) change to engine/verona/mediastreamer2/src/msv4l.c to get around the problem in the meantime:
--- a/src/msv4l.c Mon Mar 14 14:51:06 2011 +0100 +++ b/src/msv4l.c Thu Mar 17 19:26:50 2011 +0100 @@ -30,7 +30,7 @@ #include <string.h> #include <sys/mman.h> -#include <linux/videodev.h> +#include <libv4l1.h> #ifdef HAVE_LINUX_VIDEODEV2_H #include <linux/videodev2.h> #endif @@ -52,6 +52,14 @@ #define VIDIOSFPS _IOW('v',BASE_VIDIOCPRIVATE+20, int) #endif +#ifndef VIDEO_MAX_FRAME +#define VIDEO_MAX_FRAME 32 +#endif + +#ifndef BASE_VIDIOCPRIVATE +#define BASE_VIDIOCPRIVATE 192 +#endif + typedef struct V4lState{ int fd; ms_thread_t thread; - qutecom didn't link at the end, because of a missing symbol from libsndfile. I needed this patch to fix the build, but apparently the libsndfile dependency will soon be removed:
--- qutecom-3.0/libs/sound/CMakeLists.txt 2011-03-12 14:02:57.000000000 +0200 +++ qutecom-3.0/libs/sound/CMakeLists.txt 2011-03-14 21:07:28.000000000 +0200 @@ -1,5 +1,9 @@ ow_create_static_library(owsound) +ow_add_private_libraries( + sndfile +) + ow_use_public_libraries( owthread )
Specific requirements for MacOS X
GLib and GNU TLS can be installed using Fink or MacPorts.
Specific requirements for Windows
For Windows, dlls for most dependencies are included in Subversion, so you don't need to install them manually.
There is a Windows installer for Boost libraries here
For installer you need NSIS http://nsis.sf.net (installation to default directory)
You can use either Visual C++ or MinGW to build QuteCom.
Optional
QuteCom CoipManager can produce python bindings. It requires SIP and PyQt libraries.
Sip >= 4.7.6
PyQt >= 4.4.2
using Visual C++ compiler
The most mature compiler supported is Visual C++ 2003 (version 7.1).
Visual C++ 2005 (version 8.0) is supported as well.
Visual Studio 2008 hasn't been tested yet.
Qt 4.x Open Source Edition supports only MinGW. This patch http://sourceforge.net/project/showfiles.php?group_id=49109&package_id=165202 contributed by the Qt/Win? project, adds support for Visual C++. For Qt 4.4 or upper version, it's necessary to compile Qt sources. Just follow INSTALL instructions included in Qt sources.
Microsoft Platform SDK for Windows Server 2003 R2 headers and libraries are required. You can download from a web installer or fully do it from microsoft site.
Microsoft DirectX SDK headers are required. Microsoft makes a release each month of his SDK. Build has been done with Microsoft DirectX SDK August 2007 and fully succeed on our set test. Previous link is a direct download of DirectX SDK August 2007.
using MinGW compiler
MinGW 5.2 can now be used to build the whole software. Please feel free to raise any issue you may have with MinGW on the qutecom-deve mailing list. When using MinGW, you must install the Python Win32 extensions.
Building
First, you need to configure compilation, using CMake. Go inside the build dir, then make sure the Qt4 version of the qmake binary is in your path.
OWBuild
- OWBuild short introduction: OWBuildIntro
- OWBuild reference documentation: OWBuild
Windows
===Dependencies===
QuteCom build depends on several libraries, compilers and external programs. You can download them from : http://wima.co.uk/qutecom-deps/
Environment variables
Environment variables must be set before performing any build. The best way is to create settings.bat file , for example like this:
@SET QTDIR=C:\qt-4.5.3 @SET INCLUDE=%INCLUDE%;C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include @SET INCLUDE=%INCLUDE%;C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include\atl @SET INCLUDE=%INCLUDE%;C:\Program Files\Microsoft DirectX SDK (August 2007)\Include @SET LIB=%LIB%;C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Lib @SET PATH=%PATH%;C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Bin @SET PATH=%PATH%;C:\qt-4.5.3\bin @SET PATH=%PATH%;C:\Program Files\Microsoft Visual Studio 8\VC\bin\ @SET PATH=%PATH%;C:\Program Files\NSIS @SET PATH=%PATH%;C:\Program Files\NSIS\bin @SET BOOSTLIBDIR=C:\Program Files\boost\boost_1_38\lib @SET BOOSTINCLUDEDIR=C:\Program Files\boost\boost_1_38 @"C:\Program Files\Microsoft Visual Studio 8\Common7\Tools\vsvars32.bat"
Build based on Makefile
In order to build successfully it is necessary to use cloned hg repository
Build with Visual C++
cd qutecom-2.2
cd build
cmake .. -DCMAKE_BUILD_TYPE=Debug -G "NMake Makefiles"
nmake
To build the installer run: % nmake install
with MinGW
cmake -DCMAKE_BUILD_TYPE=Debug -G "MinGW Makefiles" ..
make
More detailed instruction can be found here: HowToBuildFromSource-Windows-MinGW
Note: If python bindings are enabled, SIP and PyQt libraries must be compiled and installed. Follow installation instructions from SIP and PyQt documentation.
Linux
GNU/Linux
cd /path/to/qutecom/build
cmake -DCMAKE_BUILD_TYPE=Debug /path/to/qutecom or ./build_make.sh
make
Fedora
specific commands to install libraries on Fedora: FedoraPlatformSupport
MacOS X
mkdir /path/to/qutecom/builddir
cd /path/to/qutecom/builddir
cmake -DCMAKE_BUILD_TYPE=Debug /path/to/qutecom
make
CMake
CMake standard options
Here is a list of the most interesting options provided out of the box by CMake.
- CMAKE_BUILD_TYPE: The type of build (can be Debug Release MinSizeRel RelWithDebInfo)
- CMAKE_INSTALL_PREFIX: The prefix to use when running make install (Default to /usr/local on GNU/Linux and MacOS X)
- CMAKE_C_COMPILER: The path to the C compiler
- CMAKE_CXX_COMPILER: The path to the C++ compiler
CMake options defined for QuteCom
QuteCom CMake options are defined in three files:
- DefineWengoOptions.cmake: QuteCom options
- libs/3rdparty/CMakeLists.txt: Whether to use internal or system versions of libraries
- libs/3rdparty/portaudio/CMakeLists.txt: PortAudio options
Here is a short description of the most useful ones:
- COPY_DATA_FILES_ON_CONFIGURE: Whether you want CMake to copy data files to the build dir when running
- GNU/Linux options:
- ENABLE_CRASHREPORT: If ON (the default), intercept crashes and provide a graphical interface to report information to QuteCom on crash. If OFF, just quit and dump core.
- Windows options:
- OWSOUND_PORTAUDIO_SUPPORT: If ON (the default), use PortAudio. If OFF, use WinMM.
Browsing/editing CMake options
In addition to passing options on the command line, you can browse and edit CMake options using cmakesetup (Windows) or ccmake (GNU/Linux and MacOS X).
- Go to the build dir
- On Windows: run 'cmakesetup'
- On GNU/Linux and MacOS X: run 'ccmake .'
Running
QuteCom binary can be found in the 'build/debug' dir.
Windows
If you have problems with missing DLLs you can try use dependency walker.
GNU/Linux
If you haven't installed QuteCom (using 'make install'), you need to use the --resources option to indicate where resources are located, like this:
cd build/debug
./qutecom --resources /path/to/qutecom-2.2/qutecom/resources
MacOS X
On MacOS X, the result of the compilation is a MacOS X bundle, named QuteCom.app. You can start it with 'open debug/QuteCom.app'.
This is fine, but you won't see any logging information. If you want to see logging information you can either:
- Start QuteCom with gdb:
- 'gdb debug/QuteCom.app'
- Type r(return) to start
- Run this command: 'tail -f debug/QuteCom.app/Content/MacOS/log-main.txt'
Installation
On GNU/Linux, 'make install' will install the application to the destination defined by the CMAKE_INSTALL_PREFIX option.
On Windows, 'make install' will produce an NSIS based setup program.
On MacOS X, 'make install' will produce a MacOS X bundle.
This page has been written from http://trac.qutecom.com/browser/INSTALL.txt
