Updated msys2 environment to 170126 level.
[freeciv.git] / doc / README.msys2
blobadc4563d75bb7eca2e4c0236d42e4397cc67b85d
2  MSYS2 Windows Installer build notes
3 ====================================
5 This document is about building Freeciv Windows Installer packages
6 using MSYS2 from http://msys2.github.io
9  Status
10 ====================================
12 - Msys1, not msys2, is still the official freeciv Windows Installer
13   build method
14 - Buildable clients are gtk3, gtk3.22, gtk2, sdl2, and Qt
15   - Official pre-made msys2 environment does not support building gtk2-client
18  Setup
19 ====================================
21  This chapter is about creating new msys2 build environment.
23  If you want to reproduce more official freeciv builds, the environment
24  used to make those builds is documented in the next chapter ("Premade environment"),
25  with listing of versions current at the time of this freeciv version.
27 1) Install MSYS2 following the documentation on their homepage
29 1.1) Download
30  https://sourceforge.net/projects/msys2/files/Base/i686/msys2-i686-20161025.exe
31  for win32 or
32  https://sourceforge.net/projects/msys2/files/Base/x86_64/msys2-x86_64-20161025.exe
33  for win64
35 1.2) Run it to install MSYS2 on build system
37 1.3) Launch msys2_shell to update packages
38 > pacman -Syu
40 2) Install following packages with 'pacman -Su'
42 2.1) Packages needed for building freeciv
43  These packages are needed even if you don't plan to make installer,
44  but only build freeciv for local use.
46 2.1.1) Arch independent packages needed for building freeciv
48 2.1.1.1) Arch independent packages always needed for building freeciv
49  With these packages it's possible to build freeciv source tree that
50  has already such generated files present that are created for the
51  release tarball.
53  - make
54  - gettext
55  - pkg-config
57 2.1.1.2) Arch independent packages needed for getting and extracting freeciv
58  source tarball
60  - tar
62 2.1.1.3) Arch independent packages needed for building freeciv from svn checkout
63  These are needed in addition to the ones always needed for building freeciv.
65  - subversion
66  - automake
67  - libtool
68  - autoconf
69  - python
71 2.1.2) Arch-specific packages needed for building freeciv
73 2.1.2.1) Arch-specific packages for building common parts
74  - mingw-w64-i686-gcc / mingw-w64-x86_64-gcc
75  - mingw-w64-i686-curl / mingw-w64-x86_64-curl
76  - mingw-w64-i686-bzip2 / mingw-w64-x64_64-bzip2
77  - mingw-w64-i686-readline / mingw-w64-x86_64-readline
78  - mingw-w64-i686-imagemagick / mingw-w64-x86_64-imagemagick
79  - mingw-w64-i686-SDL2_mixer / mingw-w64-x86_64-SDL2_mixer
81 2.1.2.2) Arch-specific packages for building gtk3- and gtk3.22-client
82  - mingw-w64-i686-gtk3 / mingw-w64-x86_64-gtk3
84 2.1.2.3) Arch-specific packages for buildind Qt-client and/or Ruledit
85  - mingw-w64-i686-qt5 / mingw-w64-x86_64-qt5
87 2.1.2.4) Arch-specific packages for building gtk2-client
88  - mingw-w64-i686-gtk2 / mingw-w64-x86_64-gtk2
90 2.1.2.5) Arch-specific packages for building sdl2-client
91  - mingw-w64-i686-SDL2_image / mingw-w64-x86_64-SDL2_image
92  - mingw-w64-i686-SDL2_ttf / mingw-w64-x86_64-SDL2_ttf
93  - mingw-w64-i686-SDL2_gfx / mingw-w64-x86_64-SDL2_gfx
95 2.2) Packages needed for building installer package
96  These are needed in addition to above ones used in the
97  building step already.
99 2.2.1) Arch-specific packages needed for building installer
100  package
102  - mingw-w64-i686-nsis / mingw-w64-x86_64-nsis
105  Premade environment
106 ====================================
108 Premade msys2 environment is available for download from
109 http://download.gna.org/freeciv/packages/windows/msys2/
111 Current version is
113 win64 host:
114 -----------
115 msys2-freeciv-win64-170126.7z, based on
116 https://sourceforge.net/projects/msys2/files/Base/x86-64/msys2-x86_64-20161025.exe
117 with packages updated to 26-Jan-17 level.
119 Only win64 target is included - replace <arch> with 'x86_64' in package names below
122 Following packages have been installed:
123 - make
124 - pkg-config
125 - tar
126 - subversion
127 - patch
128 - nano
129 - automake
130 - libtool
131 - autoconf
132 - python
133 - gdb
134 - mingw-w64-<arch>-gcc
135 - mingw-w64-<arch>-icu
136 - mingw-w64-<arch>-curl
137 - mingw-w64-<arch>-sqlite3
138 - mingw-w64-<arch>-gtk3
139 - mingw-w64-<arch>-nsis
140 - mingw-w64-<arch>-bzip2
141 - mingw-w64-<arch>-readline
142 - mingw-w64-<arch>-SDL2_mixer
143 - mingw-w64-<arch>-SDL2_image
144 - mingw-w64-<arch>-SDL2_ttf
145 - mingw-w64-<arch>-SDL2_gfx
146 - mingw-w64-<arch>-imagemagick
147 - mingw-w64-<arch>-qt5
150  Build
151 ====================================
153 Launch msys2 shell. Get the freeciv sources there
154 somehow. Some options are:
155 1) Download freeciv tarball within msys2 shell with wget
156 2) Use svn within msys2 shell to get them from version control
157 3) Copy them from Windows folder where they are to a directory that
158    is within msys2
160 > cd win32/installer_msys2
161 > make <targets>
163   Target can be:
164   - "<gui>-installer", where <gui> is
165      - gtk3
166      - gtk3.22
167      - gtk2
168      - sdl2
169      - qt
170   - "ruledit-installer"
171   - "snapshot", if your freeciv sources are in svn checkout directory
173  You can also set minimum Windows version targeted. While setting this
174  to an older version allows those Windows versions to run the created
175  executables, it may come with the cost of disabling functionality that
176  newer Windows versions could otherwise have.
177  The version is set via MIN_WIN_VER variable. For values to use, see
178  list in: https://msdn.microsoft.com/en-us/library/6sehtctf.aspx
179  Current default is 0x0601 (Windows 7).
183  Problems
184 ====================================
186 - Freeciv linked against readline in msys2 does not work.
187   Configure freeciv with --without-readline
190  TODO
191 ====================================
193 - Readline support