Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Section
Column
width80%

Introduction

Windows does not provide a bash environment like other 'Unix' systems. Most of tools are prepackaged and downloaded from our server to make the installation as friendly as possible. All you need to install manually is the msysGit package. Then, after running two scripts, you should have a complete build environment ready.

Column
width30%
Table of Content Zone
locationtop

 

Table of Contents
 

...

Install required software

...

Browse installation steps using left/right arrows above.

...

Get the code using Git Bash

  • Start Git Bash
  • Create a C:/CODE directory (no spaces in name) :

...

Code Block
languagepowershell
themeEmacs
cd librepilot
git checkout next

 

...

Install Windows tools

Some tools are needed : make and 7za (7-Zip)

...

Tip
titlemake command
Column
width50%

Tired of typing tools/bin/make every time?

The following command will add /C/code/librepilot/tools/bin to your PATH:

Code Block
languagepowershell
themeEmacs
echo "export PATH=\"\$PATH:/C/code/librepilot/tools/bin\"" >> ~/.profile

You should adapt it to match your librepilot directory...


After issuing the above command, you'll need to exit the current shell and start a new one for it to take effect.

The rest of the document assumes that you have done this step (and we really recommend that you do it).

Install the toolchain

The toolchain is used to build the software:

...

Info
titleCcache issue

With the latest msysGIT version there are some issues with ccache install and ccache can be disabled as follows :

Code Block
languagepowershell
themeEmacs
make[1]: *** [install] Error 3
make[1]: Leaving directory 'C:/code/librepilot/build/ccache-3.2.2'
C:/code/librepilot/make/tools.mk:1011: recipe for target 'ccache_install' failed
make: *** [ccache_install] Error 2

Edit the file make/tools.mk and find this line:

Code Block
languagepowershell
themeEmacs
BUILD_SDK_TARGETS += osg sdl nsis mesawin openssl ccache

Comment ccache target with a "#"

Code Block
languagepowershell
themeEmacs
BUILD_SDK_TARGETS += osg sdl nsis mesawin openssl #ccache

...

Building the LibrePilot software

Section
Column
width60%

 

Basically you just need to type:

Code Block
languagepowershell
themeEmacs
make package
Info

See also the Make basics page and learn more about 'make' commands

 

It will build the UAVObjGenerator utility and all firmwares:

Column
width40%

   

...

Section
Column
width60%

Finally all files are packaged using the Nsis software installer.

 

At end, the LibrePilot software installer can be found in C:\code\librepilot\build\ directory.

 

     

 

Column
width40%

   

...

Congrats !

Congratulations! You have setup the build environment and built the complete LibrePilot software suite!

...