Skip to content

hebaishi/boost-cmake

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Boost-CMake

A simple CMake wrapper around the boost build. This repo can be included as a submodule into any project that requires the boost libraries.

This project can be used as follows:

set(BOOST_REQUIRED_COMPONENTS test program_options)
add_subdirectory(boost-cmake)
find_package(
  Boost
  1.64.0
  COMPONENTS
  program_options
  unit_test_framework
)

You can then add the path to the boost headers to your include directories:

include_directories(${Boost_INCLUDE_DIR})

And link against the boost libraries:

target_link_libraries(${PROJECT_NAME} ${Boost_PROGRAM_OPTIONS_LIBRARY_DEBUG})
target_link_libraries(MyTest ${Boost_UNIT_TEST_FRAMEWORK_LIBRARY_RELEASE})

About

A CMake wrapper around boost

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages