File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11# Project dependencies
22find_package (Armadillo REQUIRED )
33find_package (Boost REQUIRED COMPONENTS regex serialization )
4+ find_package (MLPACK REQUIRED )
45find_package (OpenMP REQUIRED )
56find_package (Python3 REQUIRED COMPONENTS Development NumPy )
67
Original file line number Diff line number Diff line change 1+ # Find the mlpack includes and library
2+ #
3+ # This module defines the following IMPORTED targets:
4+ #
5+ # mlpack::mlpack - The "mlpack" library, if found.
6+ #
7+ # This module will set the following variables in your project:
8+ #
9+ # MLPACK_INCLUDE_DIRS - where to find <mlpack/core.hpp>, etc.
10+ # MLPACK_FOUND - True if the mlpack library has been found.
11+
12+ # Use pkg-config (if available) to get the library directories and then use
13+ # these values as hints for find_path() and find_library() functions.
14+ find_package (PkgConfig QUIET )
15+ if (PKG_CONFIG_FOUND)
16+ pkg_check_modules (PC_MLPACK QUIET mlpack )
17+ endif ()
18+
19+ find_path (
20+ MLPACK_INCLUDE_DIR mlpack
21+ HINTS ${PC_MLPACK_INCLUDEDIR} ${PC_MLPACK_INCLUDE_DIRS}
22+ PATH_SUFFIXES include
23+ )
24+
25+ if (PC_MLPACK_VERSION)
26+ # Version extracted from pkg-config
27+ set (MLPACK_VERSION_STRING ${PC_MLPACK_VERSION} )
28+ endif ()
29+
30+ # Handle find_package() arguments (i.e. QUIETLY and REQUIRED) and set
31+ # MLPACK_FOUND to TRUE if all listed variables are filled.
32+ include (FindPackageHandleStandardArgs )
33+ find_package_handle_standard_args (
34+ MLPACK
35+ REQUIRED_VARS MLPACK_INCLUDE_DIR
36+ VERSION_VAR MLPACK_VERSION_STRING
37+ )
38+
39+ set (MLPACK_INCLUDE_DIRS ${MLPACK_INCLUDE_DIR} )
40+ mark_as_advanced (MLPACK_INCLUDE_DIR )
You can’t perform that action at this time.
0 commit comments