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

sudo apt install catkin not working.

asked 2017-04-02 15:08:30 -0600

JGHunter gravatar image

Hi, I'm a newbie, so sorry if this is really obvious. I'm following the Tutorials instructions having just installed ROS on Ubuntu Mate. The current step says

$ cd ~/catkin_ws/
$ catkin_make

but when I enter "catkin_make" terminal returns

The program 'catkin_make' is currently not installed. You can install it by typing:
sudo apt install catkin

So I do that, and get

Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help resolve the situation:

The following packages have unmet dependencies:
 catkin : Depends: python-catkin-pkg but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

It then ends at that. How can I fix this and continue with the tutorials?

edit retag flag offensive close merge delete

Comments

what ROS distro are you using????

ΦXocę 웃 Пepeúpa ツ gravatar image ΦXocę 웃 Пepeúpa ツ  ( 2017-04-03 03:51:59 -0600 )edit

5 Answers

Sort by » oldest newest most voted
11

answered 2017-06-20 17:16:18 -0600

130s gravatar image

updated 2017-06-20 17:17:09 -0600

Basically, going through the basic tutoril again making sure to run through all the steps as @bonzi suggests is good.

The program 'catkin_make' is currently not installed. You can install it by typing:
sudo apt install catkin

Unintuitive though, this error can also happen when your terminal can't find the command in directories in ROS_PACKAGE_PATH. So make sure ROS_PACKAGE_PATH is set appropriately (e.g. by source /opt/ros/indigo/setup.bash etc.)

edit flag offensive delete link more
5

answered 2017-08-30 12:13:12 -0600

Ferrera gravatar image

Hi,

I also had this issue. The problem was that I forgot to source my ros environment. Execute the following command in your terminal:

source /opt/ros/kinetic/setup.bash

Try to use catkin as if where already installed. E.g: catkin_make in your workspace.

If works, remember to add this line to your bash echo "source /opt/ros/kinetic/setup.bash" >> ~/.bashrc

edit flag offensive delete link more

Comments

good, it works. :)

lobby gravatar image lobby  ( 2019-09-08 21:40:12 -0600 )edit

i did what you recommended, i first sourced the environment : source /opt/ros/foxy/setup.bash then tried installing catkin using this command : sudo apt install catkin but the terminal responded with issues

Reading package lists... Done Building dependency tree
Reading state information... Done Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming. The following information may help to resolve the situation:

The following packages have unmet dependencies: catkin : Depends: python3-catkin-pkg (>= 0.4.14-2) but it is not going to be installed E: Unable to correct problems, you have held broken packages.

kindly put up your valuable suggestion

hassaanaero gravatar image hassaanaero  ( 2020-11-26 06:55:49 -0600 )edit
4

answered 2017-04-03 03:53:19 -0600

updated 2017-04-03 03:55:06 -0600

How you install the catkin is depending on what ROS distro you have.... for example by indigo, normally as:

$sudo apt-get install ros-<distro_name>-catkin

where distro name are Hydro, Indigo, Kinetic etc, so assuming you have installed indigo then do:

$sudo apt-get install ros-indigo-catkin

instead of

$sudo apt install catkin

edit flag offensive delete link more

Comments

This solved the problem for me

fferri gravatar image fferri  ( 2019-05-21 08:12:13 -0600 )edit

I am trying it for neotic, does not works !! Any idea ?

virgincoder gravatar image virgincoder  ( 2021-07-17 02:00:52 -0600 )edit

The correct name of the ROS distribution is noetic, not neotic.

gvdhoorn gravatar image gvdhoorn  ( 2021-07-17 04:08:55 -0600 )edit
1

answered 2017-04-03 03:46:34 -0600

bonzi gravatar image

updated 2017-04-03 03:48:31 -0600

Hello. Did you follows the tutorial properly, because you have to source your environment. Follow this tutorial here, catkin. Once you have installed the workspace, you need to install ROS dependencies, its up to you to choose.

I installed ROS indigo so you can follow this tutorial ros indigo. Make sure to correctly follow all the instructions mentioned.

edit flag offensive delete link more
0

answered 2020-02-27 11:19:24 -0600

boxer911 gravatar image

You need to source setup files in 'source /opt/ros/<distro>/setup.bash'. Altering <distro> for your ROS version.

edit flag offensive delete link more

Comments

How is your answer different from this older answer https://answers.ros.org/question/2584...

130s gravatar image 130s  ( 2020-03-05 00:35:41 -0600 )edit
1

duplicate.

askkvn gravatar image askkvn  ( 2021-07-09 06:07:45 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2017-04-02 15:08:30 -0600

Seen: 76,532 times

Last updated: Feb 27 '20