]> git.xonotic.org Git - xonotic/xonotic.wiki.git/blob - Outdated_Compiling_In_Windows.textile
(Commit created by redmine exporter script from page "Outdated_Compiling_In_Windows...
[xonotic/xonotic.wiki.git] / Outdated_Compiling_In_Windows.textile
1 h1. Compiling in Windows
2
3 {{>toc}}
4
5 *NOTE*: there is an experimental automated building pack for Windows that uses a portable version of the tools mentioned in this article.
6 If you are planning on contributing to the project, it is best to follow the tutorial. If you are just interested in running and testing the game, you can find the build system "here":http://forums.xonotic.org/showthread.php?tid=666.
7
8 h2. Prerequisites
9
10 h3. MinGW / MSYS
11
12 You first need to install a compiler and a shell environment to run the build scripts. On windows, we use MinGW and MSYS. Those two work together, so you have to install MinGW first.
13 It can be found "here":http://sourceforge.net/projects/mingw/files/ . Run the automated installer, and do not check any of the optional components, all you need from MinGW is its C compiler, which is always installed.
14 *Important*: install MinGW in a path containing no spaces. The default path is good: c:\mingw
15
16 Next, you need to install MSYS. The recent versions don't have an installer, so it is easier to install "version 1.0.11":http://downloads.sourceforge.net/mingw/MSYS-1.0.11.exe .
17 *Important*: again, the installation path should contain no spaces. The default is c:\msys
18 After it is done installing, a terminal will pop up, asking you to run the post-install script. Answer yes, and when it asks for the MinGW install path, input it as c:/mingw .
19
20 h3. msysGit
21
22 You will need msysGit to download the Xonotic source files from the repositories and keep them up to date. You can get msysGit "here":http://code.google.com/p/msysgit/ . Download the "Full installer for official Git" file.
23 The default install options should be good.
24
25
26 h2. Downloading the Xonotic sources
27
28 Open git bash, and type those two commands:
29 <pre>
30 cd /c/msys/1.0
31 git clone git://git.xonotic.org/xonotic/xonotic.git
32 </pre>
33
34 (Tip: you can paste text in the console with the Shift-Insert keyboard shortcut)
35
36 This will install the Xonotic root repository in c:\msys\1.0\xonotic
37
38 When the download is done, type
39 <pre>
40 cd xonotic
41 ./all update
42 </pre>
43
44 This will download approximately 2 gigabytes of data, and use 4 gigabytes in disk space.
45 This will take a while, but you can already get started on the next step.
46
47
48 h2. Setting up the environment
49
50 To run and compile Xonotic, the "all" script must be able to access msysGit from MSYS, as well as wget and unzip. The xonpatch bundle patches your MSYS installation to sort this out.
51
52 *Important*: if you have followed a previous version of this guide where the "profile" file had to be edited manually, download the original msys1.0.11 profile file from the attachments on this page, and unzip it in c:\msys\1.0\etc before applying the xonpatch.
53
54 The process is simple: download the latest xonpatch from the attachments, and extract it in c:\msys\1.0 . Then, launch xonpatch.bat. This will make msysGit visible from MSYS, and add wget as well as unzip.
55
56 h2. Compiling and running the game
57
58 When the cloning of all the repositories is done, open MSYS and type:
59 <pre>
60 cd /xonotic
61 ./all compile
62 </pre>
63
64 This will compile the engine, QC compiler, and game progs. When this is done, you can then run the game with:
65 <pre>
66 ./all run
67 </pre>
68
69 h2. Updating
70
71 To update, all you need to do is open MSYS and:
72 <pre>
73 cd /xonotic
74 ./all update
75 ./all compile
76 </pre>
77
78 The most recent Xonotic development version is then ready to run.