--- CMakeLists.txt.orig 2020-08-24 16:23:49 UTC +++ CMakeLists.txt @@ -14,6 +14,7 @@ mark_as_advanced(CLEAR CMAKE_INSTALL_BINDIR CMAKE_INSTALL_INCLUDEDIR CMAKE_INSTALL_LIBDIR + CMAKE_INSTALL_LIBEXECDIR ) # @@ -114,7 +115,7 @@ option(INSTALL_EXAMPLES "Install example code." OFF) if(INSTALL_EXAMPLES) install(DIRECTORY octave raw script wav USE_SOURCE_PERMISSIONS - DESTINATION ${CMAKE_INSTALL_DATADIR}/codec2) + DESTINATION share/examples/codec2) endif() @@ -176,6 +177,18 @@ if(UNITTEST) message(STATUS " Speex DSP library: ${SPEEXDSP_LIBRARY}") if(NOT SPEEXDSP_INCLUDE_DIR AND NOT SPEEXDSP_LIBRARY) message(FATAL_ERROR "Speex DSP library not found!") + endif() + + # + # Find samplerate library + # + message(STATUS "Looking for samplerate library.") + find_path(SAMPLERATE_INCLUDE_DIR samplerate.h) + find_library(SAMPLERATE_LIBRARY samplerate) + message(STATUS " samplerate headers: ${SAMPLERATE_INCLUDE_DIR}") + message(STATUS " samplerate library: ${SAMPLERATE_LIBRARY}") + if(NOT SAMPLERATE_INCLUDE_DIR AND NOT SAMPLERATE_LIBRARY) + message(FATAL_ERROR "samplerate library not found!") endif() #