My Little Modifications to the Windows Compilation WIKI:
Posted: Mon Sep 10, 2012 2:12 am
To compile Qbittorrent 3.0.2 with QT4.8.2, boost 1.51, libtorrent 0.16.3 or with lastest libtorrent svn and without zlib support.
==================================
(Im not a programmer, I tried to compile this just for fun.)
Compilation Steps with msvc 10.0 compiler
We are building qBittorrent on Windows with msvc compiler instead of
MinGW. This choice was made because MinGW does not support wide
characters <http://www.mingw.org/wiki/wide_characters>. Msvc compiler
also generates smaller executables than MinGW.
*
•.Download and install Visual C++ 2010 Express
<http://www.microsoft.com/visualstudio/e ... pp-express>
*
•.Download and install Qt binaries compiled with msvc
<http://qt.nokia.com/downloads/windows-cpp-vs2010> (not compiled
with MinGW)
*
•.Add Msvc and Qt bin/ folders (C:\Qt\4.8.2\bin and C:\Program
Files\Microsoft Visual Studio 10.0\VC\bin) to the PATH environment
variable.
(For example using windows 7: http://www.itechtalk.com/thread3595.html)
*
•.Create new folder for download and extract sources. For example:
D:\QBT_Project
*
•.Download Boost Jam
<http://sourceforge.net/projects/boost/f ... p/download>
32bits for 1.51 boost library (bjam) and Boost library
<http://sourceforge.net/projects/boost/f ... p/download>
1.51 and unzip them in D:\QBT_Project\
You will got 2 new directories:
D:\QBT_Project\bin
and
D:\QBT_Project\boost_1_51_0
*
•.Compile boost using the following command in a terminal:
[ (bjam must be in the PATH):
(For example using windows 7: http://www.itechtalk.com/thread3595.html)
Edit PATH environment variable and ADD a point to bjam.exe
directory (you will need to close and reopen your terminal window
after that)
PATH = DONT CHANGE THE PREVIOUS ONE SIMPLE ADD THE
FOLLOWING;D:\QBT_Project\bin
]
Open “Visual Studio Command Prompt”:
Type:
D: (Press Enter)
cd D:\QBT_Project\boost_1_51_0 (Press Enter)
Copy the following command in the “Visual Studio Command Prompt” and
press Enter:
bjam -q --with-filesystem --with-thread --toolset=msvc
variant=release link=static runtime-link=shared
*
•.Define BOOST_ROOT environment variable and point to the boost
source folder (you will need to close and reopen your terminal
window after that)
(For example using windows 7: http://www.itechtalk.com/thread3595.html)
BOOST_ROOT = D:\QBT_Project\boost_1_51_0
*
•.Download lastest stable & recomended OpenSSL 32 bits
<http://slproweb.com/download/Win32OpenSSL-1_0_1c.exe> and install it
(Default: C:\OpenSSL-Win32 )
*
•.Copy OpenSSL include folder (C:\OpenSSL-Win32\include\openssl) to
Msvc include/ folder (C:\Program Files\Microsoft Visual Studio
10.0\VC\include)
*
•.Download libtorrent 0.16.3
<http://code.google.com/p/libtorrent/dow ... 6.3.tar.gz>
and extract it (v0.14.10-v0.16.0svn are known to work)
(Or you can try lastest Svn:
http://libtorrent.svn.sourceforge.net/v ... ent/trunk/?
<http://libtorrent.svn.sourceforge.net/v ... r>view=tar
<http://libtorrent.svn.sourceforge.net/v ... /?view=tar>
)
*
•.Compile libtorrent using the following command in a terminal:
Open “Visual Studio Command Prompt”:
Type:
D: (Press Enter)
cd D:\QBT_Project\libtorrent-rasterbar-0.16.3(Press Enter)
Copy the following command in the “Visual Studio Command Prompt” and
press Enter:
bjam -q --without-python --toolset=msvc variant=release link=static
runtime-link=shared logging=none geoip=static encryption=openssl
dht-support=on boost=source define="BOOST_FILESYSTEM_VERSION=2"
*
•.Download a recent qBittorrent
o
•.GIT respository is located at
git://github.com/cdumez/qBittorrent.git
o
•.Tarballs are available from sourceforge here
<http://sourceforge.net/projects/qbittor ... z/download>
(3.0.2)
Download http://geolite.maxmind.com/download/geo ... oIP.dat.gz and extrac it (GeoIP.dat) in:
D:\QBT_Project\qbittorrent-3.0.2\src\geoip
*
•.Download and install Qt Creator IDE 2.5.2 for Windows
<http://get.qt.nokia.com/qtcreator/qt-cr ... -2.5.2.exe>
o
•.Configure Qt Creator to use Qt-msvc x86:
Tools-->Options-->Build & Run-->QT versions should be QT 4.8.2
qmake.exe
Tools-->Options-->Build & Run-->Toolchains should be there MSVC
10.0 x86
*
•.Start QtCreator IDE and load qBittorrent project file
(qbittorrent.pro) in D:\QBT_Project\qbittorrent-3.0.2\
* Make sure that in Projects--->Build settings--->Is in "Released Mode"
•.Edit winconf.pri to point to the correct include and lib paths on
your file system (boost, libtorrent, OpenSSL)
o
•.boost libs are generated in
D:\QBT_Project\boost_1_51_0\stage\lib
o
•.libtorrent lib is generated in
D:\QBT_Project\libtorrent-rasterbar-0.16.3\bin\msvc-10.0\release\boost-source\encryption-openssl\geoip-static\link-static\threading-multi\
o
•.OpenSSL libs are located at C:\OpenSSL-Win32\lib\VC as a default
•.Build qBittorrent using QtCreator, it should compile fine!
( Build---->Rebuild All )
qbittorrent.exe should be located in:
D:\QBT_Project\qbittorrent-build-desktop-Qt_4_8_2_in_PATH__4_8_2__Release\src\release
Last edited Sep 10, 2012
Regards.
==================================
(Im not a programmer, I tried to compile this just for fun.)
Compilation Steps with msvc 10.0 compiler
We are building qBittorrent on Windows with msvc compiler instead of
MinGW. This choice was made because MinGW does not support wide
characters <http://www.mingw.org/wiki/wide_characters>. Msvc compiler
also generates smaller executables than MinGW.
*
•.Download and install Visual C++ 2010 Express
<http://www.microsoft.com/visualstudio/e ... pp-express>
*
•.Download and install Qt binaries compiled with msvc
<http://qt.nokia.com/downloads/windows-cpp-vs2010> (not compiled
with MinGW)
*
•.Add Msvc and Qt bin/ folders (C:\Qt\4.8.2\bin and C:\Program
Files\Microsoft Visual Studio 10.0\VC\bin) to the PATH environment
variable.
(For example using windows 7: http://www.itechtalk.com/thread3595.html)
*
•.Create new folder for download and extract sources. For example:
D:\QBT_Project
*
•.Download Boost Jam
<http://sourceforge.net/projects/boost/f ... p/download>
32bits for 1.51 boost library (bjam) and Boost library
<http://sourceforge.net/projects/boost/f ... p/download>
1.51 and unzip them in D:\QBT_Project\
You will got 2 new directories:
D:\QBT_Project\bin
and
D:\QBT_Project\boost_1_51_0
*
•.Compile boost using the following command in a terminal:
[ (bjam must be in the PATH):
(For example using windows 7: http://www.itechtalk.com/thread3595.html)
Edit PATH environment variable and ADD a point to bjam.exe
directory (you will need to close and reopen your terminal window
after that)
PATH = DONT CHANGE THE PREVIOUS ONE SIMPLE ADD THE
FOLLOWING;D:\QBT_Project\bin
]
Open “Visual Studio Command Prompt”:
Type:
D: (Press Enter)
cd D:\QBT_Project\boost_1_51_0 (Press Enter)
Copy the following command in the “Visual Studio Command Prompt” and
press Enter:
bjam -q --with-filesystem --with-thread --toolset=msvc
variant=release link=static runtime-link=shared
*
•.Define BOOST_ROOT environment variable and point to the boost
source folder (you will need to close and reopen your terminal
window after that)
(For example using windows 7: http://www.itechtalk.com/thread3595.html)
BOOST_ROOT = D:\QBT_Project\boost_1_51_0
*
•.Download lastest stable & recomended OpenSSL 32 bits
<http://slproweb.com/download/Win32OpenSSL-1_0_1c.exe> and install it
(Default: C:\OpenSSL-Win32 )
*
•.Copy OpenSSL include folder (C:\OpenSSL-Win32\include\openssl) to
Msvc include/ folder (C:\Program Files\Microsoft Visual Studio
10.0\VC\include)
*
•.Download libtorrent 0.16.3
<http://code.google.com/p/libtorrent/dow ... 6.3.tar.gz>
and extract it (v0.14.10-v0.16.0svn are known to work)
(Or you can try lastest Svn:
http://libtorrent.svn.sourceforge.net/v ... ent/trunk/?
<http://libtorrent.svn.sourceforge.net/v ... r>view=tar
<http://libtorrent.svn.sourceforge.net/v ... /?view=tar>
)
*
•.Compile libtorrent using the following command in a terminal:
Open “Visual Studio Command Prompt”:
Type:
D: (Press Enter)
cd D:\QBT_Project\libtorrent-rasterbar-0.16.3(Press Enter)
Copy the following command in the “Visual Studio Command Prompt” and
press Enter:
bjam -q --without-python --toolset=msvc variant=release link=static
runtime-link=shared logging=none geoip=static encryption=openssl
dht-support=on boost=source define="BOOST_FILESYSTEM_VERSION=2"
*
•.Download a recent qBittorrent
o
•.GIT respository is located at
git://github.com/cdumez/qBittorrent.git
o
•.Tarballs are available from sourceforge here
<http://sourceforge.net/projects/qbittor ... z/download>
(3.0.2)
Download http://geolite.maxmind.com/download/geo ... oIP.dat.gz and extrac it (GeoIP.dat) in:
D:\QBT_Project\qbittorrent-3.0.2\src\geoip
*
•.Download and install Qt Creator IDE 2.5.2 for Windows
<http://get.qt.nokia.com/qtcreator/qt-cr ... -2.5.2.exe>
o
•.Configure Qt Creator to use Qt-msvc x86:
Tools-->Options-->Build & Run-->QT versions should be QT 4.8.2
qmake.exe
Tools-->Options-->Build & Run-->Toolchains should be there MSVC
10.0 x86
*
•.Start QtCreator IDE and load qBittorrent project file
(qbittorrent.pro) in D:\QBT_Project\qbittorrent-3.0.2\
* Make sure that in Projects--->Build settings--->Is in "Released Mode"
•.Edit winconf.pri to point to the correct include and lib paths on
your file system (boost, libtorrent, OpenSSL)
o
•.boost libs are generated in
D:\QBT_Project\boost_1_51_0\stage\lib
o
•.libtorrent lib is generated in
D:\QBT_Project\libtorrent-rasterbar-0.16.3\bin\msvc-10.0\release\boost-source\encryption-openssl\geoip-static\link-static\threading-multi\
o
•.OpenSSL libs are located at C:\OpenSSL-Win32\lib\VC as a default
•.Build qBittorrent using QtCreator, it should compile fine!
( Build---->Rebuild All )
qbittorrent.exe should be located in:
D:\QBT_Project\qbittorrent-build-desktop-Qt_4_8_2_in_PATH__4_8_2__Release\src\release
Last edited Sep 10, 2012
Regards.