Skip to content

Run roscore error after build in Ubuntu 16.04 #57

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

Closed
echotor opened this issue Mar 30, 2018 · 6 comments
Closed

Run roscore error after build in Ubuntu 16.04 #57

echotor opened this issue Mar 30, 2018 · 6 comments

Comments

@echotor
Copy link

echotor commented Mar 30, 2018

I build the apollo-platform in Ubuntu 16.04, and it passed.
But when I run roscore, it outputs the error like below:

Traceback (most recent call last):
  File "/home/apollo/Apollo/apollo-platform/install_isolated/bin/rosmaster", line 34, in <module>
    import rosmaster
  File "/home/apollo/Apollo/apollo-platform/install_isolated/lib/python2.7/dist-packages/rosmaster/__init__.py", line 35, in <module>
    from .main import rosmaster_main
  File "/home/apollo/Apollo/apollo-platform/install_isolated/lib/python2.7/dist-packages/rosmaster/main.py", line 43, in <module>
    import rosmaster.master
  File "/home/apollo/Apollo/apollo-platform/install_isolated/lib/python2.7/dist-packages/rosmaster/master.py", line 45, in <module>
    import rosgraph.xmlrpc
  File "/home/apollo/Apollo/apollo-platform/install_isolated/lib/python2.7/dist-packages/rosgraph/__init__.py", line 36, in <module>
    from . masterapi import Master, MasterFailure, MasterError, MasterException
  File "/home/apollo/Apollo/apollo-platform/install_isolated/lib/python2.7/dist-packages/rosgraph/masterapi.py", line 49, in <module>
    from rospy.impl.broadcast_manager import BroadcastManager
  File "/home/apollo/Apollo/apollo-platform/install_isolated/lib/python2.7/dist-packages/rospy/__init__.py", line 49, in <module>
    from .client import spin, myargv, init_node, \
  File "/home/apollo/Apollo/apollo-platform/install_isolated/lib/python2.7/dist-packages/rospy/client.py", line 60, in <module>
    import rospy.impl.init
  File "/home/apollo/Apollo/apollo-platform/install_isolated/lib/python2.7/dist-packages/rospy/impl/init.py", line 54, in <module>
    from .tcpros import init_tcpros
  File "/home/apollo/Apollo/apollo-platform/install_isolated/lib/python2.7/dist-packages/rospy/impl/tcpros.py", line 45, in <module>
    import rospy.impl.tcpros_service
  File "/home/apollo/Apollo/apollo-platform/install_isolated/lib/python2.7/dist-packages/rospy/impl/tcpros_service.py", line 65, in <module>
    from broadcast_manager import BroadcastManager
  File "/home/apollo/Apollo/apollo-platform/install_isolated/lib/python2.7/dist-packages/rospy/impl/broadcast_manager.py", line 58, in <module>
    from rospy.impl import participant
  File "/home/apollo/Apollo/apollo-platform/install_isolated/lib/python2.7/dist-packages/rospy/impl/participant.py", line 28, in <module>
    _participant = swig_import_helper()
  File "/home/apollo/Apollo/apollo-platform/install_isolated/lib/python2.7/dist-packages/rospy/impl/participant.py", line 20, in swig_import_helper
    import _participant
ImportError: /home/apollo/Apollo/apollo-platform/install_isolated/lib/_participant.so: undefined symbol: _ZN3ros11Participant8read_msgEv

Should I solve this problem?
I find the issue like #52 #19
But I can not find a solution for this.

@echotor
Copy link
Author

echotor commented Apr 2, 2018

I solve the problem:

  1. build and install fast-rtps follow the build.sh in https://github.com/ApolloAuto/apollo-platform/blob/master/ros/third_party/build.sh
  2. build and install the apollo-platform
  3. build and install _participant.so follow the build.sh in https://github.com/ApolloAuto/apollo-platform/blob/master/ros/third_party/swig_wrapper/build.sh

Then the apollo-platform is built in ubuntu 16.04 successfully.

@echotor echotor closed this as completed Apr 2, 2018
@wlwu92
Copy link

wlwu92 commented Aug 14, 2018

Hi, have you build apollo-ros in ubuntu 16.04 correctly? I also caught the same error, and follow your hint I fixed the error, but I caught another error as follow when I run any ros command.

terminate called after throwing an instance of 'std::bad_alloc'
  what():  std::bad_alloc
Aborted (core dumped)

@echotor
Copy link
Author

echotor commented Sep 12, 2018

NO, I can run correctly. @wlwu92

@gengqx
Copy link

gengqx commented Sep 29, 2018

@wlwu92 Have you solve the problem? I have teh same error.

@gengqx
Copy link

gengqx commented Sep 29, 2018

@echotor Could you push your Ros source folder to your githbub?

@echotor
Copy link
Author

echotor commented Sep 30, 2018

@gengqx Hi, the solve method is:

  1. build and install fast-rtps follow the build.sh in https://github.com/ApolloAuto/apollo-platform/blob/master/ros/third_party/build.sh
  2. build and install the apollo-platform
  3. build and install _participant.so follow the build.sh in https://github.com/ApolloAuto/apollo-platform/blob/master/ros/third_party/swig_wrapper/build.sh

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

3 participants