[SOLVED] Problem while trying to compile APM

Hello,

I’m trying to compile the code of ArduPlane. I downloaded de code from github, but when I type “make navio” on the ArduPlane directory, I get the following error message.

I have do modify anything on make files in order to compile APM?

Thank You,

Rafael

Hello Rafael,

You will need to install the later versions of the compiler gcc and g++ instructions are here https://somewideopenspace.wordpress.com/2014/02/28/gcc-4-8-on-raspberry-pi-wheezy/

I forgot to add you will also need to change the /mk/find_tools.mk and find the navio lines.

toolchains for Raspberry Pi

RPI_CXX := arm-linux-gnueabihf-g++
RPI_CC := arm-linux-gnueabihf-gcc
RPI_AS := arm-linux-gnueabihf-gcc
RPI_AR := arm-linux-gnueabihf-ar
RPI_LD := arm-linux-gnueabihf-g++
RPI_GDB := arm-linux-gnueabihf-gdb
RPI_OBJCOPY := arm-linux-gnueabihf-obj

and change it to

toolchains for Raspberry Pi

RPI_CXX := g++
RPI_CC := gcc
RPI_AS := gcc
RPI_AR := ar
RPI_LD := g++
RPI_GDB := gdb
RPI_OBJCOPY := obj
Adric

1 Like

Adric,

I installed the compiler some time ago, but I didn’t change the file of the toolchains, It’s compilling right now.

Thank you very much.

Rafael

Hello Adric,

I was unable to find the find_tools.mk file that you mentioned. If I try “whereis find_tools.mk” it yields no result. If I try to do the same for the /mk directory, it also yields no results on my pi.

Please let me know where to find it, or what is wrong.
Chris

Hello Chris,

Have you got the latest source code from the https://github.com/diydrones/ardupilot repository?

Yes, I have been doing this all within the last day or so.

Well the files are in this location https://github.com/diydrones/ardupilot/blob/master/mk/find_tools.mk
So if you have cloned the repo the file should be there.

Adric

Ah. The other instructions I had been following hadn’t used that specific github. I will try again.

I was able to find the find_tools.mk file that you mentioned, but within the emlid github that the instructions said to download. I am able to make this work on the pi. Thanks!!