# Revision history [back]

When you created your package with roscreate-pkg (as shown in this tutorial: http://ros.org/wiki/ROS/Tutorials/CreatingPackage), it should have created the required Makefile for you. Since you don't have one, you technically have have a malformed ROS package, which is why rosmake won't build it.

Either regenerate your package using roscreate-pkg or just create a Makefile in your package with the following contents:

include $(shell rospack find mk)/cmake.mk  Also for things like OpenCV you should look into using standard find_package syntax as opposed to going through pkg-config. Here's an example snippet from the CMakeLists.txt of a package using that approach: find_package(OpenCV REQUIRED) include_directories(${OPENCV_INCLUDE_DIR})


You may find a similar find_package module is provided by CMake or GTK for using GTK libriaries in a CMake project.