Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ROS: survivepublisher fails to build #282

Open
jcaInciteRobotics opened this issue Nov 18, 2022 · 1 comment
Open

ROS: survivepublisher fails to build #282

jcaInciteRobotics opened this issue Nov 18, 2022 · 1 comment

Comments

@jcaInciteRobotics
Copy link

Describe the bug
The survive_publisher node fails to build. CMake exits with error 1 when building with both catkin build and catkin_make. Libsurvive is the only project in the catkin workspace.

Data
n/a

Compile log*******************

catkin build -v

Profile: default
Extending: [cached] /opt/ros/noetic
Workspace: /home/jc/catkin_ws

Build Space: [exists] /home/jc/catkin_ws/build
Devel Space: [exists] /home/jc/catkin_ws/devel
Install Space: [unused] /home/jc/catkin_ws/install
Log Space: [exists] /home/jc/catkin_ws/logs
Source Space: [exists] /home/jc/catkin_ws/src
DESTDIR: [unused] None

Devel Space Layout: linked
Install Space Layout: None

Additional CMake Args: None
Additional Make Args: None
Additional catkin Make Args: None
Internal Make Job Server: True
Cache Job Environments: False

Buildlisted Packages: None
Skiplisted Packages: None


WARNING: Your current environment's CMAKE_PREFIX_PATH
is different from the cached CMAKE_PREFIX_PATH used
the last time this workspace was built.

If you want to use a different CMAKE_PREFIX_PATH you
should call catkin clean to remove all references to
the previous CMAKE_PREFIX_PATH.

Cached CMAKE_PREFIX_PATH:
/opt/ros/noetic
Current CMAKE_PREFIX_PATH:
/home/jc/catkin_ws/devel/.private/catkin_tools_prebuild:/opt/ros/noetic

[build] Found 1 packages in 0.0 seconds.
[build] Package table is up to date.
Starting >>> survive_publisher
Starting >> survive_publisher:loadenv
Output << survive_publisher:loadenv /home/jc/catkin_ws/logs/survive_publisher/build.loadenv.002.log
Loading environment from: /home/jc/catkin_ws/devel/env.sh

Finished << survive_publisher:loadenv
Starting >> survive_publisher:mkdir
Starting >> survive_publisher:mkdir
Starting >> survive_publisher:cache-manifest
Starting >> survive_publisher:cmake
Subprocess > survive_publisher:cmake cd /home/jc/catkin_ws/build/survive_publisher; catkin build --get-env survive_publisher | catkin env -si /usr/bin/cmake /home/jc/catkin_ws/src/libsurvive/tools/ros_publisher --no-warn-unused-cli -DCATKIN_DEVEL_PREFIX=/home/jc/catkin_ws/devel/.private/survive_publisher -DCMAKE_INSTALL_PREFIX=/home/jc/catkin_ws/install; cd -


Errors << survive_publisher:cmake /home/jc/catkin_ws/logs/survive_publisher/build.cmake.002.log
Not searching for unused variables given on the command line.
Re-run cmake no build system arguments
CMake Warning (dev) at CMakeLists.txt:1 (project):
Policy CMP0048 is not set: project() command manages VERSION variables.
Run "cmake --help-policy CMP0048" for policy details. Use the cmake_policy
command to set the policy and suppress this warning.

The following variable(s) would be set to empty:

CMAKE_PROJECT_VERSION
CMAKE_PROJECT_VERSION_MAJOR
CMAKE_PROJECT_VERSION_MINOR

This warning is for project developers. Use -Wno-dev to suppress it.

Adding base cmake...
-- Option: DO_CORE_BUILD: OFF
-- Option: BUILD_STATIC: OFF
-- Option: USE_SINGLE_PRECISION: OFF
-- Option: ENABLE_WARNINGS_AS_ERRORS: OFF
-- Option: USE_HIDAPI: OFF
-- Option: USE_ASAN: OFF
-- Option: USE_MSAN: OFF
-- Option: ENABLE_TESTS: OFF
-- Option: USE_HEX_FLOAT_PRINTF: OFF
-- Option: USE_OPENCV: OFF
-- Option: USE_COLUMN_MAJOR_MATRICES: OFF
-- Option: USE_CPU_TUNE: OFF
-- Option: USE_OPENBLAS:
-- Option: BUILD_LH1_SUPPORT: ON
-- Option: BUILD_GATT_SUPPORT:
-- Option: BUILD_APPLICATIONS: ON
CMake Warning at /home/jc/catkin_ws/src/libsurvive/tools/ros_publisher/../../libs/cnkalman/CMakeLists.txt:23 (find_package):
By not providing "Findsciplot.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "sciplot", but
CMake did not find one.

