🛠️🐜 Antkeeper superbuild with dependencies included https://antkeeper.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
860 B

  1. # - Try to find SndFile
  2. # Once done this will define
  3. #
  4. # SNDFILE_FOUND - system has SndFile
  5. # SndFile::SndFile - the SndFile target
  6. #
  7. find_path(SNDFILE_INCLUDE_DIR NAMES sndfile.h)
  8. find_library(SNDFILE_LIBRARY NAMES sndfile sndfile-1)
  9. # handle the QUIETLY and REQUIRED arguments and set SNDFILE_FOUND to TRUE if
  10. # all listed variables are TRUE
  11. include(FindPackageHandleStandardArgs)
  12. find_package_handle_standard_args(SndFile DEFAULT_MSG SNDFILE_LIBRARY SNDFILE_INCLUDE_DIR)
  13. if(SNDFILE_FOUND)
  14. add_library(SndFile::SndFile UNKNOWN IMPORTED)
  15. set_target_properties(SndFile::SndFile PROPERTIES
  16. IMPORTED_LOCATION ${SNDFILE_LIBRARY}
  17. INTERFACE_INCLUDE_DIRECTORIES ${SNDFILE_INCLUDE_DIR})
  18. endif()
  19. # show the SNDFILE_INCLUDE_DIR and SNDFILE_LIBRARY variables only in the advanced view
  20. mark_as_advanced(SNDFILE_INCLUDE_DIR SNDFILE_LIBRARY)