Skip to content

Instantly share code, notes, and snippets.

@yuzhangbit
Created October 21, 2018 09:17
Show Gist options
  • Save yuzhangbit/7737ab6f0f5c2fa1d7b1bad3cc068ab7 to your computer and use it in GitHub Desktop.
Save yuzhangbit/7737ab6f0f5c2fa1d7b1bad3cc068ab7 to your computer and use it in GitHub Desktop.
cmake_minimum_required(VERSION 2.8)
project(example)
set(CMAKE_CXX_STANDARD 11)
find_package(PythonLibs 2.7)
find_package(catkin REQUIRED COMPONENTS pybind11_catkin)
include_directories(
include
${catkin_INCLUDE_DIRS}
${PYTHON_INCLUDE_DIRS}
)
CATKIN_PACKAGE(
INCLUDE_DIRS include
CATKIN_DEPENDS pybind11_catkin
)
add_library(example
src/example.cpp)
target_link_libraries(example
${PYTHON_LIBRARIES}
${catkin_LIBRARIES})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment