项目作者: omaralvarez

项目描述 :
Conan recipe for dlib library http://dlib.net
高级语言: Python
项目地址: git://github.com/omaralvarez/conan_dlib.git
创建时间: 2018-01-12T09:15:12Z
项目社区:https://github.com/omaralvarez/conan_dlib

开源协议:GNU General Public License v3.0

下载


Download Build Status

conan_dlib

Conan.io package for dlib library

Build packages

  1. $ pip install conan_package_tools
  2. $ python build.py

Reuse the packages

Basic setup

  1. $ conan install dlib/19.19@omaralvarez/stable

Package basic test

  1. $ conan test_package

Example usage in a CMake-based project

Conan and CMake files

  • A sample from conanfile.txt in the root directory:
    ```
    [requires]
    dlib/19.19@omaralvarez/stable

[generators]
cmake

[options]
dlib:enable_blas=False
dlib:enable_lapack=False

  1. * The `CMakeLists.txt` at the root directory:
  2. ```cmake
  3. cmake_minimum_required(VERSION 3.8)
  4. project(project_name C CXX)
  5. include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake)
  6. conan_basic_setup(TARGETS)
  7. ...
  • The CMakeLists.txt of a dependent target:
    1. ...
    2. add_executable(example example.cpp)
    3. target_link_libraries(example CONAN_PKG::dlib)
    4. ...

Running Conan and CMake

  • First, add new remote pointing to the repository:
    1. conan remote add omaralvarez https://api.bintray.com/conan/omaralvarez/public-conan
  • Change directory to the build location and run Conan installation:
    1. conan install .. -s build_type=Release --build=missing
    where the .. points to the project root at the parent directory.
  • Run CMake:
    1. cmake ..