ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
1

winros_make with Boost 1.56 and VS2013 x64

asked 2016-03-23 03:26:36 -0500

Atlancer gravatar image

updated 2016-03-23 04:06:43 -0500

gvdhoorn gravatar image

Hi, I was trying to compile win_ros with Boost 1.56 and VS2013 x64 following this guide: http://answers.ros.org/question/19622... . However, I end up getting the following error during linking stage:

rospack.cpp.obj : error LNK2019: unresolved external symbol "__declspec(dllimport) void __cdecl boost::filesystem3::path_traits::convert(char const *,char const *,class std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> > &,class std::codecvt<wchar_t,char,int> const &)"

Can anyone help me to figure out how to resolve it? l will be really grateful for any help! Here is the full output:

cmake -G "NMake Makefiles" -C "D:\workspace\ws\config.cmake" -DCMAKE_USER_MAKE_RULES_OVERRIDE:STRING="C:\Python27_64\lib\site-packages\win_ros\cmake\MsvcOverrides.cmake" -DCATKIN_DEVEL_PREFIX=D:\workspace\ws\devel D:\workspace\ws\src

loading initial cache file D:\workspace\ws\config.cmake
-- The C compiler identification is MSVC 18.0.40629.0
-- The CXX compiler identification is MSVC 18.0.40629.0
-- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio 12.0/VC/bin/amd64/cl.exe
-- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio 12.0/VC/bin/amd64/cl.exe -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: C:/Program Files (x86)/Microsoft Visual Studio 12.0/VC/bin/amd64/cl.exe
-- Check for working CXX compiler: C:/Program Files (x86)/Microsoft Visual Studio 12.0/VC/bin/amd64/cl.exe -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Using CATKIN_DEVEL_PREFIX: D:/workspace/ws/devel
-- Using CMAKE_PREFIX_PATH: C:/opt/rosdeps/hydro/x64
-- Found PythonInterp: C:/Python27_64/python.exe (found version "2.7.11")
-- Using PYTHON_EXECUTABLE: C:/Python27_64/python.exe
-- Using default Python package layout
-- Found PY_em: C:\Python27_64\lib\site-packages\empy-3.3.2-py2.7.egg\em.pyc
-- Using CATKIN_ENABLE_TESTING: ON
-- Call enable_testing()
-- Using CATKIN_TEST_RESULTS_DIR: D:/workspace/ws/build/test_results
-- Looking for include file pthread.h
-- Looking for include file pthread.h - not found
-- Found Threads: TRUE
-- Found gtest sources under 'D:/workspace/ws/src/gtest': gtests will be built
-- catkin 0.5.78
-- BUILD_SHARED_LIBS is on
-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-- ~~  traversing 81 packages in topological order:
-- ~~  - common_msgs (metapackage)
-- ~~  - cpp_common
-- ~~  - genmsg
-- ~~  - gencpp
-- ~~  - genlisp
-- ~~  - genpy
-- ~~  - message_generation
-- ~~  - message_runtime
-- ~~  - mingw_cross
-- ~~  - mk
-- ~~  - ros (metapackage)
-- ~~  - ros_comm (metapackage)
-- ~~  - rosbash
-- ~~  - rosboost_cfg
-- ~~  - rosbuild
-- ~~  - rosclean
-- ~~  - roscpp_core (metapackage)
-- ~~  - roscpp_traits
-- ~~  - roscreate
-- ~~  - rosgraph
-- ~~  - roslang
-- ~~  - roslaunch
-- ~~  - rosmake
-- ~~  - rosmaster
-- ~~  - rosmsg
-- ~~  - rospack
-- ~~  - roslib
-- ~~  - rosparam
-- ~~  - rospy
-- ~~  - rosrun
-- ~~  - rosservice
-- ~~  - rostime
-- ~~  - roscpp_serialization
-- ~~  - rosunit
-- ~~  - rosconsole
-- ~~  - rostest
-- ~~  - std_msgs
-- ~~  - actionlib_msgs
-- ~~  - diagnostic_msgs
-- ~~  - geometry_msgs
-- ~~  - nav_msgs
-- ~~  - rosgraph_msgs
-- ~~  - sensor_msgs
-- ~~  - shape_msgs
-- ~~  - std_srvs
-- ~~  - stereo_msgs
-- ~~  - test_roslib_comm
-- ~~  - trajectory_msgs
-- ~~  - visualization_msgs
-- ~~  - win_boost
-- ~~  - win_bzip2
-- ~~  - win_dateutil
-- ~~  - win_eigen
-- ~~  - win_empy
-- ~~  - win_mercurial
-- ~~  - win_pyyaml
-- ~~  - win_python_build_tools
-- ~~  - win_ros (metapackage)
-- ~~  - win_tinyxml
-- ~~  - winros_create_msg_pkg
-- ~~  - winros_create_pkg
-- ~~  - xmlrpcpp
-- ~~  - roscpp
-- ~~  - rosout
-- ~~  - actionlib
-- ~~  - message_filters
-- ~~  - rosnode
-- ~~  - rostopic
-- ~~  - roswtf
-- ~~  - test_roscpp
-- ~~  - test_rosgraph
-- ~~  - test_roslaunch
-- ~~  - test_rosmaster
-- ~~  - test_rosparam
-- ~~  - test_rospy
-- ~~  - test_rosservice
-- ~~  - topic_tools
-- ~~  - rosbag
-- ~~  - test_rosbag
-- ~~  - win_roscpp_tutorials
-- ~~  - msvc_runtime
-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-- +++ processing catkin metapackage: 'common_msgs'
-- ==> add_subdirectory(common_msgs/common_msgs)
-- +++ processing catkin package: 'cpp_common'
-- ==> add_subdirectory(roscpp_core/cpp_common)
-- Looking for execinfo.h
-- Looking for execinfo.h - not found
-- Performing Test HAVE_CXXABI_H
-- Performing Test HAVE_CXXABI_H - Failed
-- Looking for backtrace
-- Looking for backtrace - not found
-- +++ processing catkin package: 'genmsg'
-- ==> add_subdirectory(genmsg)
-- +++ processing catkin package: 'gencpp'
-- ==> add_subdirectory(gencpp)
-- +++ processing catkin package: 'genlisp'
-- ==> add_subdirectory ...
(more)
edit retag flag offensive close merge delete