Could not find a package configuration file provided by "sciplot" with any
of the following names:

sciplotConfig.cmake
sciplot-config.cmake

Add the installation prefix of "sciplot" to CMAKE_PREFIX_PATH or set
"sciplot_DIR" to a directory containing one of the above files. If
"sciplot" provides a separate development package or SDK, be sure it has
been installed.

Can't use sciplot...
-- CNMatrix option: DOWNLOAD_EIGEN: ON
-- CNMatrix option: USE_EIGEN: ON
-- CNMatrix option: USE_COLUMN_MAJOR_MATRICES: OFF
-- CNMatrix option: USE_SINGLE_PRECISION: OFF
Found system eigen
-- CNMatrix option: USE_OPENBLAS: OFF
Found cblas at /usr/lib/x86_64-linux-gnu/libcblas.so
Found openblas at /usr/lib/x86_64-linux-gnu/libopenblas.so
Found lapacke at /usr/lib/x86_64-linux-gnu/liblapacke.so
Searching for 'cblas.h'; found at /usr/include/x86_64-linux-gnu/cblas.h
Using eigen backend
Found cblas at /usr/lib/x86_64-linux-gnu/libcblas.so
Found openblas at /usr/lib/x86_64-linux-gnu/libopenblas.so
Found lapacke at /usr/lib/x86_64-linux-gnu/liblapacke.so
Searching for 'cblas.h'; found at /usr/include/x86_64-linux-gnu/cblas.h
Using eigen backend
Using provided /home/jc/catkin_ws/src/libsurvive/src/./generated/common_math.gen.h
Using provided /home/jc/catkin_ws/src/libsurvive/src/./generated/kalman_kinematics.gen.h
Using provided /home/jc/catkin_ws/src/libsurvive/src/./generated/lighthouse_model.gen.h
Using provided /home/jc/catkin_ws/src/libsurvive/src/./generated/imu_model.gen.h
Using versioned libusb dir
Can't build usbmon plugin -- pcap library was not found
-- Option: ENABLE_driver_dummy: ON
-- Option: ENABLE_driver_vive: ON
-- Option: ENABLE_driver_simulator: ON
-- Option: ENABLE_driver_playback: ON
-- Option: ENABLE_disambiguator_statebased: ON
-- Option: ENABLE_poser_dummy: ON
-- Option: ENABLE_poser_mpfit: ON
-- Option: ENABLE_poser_kalman_only: ON
-- Option: ENABLE_poser_barycentric_svd: ON
-- Option: ENABLE_driver_global_scene_solver: ON
-- Option: ENABLE_driver_udp: ON
-- Using CATKIN_DEVEL_PREFIX: /home/jc/catkin_ws/devel/.private/survive_publisher
-- Using CMAKE_PREFIX_PATH: /home/jc/catkin_ws/devel;/opt/ros/noetic
-- This workspace overlays: /home/jc/catkin_ws/devel;/opt/ros/noetic
-- Using PYTHON_EXECUTABLE: /usr/bin/python3
-- Using Debian Python package layout
-- Using empy: /usr/lib/python3/dist-packages/em.py
-- Using CATKIN_ENABLE_TESTING: ON
-- Call enable_testing()
-- Using CATKIN_TEST_RESULTS_DIR: /home/jc/catkin_ws/build/survive_publisher/test_results
-- Found gmock: gmock and gtests will be built
-- Using Python nosetests: /usr/bin/nosetests3
-- catkin 0.8.10
-- BUILD_SHARED_LIBS is on
-- Using these message generators: gencpp;geneus;genlisp;gennodejs;genpy
/opt/ros/noetic/include/opt/ros/noetic/share/xmlrpcpp/cmake/../../../include/xmlrpcpp/usr/include
-- Option: ENABLE_survive-cli: ON
-- Option: ENABLE_api_example: ON
-- Option: ENABLE_sensors-readout: ON
-- Option: ENABLE_survive-solver: ON
-- Option: ENABLE_survive-buttons: ON
-- Using CATKIN_DEVEL_PREFIX: /home/jc/catkin_ws/devel/.private/survive_publisher
-- Using CMAKE_PREFIX_PATH: /home/jc/catkin_ws/devel;/opt/ros/noetic
-- This workspace overlays: /home/jc/catkin_ws/devel;/opt/ros/noetic
-- Using PYTHON_EXECUTABLE: /usr/bin/python3
-- Using Debian Python package layout
-- Using empy: /usr/lib/python3/dist-packages/em.py
-- Using CATKIN_ENABLE_TESTING: ON
-- Call enable_testing()
-- Using CATKIN_TEST_RESULTS_DIR: /home/jc/catkin_ws/build/survive_publisher/test_results
-- Found gmock: gmock and gtests will be built
-- Using Python nosetests: /usr/bin/nosetests3
-- catkin 0.8.10
-- BUILD_SHARED_LIBS is on
-- Using these message generators: gencpp;geneus;genlisp;gennodejs;genpy
/opt/ros/noetic/include/opt/ros/noetic/share/xmlrpcpp/cmake/../../../include/xmlrpcpp/usr/include
CMake Error at /home/jc/catkin_ws/src/libsurvive/tools/ros_publisher/CMakeLists.txt:37 (add_executable):
add_executable cannot create target "survive_publisher_node" because
another target with the same name already exists. The existing target is
an executable created in source directory
"/home/jc/catkin_ws/src/libsurvive/tools/ros_publisher". See documentation
for policy CMP0002 for more details.

