Home        Store        Docs        Blog

Trouble compiling ArduSub


(Reza) #1

Hi, I am trying to compile Ardusub, however when I try entering the make command, I get the error:

No such file or directory
make: *** No rule to make target ‘ardupilot/modules/uavcan/libuavcan/include.mk’.

Thanks for your help.

(Jacob) #2

git submodule update --init --recursive

(Reza) #3

@jwalser, that worked however now when I compile I am told to:

On MacOS please run:
sudo pip install empy catkin_pkg

However, when I do this I get the error:

Could not fetch URL https://pypi.python.org/simple/empy/: There was a problem confirming the ssl certificate: [SSL: TLSV1_ALERT_PROTOCOL_VERSION] tlsv1 alert protocol version (_ssl.c:645) - skipping
Could not find a version that satisfies the requirement empy (from versions: )
No matching distribution found for empy

(Patrick José Pereira) #4

Hi Reza,

This is a pip issue, apparently you are using a old version, please update.
From python:

The rolling brownouts are finished, and TLSv1.0 and TLSv1.1 have been disabled.


(Reza) #5

I am now getting this error

error: this statement may fall through [-Werror=implicit-fallthrough=] if (AP_RangeFinder_NMEA::detect(serial_manager, serial_instance)) {

Thank you for all your help so far.

(Patrick José Pereira) #6

Hi Reza,

Can you say what are you doing and where are you getting this instructions ?

(Reza) #7

Hi I am using the command:
make px4-v2

I am following the instructions from the ArduSub GitBook

(Jacob) #8

Thanks @reza, try the instructions again, I’ve added some steps.

(Reza) #9

@jwalser thank you for all your help, but I am still having issues. I now receive this error when running the make px4-v2 command.

    ardupilot/modules/PX4Firmware/Build/px4io-v1_default.build/nuttx-export/include/stdio.h:145:8: error: declaration of 'int vsscanf(char*, const char*, va_list)' conflicts with built-in declaration 'int vsscanf(const char*, const char*, __va_list)' [-Werror=builtin-declaration-mismatch]
 int    vsscanf(char *buf, const char *s, va_list ap);
compilation terminated due to -Wfatal-errors.
cc1plus: all warnings being treated as errors

(Jacob) #10

What operating system and compiler are you using? It looks like something is broken with your toolchain installation.

(Reza) #11

OSX, and terminal. I think I will use something else, however.

(Patrick José Pereira) #12

Hi Reza,

You need to use a compatible compiler version, right now the standard version is gcc 4.9.
Can you say what are you using and version ?

(Jacob) #13

Try showing us the output of arm-none-eabi-gcc -v

(Reza) #14
    Using built-in specs.
Target: arm-none-eabi
Configured with: /Users/build/work/GCC-7-build/src/gcc/configure --target=arm-none-eabi --prefix=/Users/build/work/GCC-7-build/install-native --libexecdir=/Users/build/work/GCC-7-build/install-native/lib --infodir=/Users/build/work/GCC-7-build/install-native/share/doc/gcc-arm-none-eabi/info --mandir=/Users/build/work/GCC-7-build/install-native/share/doc/gcc-arm-none-eabi/man --htmldir=/Users/build/work/GCC-7-build/install-native/share/doc/gcc-arm-none-eabi/html --pdfdir=/Users/build/work/GCC-7-build/install-native/share/doc/gcc-arm-none-eabi/pdf --enable-languages=c,c++ --enable-plugins --disable-decimal-float --disable-libffi --disable-libgomp --disable-libmudflap --disable-libquadmath --disable-libssp --disable-libstdcxx-pch --disable-nls --disable-shared --disable-threads --disable-tls --with-gnu-as --with-gnu-ld --with-newlib --with-headers=yes --with-python-dir=share/gcc-arm-none-eabi --with-sysroot=/Users/build/work/GCC-7-build/install-native/arm-none-eabi --build=x86_64-apple-darwin10 --host=x86_64-apple-darwin10 --with-gmp=/Users/build/work/GCC-7-build/build-native/host-libs/usr --with-mpfr=/Users/build/work/GCC-7-build/build-native/host-libs/usr --with-mpc=/Users/build/work/GCC-7-build/build-native/host-libs/usr --with-isl=/Users/build/work/GCC-7-build/build-native/host-libs/usr --with-libelf=/Users/build/work/GCC-7-build/build-native/host-libs/usr --with-host-libstdcxx='-static-libgcc -Wl,-lstdc++ -lm' --with-pkgversion='GNU Tools for Arm Embedded Processors 7-2017-q4-major' --with-multilib-list=rmprofile
Thread model: single
gcc version 7.2.1 20170904 (release) [ARM/embedded-7-branch revision 255204] (GNU Tools for Arm Embedded Processors 7-2017-q4-major)

Thank you so much for all your help

(Jacob) #15

You should have downloaded arm gcc 4.9. Did you follow the instructions here?


(Reza) #16

Yes, I have

(Patrick José Pereira) #17

Hi Reza,

Can you install gcc-arm-none-eabi-49 and try again ?

(Reza) #18

That did the trick! Thank you for you continued help!

(Reza) #19

Sorry, one last question. I’ve made a custom motor layout. How do I select it in QGroundControl, as the option does not seem to show up for it.