Difference between revisions of "BuildingWindows"
|Line 69:||Line 69:|
== Boost ==
== Boost ==
Download http://prdownloads.sf.net/boost/boost_1_38_0.7z?download and http://prdownloads.sf.net/boost/boost-jam-3.1.17-1-ntx86.zip?download and unzip both to ''
Download http://prdownloads.sf.net/boost/boost_1_38_0.7z?download and http://prdownloads.sf.net/boost/boost-jam-3.1.17-1-ntx86.zip?download and unzip both to '':\dev''
Revision as of 20:05, 19 March 2009
- 1 Building Mumble on Windows
Building Mumble on Windows
Mumble has quite a few dependencies for building on Windows, and as the feature set grows, so does the list of dependencies. This page will try to detail the steps required to set up a Win32 build environment.
The paths used here equal the defaults assumed in the Mumble build files. You are free to change them, but you'll then need to change the mumble.pro file as well. If you find any problems or incorrect steps in this article please either correct them or contact us and we will try our best to resolve the issue.
Also note, that if you are submitting a bug report for a self-built executable, we expect you to either
- Follow these instructions to the letter
- Report any deviations from these instructions
Deviations means anything, from "I installed to the D: drive" to "I changed the gcc build options for Qt" or "I used another version of Speex".
Create C:\dev, and inside that directory create a file prep.bat containing:
@echo off SET QTDIR=C:\dev\Qt4.5.0 SET DBUSDIR=C:\dev\dbus SET LIB= SET MYSQL=c:\dev\mysql SET ICE=c:\dev\Ice IF DEFINED "%PROGRAMFILES(X86)%" ( CALL "%PROGRAMFILES(X86)%\Microsoft Visual Studio 9.0\VC\vcvarsall.bat" x86 ) ELSE ( CALL "%PROGRAMFILES%\Microsoft Visual Studio 9.0\VC\vcvarsall.bat" x86 ) SET INCLUDE=C:\dev\WinSDK\include;%INCLUDE% SET PATH=%QTDIR%\bin;%DBUSDIR%\bin;c:\dev\OpenSSL\bin;c:\dev\cmake\bin;%MYSQL%\lib\opt;%ICE%\bin;%PATH%
Start a new command shell (run cmd.exe)
cd \dev prep
Whenever something appears
you're supposed to enter it in that command shell (or copy it from this webpage and right click in the command window and select Paste). When you later want to compile things, remember to call prep.bat first to set paths correctly.
Download the most recent version of TortoiseSVN at http://tortoisesvn.net/downloads and install it. The defaults are fine.
Download the most recent Git from http://code.google.com/p/msysgit/downloads/list and install it. Make sure you select "Run Git from the Windows Command Prompt".
You'll need Visual Studio 2008 (or Visual C++ Express Edition) with SP1.
Visual Studio 2008 Professional 90 day trial: http://msdn2.microsoft.com/en-us/vs2008/products/cc268305.aspx
Visual C++ Express Edition: http://www.microsoft.com/express/download/#webInstall (Look at the bottom right corner for "Visual C++ 2008".)
Intel C++ Compiler
Download and install this: http://www.intel.com/cd/software/products/asmo-na/eng/368972.htm
You only need the file libmmd.dll but currently this seems to be the only official place to get it. If the installer fails it should still install the libraries you need for Mumble.
Download the G15 software from here: http://www.logitech.com/index.cfm/434/180&cl=us,en?WT.ac=sc%7Cdownloads%7C%7Cdd and install it.
Now go to C:\Program Files\Logitech\GamePanel Software\LCD Manager\SDK and extract "LCDSDK_3.01.180.zip". Take the folder that has been extracted and rename it to G15SDK. Put this folder into C:\dev.
Download http://prdownloads.sf.net/boost/boost_1_38_0.7z?download and http://prdownloads.sf.net/boost/boost-jam-3.1.17-1-ntx86.zip?download and unzip both to c:\dev
cd \dev\boost_1_38_0 copy ..\boost-jam-3.1.17-1-ntx86\bjam.exe bjam --toolset=msvc --prefix=C:\dev\Boost install
This might take a while, but when done you'll have Boost installed. Note that none of the other build dependencies do themselves depend on boost, so if you want you can just continue in a new command shell (but remember to call prep.bat). Once all is done, you can safely delete the boost_1_38_0 and boost-jam directories. If you get the warning, that some targets were skipped or failed, it can be ignored for our purposes.
Microsoft Windows SDK
Go here to download: http://www.microsoft.com/downloads/details.aspx?FamilyId=E6E1C3DF-A74F-4207-8586-711EBE331CDC&displaylang=en . At the time of this writing, the latest version is the "Windows SDK for Windows Server 2008 and .NET Framework 3.5". Install it to C:\dev\WinSDK
As you are going through the installer you will come to a window where you will see two main categories and then subcategories below them. Uncheck the green check boxes next to “Documentation” and “Samples”. Continue with the installation. These take a long time to download and are not really needed for Mumble.
Microsoft DirectX SDK
Go to http://msdn.microsoft.com/directx/sdk/ and download the latest SDK. Install it to c:\dev\DXSDK\
From http://www.winkde.org/pub/kde/ports/win32/repository/win32libs/ download the following archives:
Whereas * represents the newest version on the server. Unpack all of them to 'c:\Program Files\win32libs'. If you have extracted them all correctly you should see inside of 'c:\Program Files\win32libs' "include, bin, lib, and manifest" folders. Note that you may also download the dbus library from there, but if you do it will not automatically spawn dbus-daemon as that needs patching.
Download http://www.cmake.org/files/v2.6/cmake-2.6.2-win32-x86.zip and unpack it to c:\dev. Rename the top directory to just 'cmake'.
Checkout the SVN of WinDBus from https://windbus.svn.sourceforge.net/svnroot/windbus/trunk to c:\dev\windbus
cd \dev mkdir windbus-build cd windbus-build cmake -DCMAKE_BUILD_TYPE=Release -DDBUS_INSTALL_SYSTEM_LIBS=ON -G "NMake Makefiles" c:\dev\windbus\cmake nmake nmake install
Regardless of what you say, Windbus is installed to c:\<Program Files>\dbus. Move that entire directory into c:\dev (so it ends up as c:\dev\dbus)
Copy all .dll files from c:\Program Files\win32libs\bin to c:\dev\dbus\bin
You can remove the c:\dev\windbus and c:\dev\windbus-build directories at this point.
Download the OpenSSL source named "openssl-0.9.8g.tar.gz" from here http://www.openssl.org/source/. Unpack it to c:\dev\ (it will create a directory called openssl-x.y.z)
Download and install ActivePerl here: http://downloads.activestate.com/ActivePerl/Windows/5.10/ActivePerl-22.214.171.1244-MSWin32-x86-287188.msi
Open a new shell (so that %PATH% includes ActivePerl).
cd \dev prep cd openssl<press tab> perl Configure VC-WIN32 --prefix=c:\\dev\\OpenSSL ms\do_masm nmake -f ms\ntdll.mak nmake -f ms\ntdll.mak install
You can remove c:\dev\openssl-x.y.z after this.
Download the latest release of MySQL Server. It can be found here: http://dev.mysql.com/downloads/mysql/5.1.html#win32 (select "Without installer (unzip in C:\)"). Unzip it to c:\dev\MySQL.
Download the latest version of ZeroC ICE from http://www.zeroc.com/download.html and make sure you select the VS2008 version. Install to c:\dev\Ice
Download ftp://ftp.trolltech.com/qt/source/qt-win-opensource-src-4.5.0.zip and unzip to C:\dev. Rename the directory from qt-win-opensource-src-4.5.0 to Qt4.5.0
Download http://mumble.sourceforge.net/qt450msvc.patch and put it in c:\dev\Qt4.5.0. Then, start Git Bash, which came with git.
cd /c/dev/Qt4.5.0 patch -lp0 < qt450msvc.patch exit
Start a regular command shell:
cd \dev prep cd Qt4.5.0 configure -debug-and-release -qt-sql-sqlite -qt-sql-mysql -no-qt3support -no-exceptions -qt-zlib -qt-libpng -qt-libjpeg -openssl-linked -dbus-linked -I c:\dev\OpenSSL\include -L c:\dev\OpenSSL\lib -I c:\dev\dbus\include -L c:\dev\dbus\lib -I c:\dev\mysql\include -L c:\dev\mysql\lib\opt -platform win32-msvc2008 nmake
This will also take quite a while.
Download http://downloads.xiph.org/releases/ogg/libogg-1.1.3.zip and unpack it to c:\dev\libogg Use the included project files to build a static library (double click C:\dev\libogg\win32\ogg.dsw and MSVC should start. Select Build -> Batch Build -> check both ogg_static's and then click Build). Make sure the resulting .lib file ends up in c:\dev\libogg\lib and they are named libogg.lib and libogg_d.lib.
Download Mumble and submodules
To clone the repositories :
cd \dev prep git clone git://mumble.git.sourceforge.net/gitroot/mumble mumble cd mumble git submodule init git submodule update
Building Mumble and Murmur
Once all of the above is done we can get to compiling mumble itself. If you want to have ASIO support you have to install an additional, proprietary, ASIO SDK. If you do not need it you can disable it by editing the C:\dev\mumble\src\mumble.pri. Add no-asio to the line which says CONFIG += qt thread debug_and_release warn_on to make it CONFIG += qt thread debug_and_release warn_on no-asio. This disables support for ASIO and gets rid of the dependency. If you want to compile Mumble without G15 support change the qmake command below to qmake CONFIG+="no-g15" main.pro
cd \dev prep cd mumble qmake nmake clean nmake
Note that this builds the debug versions, which is what we strongly recommend to use while developing. If you want to send the binary to someone else, use nmake release instead of the last nmake command listed above. This will result in a much smaller binary with fewer dependencies.