1
0

cpr-config.cmake 903 B

1234567891011121314151617181920212223242526
  1. # - C++ Requests, Curl for People
  2. # This module is a libcurl wrapper written in modern C++.
  3. # It provides an easy, intuitive, and efficient interface to
  4. # a host of networking methods.
  5. #
  6. # Finding this module will define the following variables:
  7. # CPR_FOUND - True if the core library has been found
  8. # CPR_LIBRARIES - Path to the core library archive
  9. # CPR_INCLUDE_DIRS - Path to the include directories. Gives access
  10. # to cpr.h, which must be included in every
  11. # file that uses this interface
  12. find_path(CPR_INCLUDE_DIR
  13. NAMES cpr.h)
  14. find_library(CPR_LIBRARY
  15. NAMES cpr
  16. HINTS ${CPR_LIBRARY_ROOT})
  17. include(FindPackageHandleStandardArgs)
  18. find_package_handle_standard_args(CPR REQUIRED_VARS CPR_LIBRARY CPR_INCLUDE_DIR)
  19. if(CPR_FOUND)
  20. set(CPR_LIBRARIES ${CPR_LIBRARY})
  21. set(CPR_INCLUDE_DIRS ${CPR_INCLUDE_DIR})
  22. endif()