Build Quassel on Windows » History » Version 33
romibi, 06/23/2016 08:35 PM
1 | 7 | sph | h1. Building Quassel on Windows |
---|---|---|---|
2 | 1 | sph | |
3 | 3 | sph | {{toc}} |
4 | 3 | sph | |
5 | 1 | sph | h2. Software Requirements |
6 | 1 | sph | |
7 | 1 | sph | * Windows |
8 | 32 | romibi | * "Visual Studio 2015":https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx |
9 | 33 | romibi | * "DirectX SDK":https://www.microsoft.com/en-us/download/details.aspx?id=6812 |
10 | 19 | Datafreak | * "Visual C++ 2008 Redistributables":http://www.microsoft.com/downloads/details.aspx?familyid=A5C84275-3B97-4AB7-A40D-3802B2AF5FC2 |
11 | 19 | Datafreak | * "Platform SDK":http://go.microsoft.com/fwlink/?LinkID=150217&clcid=0x409 |
12 | 28 | romibi | * "OpenSSL":http://www.slproweb.com/products/Win32OpenSSL.html (Tested with: Win64 OpenSSL v1.0.2d) |
13 | 28 | romibi | * "Git for Windows":https://git-for-windows.github.io/ (>= 1.6.0.2) |
14 | 32 | romibi | * "CMake":https://cmake.org/download/ (>= 2.6.2) |
15 | 32 | romibi | * "Qt OpenSource SRC or Qt Installer":http://www.qt.io/download-open-source/#section-2 (Tested with Installer: Qt 5.6.0 for Windows 64-bit) |
16 | 13 | Datafreak | * "PostgreSQL":http://www.enterprisedb.com/products/pgdownload.do#windows (Optional for PostgreSQL-Support) |
17 | 24 | Datafreak | * "SlikSvn":http://www.sliksvn.com/en/download (Optional for Crypt-Support) |
18 | 1 | sph | |
19 | 1 | sph | h2. Installation |
20 | 1 | sph | |
21 | 32 | romibi | h3. Step 1: Install (and Update if necessary) Visual Studio 2015 |
22 | 1 | sph | |
23 | 1 | sph | |
24 | 6 | sph | h3. Step 2: Install Visual C++ 2008 Redistributables. |
25 | 1 | sph | |
26 | 1 | sph | These will be needed for OpenSSL. |
27 | 28 | romibi | (Comment: Still this old version?) |
28 | 1 | sph | |
29 | 1 | sph | h3. Step 3: Install Platform SDK |
30 | 1 | sph | |
31 | 1 | sph | h3. Step 4: Install DirectX SDK |
32 | 1 | sph | |
33 | 28 | romibi | If there's an S1023 error "see this link":https://support.microsoft.com/en-us/kb/2728613 |
34 | 28 | romibi | It says to uninstall Visual C++ 2010 x64 Redistributable, install DirectX SDK and reinstall Redistributable... |
35 | 28 | romibi | (Comment: Should this step be done earlier?) |
36 | 28 | romibi | |
37 | 28 | romibi | |
38 | 10 | Datafreak | h3. Step 5: Install OpenSSL |
39 | 5 | sph | |
40 | 1 | sph | The first error message can be ignored as the Redistributables were installed. |
41 | 1 | sph | |
42 | 10 | Datafreak | h3. Step 6: Install Git |
43 | 1 | sph | |
44 | 1 | sph | |
45 | 1 | sph | h3. Step 7: Install CMake |
46 | 1 | sph | |
47 | 10 | Datafreak | |
48 | 1 | sph | h3. Step 8: Update the environment variables |
49 | 1 | sph | |
50 | 28 | romibi | *Note: The correct paths can vary! Check your folders to find the correct ones! The Variables I had during a successful build are noted "somewhere here":http://pastebin.com/UjQtBNmL* |
51 | 28 | romibi | |
52 | 1 | sph | Go to the system settings (Start => Control Panel => System), go to the "Advanced" tab and click on Environment Variables. |
53 | 1 | sph | |
54 | 23 | Datafreak | First you'll have to edit the "Path" variable. Append the following to the current value: |
55 | 1 | sph | <pre>;C:\Programme\Microsoft SDKs\Windows\v7.0\Bin;C:\Program Files\Git\bin;C:\OpenSSL-Win32\bin</pre> |
56 | 1 | sph | |
57 | 1 | sph | Next, create the following new system variables: |
58 | 1 | sph | |
59 | 23 | Datafreak | * LIB: |
60 | 1 | sph | <pre>C:\Programme\Microsoft SDKs\Windows\v7.0\Lib;C:\Programme\Microsoft DirectX SDK (February 2010)\Lib;C:\OpenSSL-Win32\lib\VC\static</pre> |
61 | 19 | Datafreak | |
62 | 1 | sph | * INCLUDE: |
63 | 23 | Datafreak | <pre>C:\Programme\Microsoft SDKs\Windows\v7.0\Include;C:\Programme\Microsoft DirectX SDK (February 2010)\Include;C:\OpenSSL-Win32\include</pre> |
64 | 19 | Datafreak | |
65 | 11 | Datafreak | * QMAKESPEC: |
66 | 1 | sph | <pre>win32-msvc2008</pre> |
67 | 14 | pennywise | |
68 | 31 | romibi | h3. Step 9: (Optional Install PostgreSQL and Update the environment variables, tutorial not tested with Quassel 0.12) |
69 | 12 | Datafreak | |
70 | 12 | Datafreak | Install PostgreSQL and edit the "Path","LIB" and "INCLUDE" variable. Append the following to the current value: |
71 | 1 | sph | * Path |
72 | 12 | Datafreak | <pre>;C:\Programme\PostgreSQL\8.4\bin</pre> |
73 | 1 | sph | |
74 | 1 | sph | * LIB: |
75 | 12 | Datafreak | <pre>;C:\Programme\PostgreSQL\8.4\lib</pre> |
76 | 1 | sph | |
77 | 12 | Datafreak | * INCLUDE: |
78 | 1 | sph | <pre>;C:\Programme\PostgreSQL\8.4\include</pre> |
79 | 12 | Datafreak | |
80 | 28 | romibi | h3. Step 10: (Compile and) Install Qt |
81 | 12 | Datafreak | |
82 | 28 | romibi | Follow the instructions below or just install via installer and go to Step 11. |
83 | 28 | romibi | |
84 | 1 | sph | Create a directory (e.g. C:\dev\) and unpack Qt. |
85 | 11 | Datafreak | |
86 | 28 | romibi | Now open the Visual Studio command line. |
87 | 1 | sph | |
88 | 1 | sph | And cd to the directory containing Qt. Now you can configure the Qt installation with the following command: |
89 | 1 | sph | * Static without PostgreSQL-Support: |
90 | 23 | Datafreak | <pre>configure.exe -platform win32-msvc2008 -static -release -qt-sql-sqlite -no-qt3support -qt-zlib -qt-gif -qt-libpng -qt-libmng -qt-libtiff -qt-libjpeg -openssl-linked -confirm-license -opensource -no-phonon -no-dbus -webkit -nomake demos -nomake examples OPENSSL_LIBS="-lssleay32MD -llibeay32MD" -l gdi32 -l crypt32</pre> |
91 | 12 | Datafreak | * Shared with PostgreSQL-Support: |
92 | 23 | Datafreak | <pre>configure.exe -platform win32-msvc2008 -shared -release -qt-sql-sqlite -qt-sql-psql -no-qt3support -qt-zlib -qt-gif -qt-libpng -qt-libmng -qt-libtiff -qt-libjpeg -openssl-linked -confirm-license -opensource -phonon -phonon-backend -nomake demos -nomake examples OPENSSL_LIBS="-lssleay32MD -llibeay32MD" -l gdi32 -l crypt32</pre> |
93 | 1 | sph | |
94 | 1 | sph | Then you can compiled Qt with these commands: |
95 | 15 | Datafreak | <pre> |
96 | 1 | sph | nmake |
97 | 8 | Datafreak | </pre> |
98 | 1 | sph | |
99 | 1 | sph | You can close the prompt after this. |
100 | 1 | sph | |
101 | 1 | sph | h3. Step 11: Update the environment variables again |
102 | 12 | Datafreak | |
103 | 28 | romibi | *Note: The correct paths can vary! Check your folders to find the correct ones! The Variables I had during a successful build are noted "somewhere here":http://pastebin.com/UjQtBNmL* |
104 | 28 | romibi | |
105 | 32 | romibi | After compiling and installing Qt, you will have to append the following: |
106 | 1 | sph | |
107 | 8 | Datafreak | * Path |
108 | 23 | Datafreak | <pre>;C:\dev\qt-everywhere-opensource-src-4.6.3\bin</pre> |
109 | 1 | sph | |
110 | 1 | sph | * LIB: |
111 | 1 | sph | <pre>;C:\dev\qt-everywhere-opensource-src-4.6.3\lib</pre> |
112 | 23 | Datafreak | |
113 | 1 | sph | * INCLUDE: |
114 | 1 | sph | <pre>;C:\dev\qt-everywhere-opensource-src-4.6.3\include</pre> |
115 | 23 | Datafreak | |
116 | 32 | romibi | Or if you used the Qt-Installer the folders are somewhere around C:\Qt\Qt5.6.1\5.6\msvc2015_64\ or similiar |
117 | 1 | sph | |
118 | 31 | romibi | h3. Step 12:(Optional for Crypt-Support, tutorial not tested with Quassel 0.12) |
119 | 24 | Datafreak | |
120 | 24 | Datafreak | h4. Step 12.1 Install SlikSvn |
121 | 24 | Datafreak | |
122 | 24 | Datafreak | h4. Step 12.2 Add SlikSvn to environment variables |
123 | 24 | Datafreak | * Path |
124 | 24 | Datafreak | <pre>;C:\Programme\SlikSvn\bin\</pre> |
125 | 24 | Datafreak | |
126 | 24 | Datafreak | h4. Step 12.3 Build QCA |
127 | 24 | Datafreak | <pre>cd C:\dev |
128 | 24 | Datafreak | mkdir qca-build |
129 | 24 | Datafreak | cd qca-build |
130 | 24 | Datafreak | svn checkout svn://anonsvn.kde.org/home/kde/trunk/kdesupport/qca/ |
131 | 24 | Datafreak | mkdir qca2-build |
132 | 24 | Datafreak | cd qca2-build |
133 | 24 | Datafreak | cmake -DBUILD_TESTS=OFF -DCMAKE_INSTALL_PREFIX=C:\dev\qca -DCMAKE_BUILD_TYPE=Release -G "NMake Makefiles" ..\qca |
134 | 24 | Datafreak | nmake |
135 | 24 | Datafreak | nmake install</pre> |
136 | 24 | Datafreak | |
137 | 1 | sph | h4. Step 12.4 Add QCA to environment variables |
138 | 1 | sph | |
139 | 24 | Datafreak | * Path |
140 | 24 | Datafreak | <pre>;C:\dev\qca\bin</pre> |
141 | 24 | Datafreak | |
142 | 1 | sph | * LIB: |
143 | 1 | sph | <pre>;C:\dev\qca\lib</pre> |
144 | 1 | sph | |
145 | 1 | sph | * INCLUDE: |
146 | 1 | sph | <pre>;C:\dev\qca\include</pre> |
147 | 1 | sph | |
148 | 1 | sph | h3. Step 13: Compile Quassel |
149 | 1 | sph | |
150 | 28 | romibi | Open a new Visual Studio command line and go to the "C:\dev" directory again (or create it). Use git to download the Quassel source code. |
151 | 28 | romibi | <pre>git clone https://github.com/quassel/quassel.git</pre> |
152 | 1 | sph | |
153 | 1 | sph | This will create a new directory "quassel" containing the source. When you want to update Quassel later, you just have to go to this directory (C:\dev\quassel) and do a "git pull" to update the source code. |
154 | 28 | romibi | |
155 | 31 | romibi | Next, create a new directory in "C:\dev" in which Quassel will be built. In our case, we will simply call it "build". Change to this directory and enter the following command to configure Quassel: |
156 | 28 | romibi | |
157 | 28 | romibi | With Visual Studio: |
158 | 32 | romibi | * Shared: |
159 | 32 | romibi | <pre>cmake -G"Visual Studio 14 Win64" C:\dev\quassel -DSTATIC=OFF -DWANT_CORE=ON -DWANT_QTCLIENT=ON -DWANT_MONO=ON -DCMAKE_BUILD_TYPE=Release -DWITH_WEBKIT=ON -DLINK_EXTRA=crypt32 -DUSE_QT5=ON -DCMAKE_DISABLE_FIND_PACKAGE_Qt5DBus=ON</pre> |
160 | 28 | romibi | then open "QuasselIRC.sln" |
161 | 28 | romibi | Build->Configuration-Manager-> Switch from "Debug" to "Release" |
162 | 32 | romibi | Build->Build |
163 | 28 | romibi | I just copied the src\Release\quasselclient.exe to an existing official build but this link should help which files are needed in the Program folder: http://wiki.qt.io/Deploy_an_Application_on_Windows |
164 | 28 | romibi | additionally there should be an libeay32.dll and an ssleay32.dll from OpenSSL next to the exe |
165 | 28 | romibi | |
166 | 28 | romibi | Or with nmake: |
167 | 28 | romibi | * Static: (old command?) |
168 | 23 | Datafreak | <pre>cmake -G"NMake Makefiles" C:\dev\quassel -DSTATIC=ON -DWANT_CORE=ON -DWANT_QTCLIENT=ON -DWANT_MONO=ON -DWITH_PHONON=OFF -DCMAKE_BUILD_TYPE=Release -DWITH_WEBKIT=OFF -DLINK_EXTRA=crypt32</pre> |
169 | 28 | romibi | * Shared: (old command?) |
170 | 22 | JabLuszko | <pre>cmake -G"NMake Makefiles" C:\dev\quassel -DWANT_CORE=ON -DWANT_QTCLIENT=ON -DWANT_MONO=ON -DWITH_PHONON=ON -DWITH_WEBKIT=ON -DCMAKE_BUILD_TYPE=Release -DLINK_EXTRA=crypt32</pre> |
171 | 22 | JabLuszko | And after that: |
172 | 22 | JabLuszko | <pre>nmake</pre> |
173 | 22 | JabLuszko | This will build Quasselcore, Quasselclient and Quasselmonolithic which can be found in the "C:\dev\build" directory. |
174 | 2 | sph | |
175 | 2 | sph | h2. Related links |
176 | 2 | sph | |
177 | 25 | Datafreak | * [[DLL Requirement]] |
178 | 2 | sph | * "German tutorial by Datafreak":http://www.datafreak.eu/2008/11/build-qt-and-quassel-under-windows/ |
179 | 28 | romibi | * "Notes: Building Quassel-Client 0.12.2 with link preview by romibi":http://pastebin.com/UjQtBNmL |