Comments

@Atlancer: please use the Preformatted text button (the one with 101010 on it) for console copy/pastes. No need for the html :).

gvdhoorn gravatar image gvdhoorn  ( 2016-03-23 04:07:57 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
2

answered 2016-03-24 20:03:20 -0500

Atlancer gravatar image

updated 2016-03-26 01:20:16 -0500

I was able to narrow down the problem: it appears that I was using the wrong headers (the ones for Boost 1.47 instead of Boost 1.56). More info (for anyone interested) can be found in my post on Stackoverflow here: http://stackoverflow.com/questions/36... . To fix the problem I just copied all the headers from boost_1_56_0 folder to C:\opt\rosdeps\hydro\x64\include.

Update 1: Also, during the compilation I encountered the error in timer.cpp and wall_timer.cpp which indicated that conversion from ros::VoidConstPtr to bool was not possible. To fix the error I manually added an explicit cast to bool:

impl_->has_tracked_object_ = (bool) ops.tracked_object;

Then, I was finally able to compile everything.

Update 2: You also need to include boost_chrono-mt.dll into rosdeps/libs folder (just copy it there, no need to add it to any of the .CMake files). It turns out that boost_date_time-mt.dll depends on it at runtime. It will save you 10+ hours of debugging with Dependency Walker.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2016-03-23 03:26:36 -0500

Seen: 471 times

Last updated: Mar 26 '16