Deleted Packages

I am in the navigation in 5 days course on the localization unit. Whenever I tried to catkin_make it always gives me this error:

– Could NOT find publish_kinect_tf (missing: publish_kinect_tf_DIR)
– Could not find the required component ‘publish_kinect_tf’. The following CMake error indicates that you either need to install the package with the same name or change your environment so that it can be found.
CMake Error at /opt/ros/noetic/share/catkin/cmake/catkinConfig.cmake:83 (find_package):
Could not find a package configuration file provided by “publish_kinect_tf”
with any of the following names:

publish_kinect_tfConfig.cmake
publish_kinect_tf-config.cmake

Add the installation prefix of “publish_kinect_tf” to CMAKE_PREFIX_PATH or
set “publish_kinect_tf_DIR” to a directory containing one of the above
files. If “publish_kinect_tf” provides a separate development package or
SDK, be sure it has been installed.
Call Stack (most recent call first):
static_transform_publisher/CMakeLists.txt:10 (find_package)

– Configuring incomplete, errors occurred!
See also “/home/user/catkin_ws/build/CMakeFiles/CMakeOutput.log”.
See also “/home/user/catkin_ws/build/CMakeFiles/CMakeError.log”.
Invoking “cmake” failed

I tried to fix it myself but could not and I tried to create the packages that created to problems from scratch and I got more issues.

Is there a way to recover the packages? Also do I need to redo the previous units before I continue?

Hi @omarsahri123, welcome to the community!

I believe publish_kinect_tf is a package you’ve previously created, correct? I looked through the instructions of Units 1 through 4 and found no mention of the package.

If it’s missing from the ~/catkin_ws/src directory, and you still see that message when compiling, then the issue is probably that the ~/catkin_ws/build and ~/catkin_ws/devel directories still have information of the package publish_kinect_tf, and thus the compilation fails.

To solve it, you delete /build and /devel and compile again.

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.