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

Installing ros-melodic-ros-base deletes npm, installing npm deletes ros. How can I have both?

asked 2019-07-23 11:39:09 -0600

tzinke gravatar image

I inherited a system that needs both ROS and npm to be complete. I had to re-flash the embedded computer that they were running on, and so now I am reinstalling and reconfiguring everything. However, when I run sudo apt install ros-melodic-ros-base, it deletes npm during installation. When I run sudo apt install npm, it deletes all of my ros stuff during installation. The person that set it up before doesn't know why this is happening, so he is unable to help me get both packages installed.

Why is this happening? Is there a way to have both? I will gladly give more detail if necessary, just let me know.

Thanks in advance

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
1

answered 2019-07-24 17:33:14 -0600

tzinke gravatar image

I got around the issue by installing nodejs and npm using these three commands:

sudo apt-get install curl python-software-properties
curl -sL https://deb.nodesource.com/setup_12.x | sudo -E bash -
sudo apt-get install nodejs

Not entirely sure why sudo apt-get install npm was problematic. Hopefully that helps someone other than myself!

edit flag offensive delete link more

Comments

Thanks! This worked for me...

hardesh gravatar image hardesh  ( 2020-05-07 14:02:14 -0600 )edit

Thanks. The commands 2, 3 worked for me. nodejs is installed

Lingaa gravatar image Lingaa  ( 2020-05-28 15:58:21 -0600 )edit
1

This solution didn't work for me, as it still requires libssl1.0-dev to install nodejs-dev, which is required by npm. And libssl1.0-dev wipes out ROS

daniyalyasin93 gravatar image daniyalyasin93  ( 2021-03-14 04:44:09 -0600 )edit

I also have problems. nodejs is ok with sudo apt install nodejs, but if I try to install the npm depencies, in particular libssl1.0-dev, it will delete ROS packages.

bach gravatar image bach  ( 2021-08-24 08:57:37 -0600 )edit
1

answered 2019-07-24 16:54:25 -0600

tfoote gravatar image

It's likely that there are conflicting dependencies like in this issue: https://github.com/ros/rosdistro/issu...

You can ask apt to tell you more about why it's uninstalling the other one when it does so. You should copy and paste the output into your question for more help.

edit flag offensive delete link more

Question Tools

3 followers

Stats

Asked: 2019-07-23 11:39:09 -0600

Seen: 2,328 times

Last updated: Jul 24 '19