CMake Error at /home/jc/catkin_ws/src/libsurvive/tools/ros_publisher/CMakeLists.txt:50 (target_link_libraries):
Attempt to add link library "/opt/ros/noetic/lib/libtf.so" to target
"survive_publisher_node" which is not built in this directory.

This is allowed only when policy CMP0079 is set to NEW.

CMake Error in CMakeLists.txt:
No cmake_minimum_required command is present. A line of code such as

cmake_minimum_required(VERSION 3.16)

should be added at the top of the file. The version specified may be lower
if you wish to support older CMake versions for this project. For more
information run "cmake --help-policy CMP0000".

-- Configuring incomplete, errors occurred!
See also "/home/jc/catkin_ws/build/survive_publisher/CMakeFiles/CMakeOutput.log".
See also "/home/jc/catkin_ws/build/survive_publisher/CMakeFiles/CMakeError.log".
cd /home/jc/catkin_ws/build/survive_publisher; catkin build --get-env survive_publisher | catkin env -si /usr/bin/cmake /home/jc/catkin_ws/src/libsurvive/tools/ros_publisher --no-warn-unused-cli -DCATKIN_DEVEL_PREFIX=/home/jc/catkin_ws/devel/.private/survive_publisher -DCMAKE_INSTALL_PREFIX=/home/jc/catkin_ws/install; cd -

...............................................................................
Failed << survive_publisher:cmake [ Exited with code 1 ]
Failed <<< survive_publisher [ 1.3 seconds ]
[build] Summary: 0 of 1 packages succeeded.
[build] Ignored: None.
[build] Warnings: None.
[build] Abandoned: None.
[build] Failed: 1 packages failed.
[build] Runtime: 1.3 seconds total.

********************************* END **************************************

Desktop (please complete the following information):
Linux Ubuntu

  • Version [20.04.5 LTS]
    ROS Noetic
  • version [1.15.14]

Additional context
ROS is installed correctly and functions as intended using other packages.
We have checked issues: #181 and #229 but they seem different to this issue.

@jcaInciteRobotics
Copy link
Author

Restructuring the libsurvive Ros setup solved this. For anyone curious we restructured the library as follows:

Libsurvive_pub (name of library)

  • launch file for puplisher
  • pakage.xml
  • CMakeLists.txt (rewritten because the old i broken)
  • src
    • libsurvive_pub_node.cc
  • include
    • cnmatrix
    • libsurive (all the .h files from the libsurvive lib)
    • redist

CMakeLists.txt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant