Windows Building and Packaging
Introduction
The old GitBash build environment is deprecated and we use now the Msys2 that supports a package system for updates.
Install Msys2
- Download the msys2 installer from https://msys2.github.io
- Install Msys2 following the instructions on the web site.
- You can either install the i686 (32 bit) or x86_64 (64 bit) version, this applies to host used. Both installers support Win32 and Win64 shells.
- Update Msys2 to the latest available binaries following steps 5 to 7 of Msys2 installation guide.
pacman -Syu
If you get build errors when pulling new code later, always try re-running "pacman -Syu" as that will often resolve build problems.
Username / Home directory
Msys2 creates the home directory using the current Username from Windows.
Be sure the home directory does not contains spaces and rename it if needed.
Check your home directory:
cd ~ pwd
Add LibrePilot MinGW repository
Add the following lines at the end of your /etc/pacman.conf file:
[librepilot-mingw] SigLevel = Optional TrustAll Server = http://download.librepilot.org/repo/mingw
Paste this code into the bash-window to add the above lines to /etc/pacman.conf
echo "[librepilot-mingw]" >> /etc/pacman.conf echo "SigLevel = Optional TrustAll" >> /etc/pacman.conf echo "Server = http://download.librepilot.org/repo/mingw" >> /etc/pacman.conf
Install the toolchain
The toolchain is used to build the software:
Building the LibrePilot software
Congrats !
Congratulations! You have setup the build environment and built the complete LibrePilot software suite!

