I am trying to cross compile the C++ movehead example from SDK, my machine is a VM UBUNTU 18.04.6 LTS.
I created the crosscompile toolchain and configured it in qibuild. The cmake path is defined in cmakelists and when I try to build the program, the following error appears:
* (1/1) Building movehead in Debug
Scanning dependencies of target movehead
[ 50%] Linking CXX executable sdk/bin/movehead
../lib/libalproxies.so: error adding symbols: File in wrong format
collect2: error: ld returned 1 exit status
CMakeFiles/movehead.dir/build.make:131: recipe for target 'sdk/bin/movehead' failed
make[2]: *** [sdk/bin/movehead] Error 1
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/movehead.dir/all' failed
Ocodracnata
Hello guys
I am trying to cross compile the C++ movehead example from SDK, my machine is a VM UBUNTU 18.04.6 LTS.
I created the crosscompile toolchain and configured it in qibuild. The cmake path is defined in cmakelists and when I try to build the program, the following error appears:
* (1/1) Building movehead in Debug
Scanning dependencies of target movehead
[ 50%] Linking CXX executable sdk/bin/movehead
../lib/libalproxies.so: error adding symbols: File in wrong format
collect2: error: ld returned 1 exit status
CMakeFiles/movehead.dir/build.make:131: recipe for target 'sdk/bin/movehead' failed
make[2]: *** [sdk/bin/movehead] Error 1
CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/movehead.dir/all' failed
make[1]: *** [CMakeFiles/movehead.dir/all] Error 2
Makefile:129: recipe for target 'all' failed
make: *** [all] Error 2
This is the CMakelists file
CMakeLists.txt
##
# Copyright (c) 2011 Aldebaran Robotics. All Rights Reserved.
cmake_minimum_required(VERSION 2.6.4 FATAL_ERROR)
# Give a name to the project.
project(movehead)
# Set _SDK_ROOT_DIR to the dirname of this file (/path/to/sdk)
get_filename_component(_SDK_ROOT_DIR ${CMAKE_CURRENT_LIST_FILE} PATH)
# Libraries are looked for in /path/to/sdk/lib,
# headers in /path/to/sdk/include, and so on.
set(qibuild_DIR "${_SDK_ROOT_DIR}/share/cmake/qibuild" INTERNAL CACHE "" FORCE)
set(CMAKE_PREFIX_PATH "${_SDK_ROOT_DIR}/share/cmake/" INTERNAL CACHE "" FORCE)
# This include enable you to use our CMake framework
find_package(qibuild)
# Create an executable named movehead,
# with the source file : movehead.cpp
qi_create_bin(movehead movehead.cpp)
# Tell CMake that movehead depends on ALCOMMON and ALPROXIES
# This will set the libraries to link movehead with,
# the include paths, and so on
qi_use_lib(movehead ALCOMMON ALPROXIES)
The movehead.cpp file and others needed for qibuild are at:
/home/name/Documents/naoqi-sdk-2.8.5.10-linux64