catkin_make and catkin_tools not finding new msg/srv?
When I add a new .msg
(I confirmed for .srv
as well) and running catkin build
, the new file doesn't seem to be processed.
Is this expected, or is there a way to let it find new definition? This doesn't seem to be is also a case with catkin_make
.
CWS_PROOV=/tmp/cws_proof
mkdir -p "$CWS_PROOV"/src
cd "$CWS_PROOV"/src
git clone git@github.com:130s/prooving_grounds.git <-- Merely beginner_tutorials with minor change
cd "$CWS_PROOV"
catkin b
ll ./devel/lib/python2.7/dist-packages/beginner_tutorials/msg
source devel/setup.bash
roscd beginner_tutorials/
echo "int64 num" > msg/Num4.msg
cd -
catkin b
ll ./devel/lib/python2.7/dist-packages/beginner_tutorials/msg
total 24K
drwxrwxr-x 2 rosnoodle rosnoodle 4.0K Mar 17 14:23 ./
drwxrwxr-x 3 rosnoodle rosnoodle 4.0K Mar 17 14:23 ../
lrwxrwxrwx 1 rosnoodle rosnoodle 111 Mar 17 14:23 __init__.py -> /tmp/cws_proof/devel/.private/beginner_tutorials/lib/python2.7/dist-packages/beginner_tutorials/msg/__init__.py
lrwxrwxrwx 1 rosnoodle rosnoodle 108 Mar 17 14:23 _Num2.py -> /tmp/cws_proof/devel/.private/beginner_tutorials/lib/python2.7/dist-packages/beginner_tutorials/msg/_Num2.py
lrwxrwxrwx 1 rosnoodle rosnoodle 108 Mar 17 14:23 _Num3.py -> /tmp/cws_proof/devel/.private/beginner_tutorials/lib/python2.7/dist-packages/beginner_tutorials/msg/_Num3.py
lrwxrwxrwx 1 rosnoodle rosnoodle 107 Mar 17 14:23 _Num.py -> /tmp/cws_proof/devel/.private/beginner_tutorials/lib/python2.7/dist-packages/beginner_tutorials/msg/_Num.py
ll /tmp/cws_proof/devel/.private/beginner_tutorials/lib/python2.7/dist-packages/beginner_tutorials/msg
(Num4 not found)
ll ./devel/share/gennodejs/ros/beginner_tutorials/msg
(Num4 not found)
ll ./devel/share/common-lisp/ros/beginner_tutorials/msg
(Num4 not found)
$ apt-cache policy python-catkin-tools|grep Inst
Installed: 0.4.4-1
To work this around I'm removing build
, devel
before building. After modifying CMakeLists.txt
also works for me.
Seen on Xenial Kinetic and Trusty Indigo.
UPDATE After listing all .msg
s and .srv
s in CMakeLists.txt both catkin_make
and catkin build
seem to find the new files and update to the existing files. It'd be still nice if there's a way to achieve the same without listing them.
just making sure: you did add
Num4.msg
to theadd_message_files(..)
call inCMakeLists.txt
, correct?Nope, only passing
DIRECTORY
(exact line in my sample). Thanks to this answer (aka yours :)) I've been able to build msgs without specifingFILES
. But added files aren't the case, which is my issue.