Servers by jDrones

Building older release from version or commit #


(David Posea) #1

I have tried numerous searches but can’t find an answer that works. If I look up the commit associated with the verion.h updated of say Copter, and checkout a branch based on that, the build fails with some Task.py mismatch. If I use git checkout Copter-3.6 I get a similar but different error. How can I build the exact same project that was build the day the Copter-3.6 tag was created, or better yet how do I checkout and build Copter-3.6rc12?

Sorry if this is a stupid question, but I can’t figure it out.


(Hunt0r) #2

I’m trying on my system now. I changed the working directory to ArduPilot and then ran:

git pull
git checkout Copter-3.6
git submodule update
make

It seems to be building fine… could you be more specific about what you did, and what the error result was?


(James Pattison) #3

The “git submodule update” is easy to forget, but very important.
To explain, “git checkout xxxxx” sets the version of ArduPilot code you want to work with, but you need to set the submodules (like uavcan, nuttx, ChibiOS, mavlink) to the version that was correct for the main code at the time. If you move back to master or another branch you’ll need to update the submodules again.
If a simple “git submodule update” doesn’t work, add “—recursive —force” to the end.


(David Posea) #4

that was what I was missing. I also could not find out how to build nuttx vs chibios documented anywhere. The only thing I was able to figure out is it is tied to the board name (and maybe version). I saw a new option was added 4 days ago but that does not help with older builds. I’m going to see if I can update the developer guide to better explain the submodule structure.


(James Pattison) #5

For most of the boards where both ChibiOS and NuttX are supported, the “fmuvN” build target is ChibiOS, and “px4-vN” is NuttX.