ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | Q&A
Ask Your Question

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

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

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

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

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 | 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


Thanks! This worked for me...

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

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

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

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 -0500 )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 -0500 )edit

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

tfoote gravatar image

It's likely that there are conflicting dependencies like in this issue:

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

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools



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

Seen: 2,184 times

Last updated: Jul 24 '19