Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
howtos:win32:msys2 [2016/03/13 15:28] – Update download instructions enrico | howtos:win32:msys2 [2019/08/19 19:08] – Add warning not to install gcc and mingw-w64-i686-gcc ntrel | ||
---|---|---|---|
Line 2: | Line 2: | ||
====== Build Geany on Windows (using MSYS2) ====== | ====== Build Geany on Windows (using MSYS2) ====== | ||
- | |||
- | *** UNDER CONSTRUCTION *** | ||
Msys2 is a successor to msys which offers a unix-like environment on Windows combined with a pacman-based package manager. It's purpose is to simplify win32 compiliations, | Msys2 is a successor to msys which offers a unix-like environment on Windows combined with a pacman-based package manager. It's purpose is to simplify win32 compiliations, | ||
Line 36: | Line 34: | ||
# gtk familiy | # gtk familiy | ||
pacman -S mingw-w64-i686-gtk2 mingw-w64-i686-gtk3 | pacman -S mingw-w64-i686-gtk2 mingw-w64-i686-gtk3 | ||
- | # for building html docs | + | # for building html docs* |
pacman -S mingw-w64-i686-python2 mingw-w64-i686-python2-docutils | pacman -S mingw-w64-i686-python2 mingw-w64-i686-python2-docutils | ||
# and if you fancy building from git | # and if you fancy building from git | ||
pacman -S git | pacman -S git | ||
+ | # necessary for GTK bundle and installer steps | ||
+ | pacman -S rsync | ||
+ | | ||
+ | *If you don't install python docutils, you will need to pass '' | ||
+ | |||
+ | Make sure you have not installed both '' | ||
| | ||
At last, you want to add '' | At last, you want to add '' | ||
Line 87: | Line 91: | ||
{{: | {{: | ||
- | ===== Creating an installer ===== | + | ===== Creating |
+ | |||
+ | In order to run Geany and/or create | ||
+ | There is simple script which downloads all necessary packages and unpack them in an automated way. | ||
+ | |||
+ | After you have run the scripts as described below, you should copy the resulting files and directories | ||
+ | all into your Geany installation directory if you want to use it directly for your own Geany | ||
+ | installation. | ||
+ | In case you want to create an installer, leave the directories as they are and read on. | ||
+ | |||
+ | |||
+ | ==== Geany ==== | ||
+ | |||
+ | The script is available at https:// | ||
+ | |||
+ | To run it, simply create a new directory where the GTK runtime environment should be | ||
+ | unpacked and change into this directory. | ||
+ | Then call the script and wait a bit. It will download all necessary MSYS2 packages and extract them. | ||
+ | Finally it will download the sources for *grep* and then compile *grep*. | ||
+ | |||
+ | cd | ||
+ | curl -L -o geany-gtk-bundle-from-msys2.sh https:// | ||
+ | mkdir / | ||
+ | cd / | ||
+ | bash ~/ | ||
+ | rsync -a --delete / | ||
+ | |||
+ | There are a few command line options for this script. Run it with " | ||
+ | The most important option is " | ||
+ | |||
+ | The trailing " | ||
+ | |||
+ | ==== Geany-Plugins ==== | ||
+ | |||
+ | For Geany-Plugins, | ||
+ | The script for Geany-Plugins is available at https:// | ||
+ | |||
+ | cd | ||
+ | curl -L -o geany-plugins-gtk-bundle-from-msys2.sh https:// | ||
+ | mkdir / | ||
+ | cd / | ||
+ | bash ~/ | ||
+ | rsync -a --delete / | ||
+ | |||
+ | The trailing " | ||
+ | |||
+ | ===== Creating an installer / Making a release ===== | ||
+ | |||
+ | When creating releases, you always should make sure your GIT working tree is clean | ||
+ | and maybe temporarily rename " | ||
+ | to build a debug release. | ||
+ | Alernatively, | ||
+ | resp. Geany-Plugins. | ||
+ | |||
+ | ==== Geany ==== | ||
+ | |||
+ | Build instructions to build Geany in order to create a Windows installer (within MSYS2 shell): | ||
+ | |||
+ | DESTINATON=/ | ||
+ | VERSION=" | ||
+ | cd ~/geany | ||
+ | make distclean | ||
+ | ./ | ||
+ | ./configure --prefix=${DESTINATON}/ | ||
+ | make -j 2 | ||
+ | make install | ||
+ | make DESTDIR=${DESTINATON}/ | ||
+ | rsync -a --delete ${DESTINATON}/ | ||
+ | |||
+ | The used destination here is "/ | ||
+ | You can use any other location as installation target. | ||
+ | Then we compile Geany and install it normally and additionally using DESTDIR to | ||
+ | another location. | ||
+ | The normal installation is for Geany-Plugins so they can easily find the Geany installation | ||
+ | while the DESTDIR installation is used to move the installed files into the source directory | ||
+ | back for the installer creation. | ||
+ | |||
+ | This process can probably be optimized and shortened but for now it works this way. | ||
+ | |||
+ | The following actually creates the installer. | ||
+ | The installer script expects that you have Python and NSIS 2.x (http:// | ||
+ | installed in your normal Windows system (not in MSYS2). In the future, it would be cool to build the | ||
+ | installer from within the MSYS2 environment but currently only NSIS 3.0 Beta is available in MSYS2. | ||
+ | |||
+ | For the following steps, a little Python is necessary to automate the further installer creation. | ||
+ | The script can be downloaded here: {{: | ||
+ | Open the script in your editor of choice and change paths at the beginning of the script as needed. | ||
+ | |||
+ | The script will also use SignCode to add digital signatures to the created binaries and installers. | ||
+ | Either setup a working SignCode installation or comment out the signing calls at the end of the script. | ||
+ | |||
+ | Finally, start a Windows console session (Start-> | ||
+ | |||
+ | cd c: | ||
+ | python ..\geany-release.py | ||
+ | |||
+ | This will strip and sign all binaries (geany.exe and various .dll files) and | ||
+ | also convert documentation text files to CRLF format. | ||
+ | At the end, you should get two installer executables in ~/geany. | ||
+ | |||
+ | |||
+ | ==== Geany-Plugins ==== | ||
+ | |||
+ | Build instructions to build Geany-Plugins in order to create a Windows installer (within MSYS2 shell): | ||
+ | |||
+ | DESTINATON=/ | ||
+ | VERSION=" | ||
+ | cd ~/ | ||
+ | make distclean | ||
+ | ./ | ||
+ | ./configure --prefix=${DESTINATON}/ | ||
+ | make -j 2 | ||
+ | make install | ||
+ | make DESTDIR=${DESTINATON}/ | ||
+ | rsync -a --delete ${DESTINATON}/ | ||
+ | |||
+ | For the following steps, a little Python is necessary to automate the further installer creation. | ||
+ | The script can be downloaded here: {{: | ||
+ | Open the script in your editor of choice and change paths at the beginning of the script as needed. | ||
+ | |||
+ | The script will also use SignCode to add digital signatures to the created binaries and installers. | ||
+ | Either setup a working SignCode installation or comment out the signing calls at the end of the script. | ||
+ | |||
+ | Finally, start a Windows console session (Start-> | ||
+ | |||
+ | cd c: | ||
+ | python ..\geany-plugins-release.py | ||
+ | |||
+ | This will strip and sign all binaries (various .dll files) and | ||
+ | also convert documentation text files to CRLF format. | ||
+ | At the end, you should get an installer executable in ~/ | ||
- | TODO | ||
===== Automated build via MAKEPKG file ===== | ===== Automated build via MAKEPKG file ===== | ||
Line 95: | Line 228: | ||
TODO | TODO | ||
- | {{tag> | + | {{tag> |