I am trying to Cross compile MAVSDK for Raspberry Pi (for use as off-board computer) using dockcross by following this documentation. Unfortunately after running the command:
./dockcross-linux-armv7 cmake -DCMAKE_BUILD_TYPE=Release -DBUILD_BACKEND=ON -DBUILD_SHARED_LIBS=OFF -Bbuild/linux-armv7 -S.
I get the following notification:
CMake Error in src/CMakeLists.txt: Target "unit_tests_runner" requires the language dialect "CXX17" (with compiler extensions), but CMake does not know the compile flags to use to enable it.
For this and other
CmakeLists.txt located at
src/integration_tests saying the exact same thing.
CMake Generate step failed. Build files cannot be regenerated correctly.
I was hoping someone here could point me in the right direction, as I can’t seem to find the solution for this on my own.
At first I thought that upgrading my cmake (3.18.4) and gcc and g++ versions would solve the problems, but it did not as it seems the docker uses it’s own compilers. Unfortunately I am quite inexperienced with these tools and could not find the solution on my own. As it seems that there have been no questions about problems with cross compilations, I assume the could be a problem with my setup.
Anyway, any recommendations and suggestions will be appreciated.