summaryrefslogtreecommitdiff
path: root/lib/libsamplerate/libsamplerate-0.2.2/cmake
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libsamplerate/libsamplerate-0.2.2/cmake')
-rwxr-xr-xlib/libsamplerate/libsamplerate-0.2.2/cmake/ClipMode.cmake81
-rwxr-xr-xlib/libsamplerate/libsamplerate-0.2.2/cmake/FindFFTW3.cmake88
-rwxr-xr-xlib/libsamplerate/libsamplerate-0.2.2/cmake/FindFLAC.cmake63
-rwxr-xr-xlib/libsamplerate/libsamplerate-0.2.2/cmake/FindOgg.cmake57
-rwxr-xr-xlib/libsamplerate/libsamplerate-0.2.2/cmake/FindOpus.cmake64
-rwxr-xr-xlib/libsamplerate/libsamplerate-0.2.2/cmake/FindSndFile.cmake57
-rwxr-xr-xlib/libsamplerate/libsamplerate-0.2.2/cmake/FindVorbis.cmake204
-rwxr-xr-xlib/libsamplerate/libsamplerate-0.2.2/cmake/SampleRateConfig.cmake.in1
8 files changed, 615 insertions, 0 deletions
diff --git a/lib/libsamplerate/libsamplerate-0.2.2/cmake/ClipMode.cmake b/lib/libsamplerate/libsamplerate-0.2.2/cmake/ClipMode.cmake
new file mode 100755
index 00000000..d1f71de0
--- /dev/null
+++ b/lib/libsamplerate/libsamplerate-0.2.2/cmake/ClipMode.cmake
@@ -0,0 +1,81 @@
+macro(CLIP_MODE)
+
+ set(CLIP_MODE_POSITIVE_MESSAGE "Target processor clips on positive float to int conversion")
+ set(CLIP_MODE_NEGATIVE_MESSAGE "Target processor clips on negative float to int conversion")
+
+ message(STATUS "Checking processor clipping capabilities...")
+
+ if(CMAKE_CROSSCOMPILING)
+
+ set(CLIP_MSG "disabled")
+ set(CPU_CLIPS_POSITIVE FALSE CACHE BOOL ${CLIP_MODE_POSITIVE_MESSAGE})
+ set(CPU_CLIPS_NEGATIVE FALSE CACHE BOOL ${CLIP_MODE_NEGATIVE_MESSAGE})
+
+ else()
+ include(CheckCSourceRuns)
+ include(CMakePushCheckState)
+ cmake_push_check_state(RESET)
+
+ if(MATH_LIBRARY)
+ list(APPEND CMAKE_REQUIRED_LIBRARIES ${MATH_LIBRARY})
+ endif()
+
+ check_c_source_runs(
+ "
+ #include <math.h>
+ int main (void)
+ { double fval ;
+ int k, ival ;
+
+ fval = 1.0 * 0x7FFFFFFF ;
+ for (k = 0 ; k < 100 ; k++)
+ { ival = (lrint (fval)) >> 24 ;
+ if (ival != 127)
+ return 1 ;
+
+ fval *= 1.2499999 ;
+ } ;
+
+ return 0 ;
+ }
+ "
+ CPU_CLIPS_POSITIVE)
+
+ check_c_source_runs(
+ "
+ #include <math.h>
+ int main (void)
+ { double fval ;
+ int k, ival ;
+
+ fval = -8.0 * 0x10000000 ;
+ for (k = 0 ; k < 100 ; k++)
+ { ival = (lrint (fval)) >> 24 ;
+ if (ival != -128)
+ return 1 ;
+
+ fval *= 1.2499999 ;
+ } ;
+
+ return 0 ;
+ }
+ "
+ CPU_CLIPS_NEGATIVE)
+
+ cmake_pop_check_state()
+
+ if(CPU_CLIPS_POSITIVE AND CPU_CLIPS_NEGATIVE)
+ set(CLIP_MSG "both")
+ elseif(CPU_CLIPS_POSITIVE)
+ set(CLIP_MSG "positive")
+ elseif(CPU_CLIPS_NEGATIVE)
+ set(CLIP_MSG "negative")
+ else()
+ set(CLIP_MSG "none")
+ endif()
+
+ endif()
+
+ message(STATUS "Checking processor clipping capabilities... ${CLIP_MSG}")
+
+endmacro()
diff --git a/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindFFTW3.cmake b/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindFFTW3.cmake
new file mode 100755
index 00000000..169d4a64
--- /dev/null
+++ b/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindFFTW3.cmake
@@ -0,0 +1,88 @@
+# Adapted from: https://github.com/wjakob/layerlab/blob/master/cmake/FindFFTW.cmake
+
+# Copyright (c) 2015, Wenzel Jakob
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions are met:
+#
+# * Redistributions of source code must retain the above copyright notice, this
+# list of conditions and the following disclaimer.
+#
+# * Redistributions in binary form must reproduce the above copyright notice,
+# this list of conditions and the following disclaimer in the documentation
+# and/or other materials provided with the distribution.
+#
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
+# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+# - Find FFTW3
+# Find the native FFTW3 includes and library
+#
+# Cache variables:
+#
+# FFTW3_INCLUDE_DIR - where to find fftw3.h
+# FFTW3_LIBRARY - Path to FFTW3 libray.
+# FFTW3_ROOT - Root of FFTW3 installation.
+#
+# User variables:
+#
+# FFTW3_INCLUDE_DIRS - where to find fftw3.h
+# FFTW3_LIBRARIES - List of libraries when using FFTW3.
+# FFTW3_FOUND - True if FFTW3 found.
+
+
+if(FFTW3_INCLUDE_DIR)
+ # Already in cache, be silent
+ set(FFTW3_FIND_QUIETLY TRUE)
+endif(FFTW3_INCLUDE_DIR)
+
+find_package(PkgConfig QUIET)
+pkg_check_modules(PC_FFTW3 QUIET fftw3)
+
+set(FFTW3_VERSION ${PC_FFTW3_VERSION})
+
+find_path(FFTW3_INCLUDE_DIR fftw3.h
+ HINTS
+ ${PC_FFTW3_INCLUDEDIR}
+ ${PC_FFTW3_INCLUDE_DIRS}
+ ${FFTW3_ROOT})
+
+find_library(FFTW3_LIBRARY NAMES fftw3
+ HINTS
+ ${PC_FFTW3_LIBDIR}
+ ${PC_FFTW3_LIBRARY_DIRS}
+ ${FFTW3_ROOT})
+
+# handle the QUIETLY and REQUIRED arguments and set FFTW3_FOUND to TRUE if
+# all listed variables are TRUE
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(FFTW3
+ REQUIRED_VARS
+ FFTW3_LIBRARY
+ FFTW3_INCLUDE_DIR
+ VERSION_VAR
+ FFTW3_VERSION)
+
+if(FFTW3_FOUND)
+ set(FFTW3_LIBRARIES ${FFTW3_LIBRARY})
+ set(FFTW3_INCLUDE_DIRS ${FFTW3_INCLUDE_DIR})
+
+ if(NOT TARGET FFTW3::fftw3)
+ add_library(FFTW3::fftw3 UNKNOWN IMPORTED)
+ set_target_properties(FFTW3::fftw3 PROPERTIES
+ INTERFACE_INCLUDE_DIRECTORIES "${FFTW3_INCLUDE_DIR}"
+ IMPORTED_LOCATION "${FFTW3_LIBRARY}"
+ )
+ endif()
+endif()
+
+mark_as_advanced(FFTW3_LIBRARY FFTW3_INCLUDE_DIR)
diff --git a/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindFLAC.cmake b/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindFLAC.cmake
new file mode 100755
index 00000000..148e40e8
--- /dev/null
+++ b/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindFLAC.cmake
@@ -0,0 +1,63 @@
+# - Find FLAC
+# Find the native FLAC includes and libraries
+#
+# FLAC_INCLUDE_DIRS - where to find FLAC headers.
+# FLAC_LIBRARIES - List of libraries when using libFLAC.
+# FLAC_FOUND - True if libFLAC found.
+# FLAC_DEFINITIONS - FLAC compile definitons
+
+if(FLAC_INCLUDE_DIR)
+ # Already in cache, be silent
+ set(FLAC_FIND_QUIETLY TRUE)
+endif()
+
+find_package(Ogg QUIET)
+
+find_package(PkgConfig QUIET)
+pkg_check_modules(PC_FLAC QUIET flac)
+
+set(FLAC_VERSION ${PC_FLAC_VERSION})
+
+find_path(FLAC_INCLUDE_DIR FLAC/stream_decoder.h
+ HINTS
+ ${PC_FLAC_INCLUDEDIR}
+ ${PC_FLAC_INCLUDE_DIRS}
+ ${FLAC_ROOT})
+
+# MSVC built libraries can name them *_static, which is good as it
+# distinguishes import libraries from static libraries with the same extension.
+find_library(FLAC_LIBRARY
+ NAMES
+ FLAC
+ libFLAC
+ libFLAC_dynamic
+ libFLAC_static
+ HINTS
+ ${PC_FLAC_LIBDIR}
+ ${PC_FLAC_LIBRARY_DIRS}
+ ${FLAC_ROOT})
+
+# Handle the QUIETLY and REQUIRED arguments and set FLAC_FOUND to TRUE if
+# all listed variables are TRUE.
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(FLAC
+ REQUIRED_VARS
+ FLAC_LIBRARY
+ FLAC_INCLUDE_DIR
+ Ogg_FOUND
+ VERSION_VAR
+ FLAC_VERSION)
+
+if(FLAC_FOUND)
+ set(FLAC_INCLUDE_DIRS ${FLAC_INCLUDE_DIR} ${Ogg_INCLUDE_DIRS})
+ set(FLAC_LIBRARIES ${FLAC_LIBRARY} ${Ogg_LIBRARIES})
+ if(NOT TARGET FLAC::FLAC)
+ add_library(FLAC::FLAC UNKNOWN IMPORTED)
+ set_target_properties(FLAC::FLAC PROPERTIES
+ INTERFACE_INCLUDE_DIRECTORIES "${FLAC_INCLUDE_DIR}"
+ IMPORTED_LOCATION "${FLAC_LIBRARY}"
+ INTERFACE_LINK_LIBRARIES Ogg::ogg)
+ endif()
+endif()
+
+mark_as_advanced(FLAC_INCLUDE_DIR FLAC_LIBRARY)
diff --git a/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindOgg.cmake b/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindOgg.cmake
new file mode 100755
index 00000000..ed6045e8
--- /dev/null
+++ b/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindOgg.cmake
@@ -0,0 +1,57 @@
+# - Find ogg
+# Find the native ogg includes and libraries
+#
+# Ogg_INCLUDE_DIRS - where to find ogg.h, etc.
+# Ogg_LIBRARIES - List of libraries when using ogg.
+# Ogg_FOUND - True if ogg found.
+
+if(Ogg_INCLUDE_DIR)
+ # Already in cache, be silent
+ set(Ogg_FIND_QUIETLY TRUE)
+endif()
+
+find_package(PkgConfig QUIET)
+pkg_check_modules(PC_Ogg QUIET ogg)
+
+set(Ogg_VERSION ${PC_Ogg_VERSION})
+
+find_path(Ogg_INCLUDE_DIR ogg/ogg.h
+ HINTS
+ ${PC_Ogg_INCLUDEDIR}
+ ${PC_Ogg_INCLUDE_DIRS}
+ ${Ogg_ROOT})
+# MSVC built ogg may be named ogg_static.
+# The provided project files name the library with the lib prefix.
+find_library(Ogg_LIBRARY
+ NAMES
+ ogg
+ ogg_static
+ libogg
+ libogg_static
+ HINTS
+ ${PC_Ogg_LIBDIR}
+ ${PC_Ogg_LIBRARY_DIRS}
+ ${Ogg_ROOT})
+# Handle the QUIETLY and REQUIRED arguments and set Ogg_FOUND
+# to TRUE if all listed variables are TRUE.
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(Ogg
+ REQUIRED_VARS
+ Ogg_LIBRARY
+ Ogg_INCLUDE_DIR
+ VERSION_VAR
+ Ogg_VERSION)
+
+if(Ogg_FOUND)
+ set(Ogg_LIBRARIES ${Ogg_LIBRARY})
+ set(Ogg_INCLUDE_DIRS ${Ogg_INCLUDE_DIR})
+
+ if(NOT TARGET Ogg::ogg)
+ add_library(Ogg::ogg UNKNOWN IMPORTED)
+ set_target_properties(Ogg::ogg PROPERTIES
+ INTERFACE_INCLUDE_DIRECTORIES "${Ogg_INCLUDE_DIR}"
+ IMPORTED_LOCATION "${Ogg_LIBRARY}")
+ endif()
+endif()
+
+mark_as_advanced(Ogg_INCLUDE_DIR Ogg_LIBRARY)
diff --git a/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindOpus.cmake b/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindOpus.cmake
new file mode 100755
index 00000000..98b556a9
--- /dev/null
+++ b/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindOpus.cmake
@@ -0,0 +1,64 @@
+# - Find opus
+# Find the native opus includes and libraries
+#
+# OPUS_INCLUDE_DIRS - where to find opus.h, etc.
+# OPUS_LIBRARIES - List of libraries when using opus.
+# OPUS_FOUND - True if Opus found.
+
+if(OPUS_INCLUDE_DIR)
+ # Already in cache, be silent
+ set(OPUS_FIND_QUIETLY TRUE)
+endif()
+
+find_package(Ogg QUIET)
+
+find_package(PkgConfig QUIET)
+pkg_check_modules(PC_OPUS QUIET opus)
+
+set(OPUS_VERSION ${PC_OPUS_VERSION})
+
+find_path(OPUS_INCLUDE_DIR opus/opus.h
+ HINTS
+ ${PC_OPUS_INCLUDEDIR}
+ ${PC_OPUS_INCLUDE_DIRS}
+ ${OPUS_ROOT})
+
+# MSVC built opus may be named opus_static.
+# The provided project files name the library with the lib prefix.
+
+find_library(OPUS_LIBRARY
+ NAMES
+ opus
+ opus_static
+ libopus
+ libopus_static
+ HINTS
+ ${PC_OPUS_LIBDIR}
+ ${PC_OPUS_LIBRARY_DIRS}
+ ${OPUS_ROOT})
+
+# Handle the QUIETLY and REQUIRED arguments and set OPUS_FOUND
+# to TRUE if all listed variables are TRUE.
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(Opus
+ REQUIRED_VARS
+ OPUS_LIBRARY
+ OPUS_INCLUDE_DIR
+ Ogg_FOUND
+ VERSION_VAR
+ OPUS_VERSION)
+
+if(OPUS_FOUND)
+ set(OPUS_LIBRARIES ${OPUS_LIBRARY})
+ set(OPUS_INCLUDE_DIRS ${OPUS_INCLUDE_DIR} ${Ogg_INCLUDE_DIRS})
+
+ if(NOT TARGET Opus::opus)
+ add_library(Opus::opus UNKNOWN IMPORTED)
+ set_target_properties(Opus::opus PROPERTIES
+ INTERFACE_INCLUDE_DIRECTORIES "${OPUS_INCLUDE_DIR}"
+ IMPORTED_LOCATION "${OPUS_LIBRARY}"
+ INTERFACE_LINK_LIBRARIES Ogg::ogg)
+ endif()
+endif()
+
+mark_as_advanced(OPUS_INCLUDE_DIR OPUS_LIBRARY)
diff --git a/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindSndFile.cmake b/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindSndFile.cmake
new file mode 100755
index 00000000..4f098ce8
--- /dev/null
+++ b/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindSndFile.cmake
@@ -0,0 +1,57 @@
+# Variables defined:
+# SNDFILE_FOUND
+# SNDFILE_INCLUDE_DIR
+# SNDFILE_LIBRARY
+#
+# Environment variables used:
+# SNDFILE_ROOT
+
+if(SndFile_INCLUDE_DIR)
+ # Already in cache, be silent
+ set(SndFile_FIND_QUIETLY TRUE)
+endif(SndFile_INCLUDE_DIR)
+
+find_package(PkgConfig QUIET)
+pkg_check_modules(PC_SndFile QUIET sndfile)
+
+set(SndFile_VERSION ${PC_SndFile_VERSION})
+
+find_package(Vorbis COMPONENTS Enc QUIET)
+find_package(FLAC QUIET)
+find_package(Opus QUIET)
+
+find_path(SndFile_INCLUDE_DIR sndfile.h
+ HINTS
+ ${PC_SndFile_INCLUDEDIR}
+ ${PC_SndFile_INCLUDE_DIRS}
+ ${SndFile_ROOT})
+
+find_library(SndFile_LIBRARY NAMES sndfile
+ HINTS
+ ${PC_SndFile_LIBDIR}
+ ${PC_SndFile_LIBRARY_DIRS}
+ ${SndFile_ROOT})
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(SndFile
+ REQUIRED_VARS
+ SndFile_LIBRARY
+ SndFile_INCLUDE_DIR
+ VERSION_VAR
+ SndFile_VERSION)
+
+if(SndFile_FOUND)
+
+ set(SndFile_LIBRARIES ${SndFile_LIBRARY} ${Vorbis_Enc_LIBRARIES} ${FLAC_LIBRARIES} ${OPUS_LIBRARIES})
+ set(SndFile_INCLUDE_DIRS ${SndFile_INCLUDE_DIR} ${Vorbis_Enc_INCLUDE_DIRS} ${FLAC_INCLUDE_DIRS} ${OPUS_INCLUDE_DIRS})
+
+ if(NOT TARGET SndFile::sndfile)
+ add_library(SndFile::sndfile UNKNOWN IMPORTED)
+ set_target_properties(SndFile::sndfile PROPERTIES
+ INTERFACE_INCLUDE_DIRECTORIES "${SndFile_INCLUDE_DIR}"
+ IMPORTED_LOCATION "${SndFile_LIBRARY}"
+ INTERFACE_LINK_LIBRARIES "Vorbis::vorbisenc;Opus::opus;FLAC::FLAC")
+ endif()
+endif()
+
+mark_as_advanced(SndFile_LIBRARY SndFile_INCLUDE_DIR)
diff --git a/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindVorbis.cmake b/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindVorbis.cmake
new file mode 100755
index 00000000..b952574b
--- /dev/null
+++ b/lib/libsamplerate/libsamplerate-0.2.2/cmake/FindVorbis.cmake
@@ -0,0 +1,204 @@
+#[=======================================================================[.rst:
+FindVorbis
+----------
+
+Finds the native vorbis, vorbisenc amd vorbisfile includes and libraries.
+
+Imported Targets
+^^^^^^^^^^^^^^^^
+
+This module provides the following imported targets, if found:
+
+``Vorbis::vorbis``
+ The Vorbis library
+``Vorbis::vorbisenc``
+ The VorbisEnc library
+``Vorbis::vorbisfile``
+ The VorbisFile library
+
+Result Variables
+^^^^^^^^^^^^^^^^
+
+This will define the following variables:
+
+``Vorbis_Vorbis_INCLUDE_DIRS``
+ List of include directories when using vorbis.
+``Vorbis_Enc_INCLUDE_DIRS``
+ List of include directories when using vorbisenc.
+``Vorbis_File_INCLUDE_DIRS``
+ List of include directories when using vorbisfile.
+``Vorbis_Vorbis_LIBRARIES``
+ List of libraries when using vorbis.
+``Vorbis_Enc_LIBRARIES``
+ List of libraries when using vorbisenc.
+``Vorbis_File_LIBRARIES``
+ List of libraries when using vorbisfile.
+``Vorbis_FOUND``
+ True if vorbis and requested components found.
+``Vorbis_Vorbis_FOUND``
+ True if vorbis found.
+``Vorbis_Enc_FOUND``
+ True if vorbisenc found.
+``Vorbis_Enc_FOUND``
+ True if vorbisfile found.
+
+Cache variables
+^^^^^^^^^^^^^^^
+
+The following cache variables may also be set:
+
+``Vorbis_Vorbis_INCLUDE_DIR``
+ The directory containing ``vorbis/vorbis.h``.
+``Vorbis_Enc_INCLUDE_DIR``
+ The directory containing ``vorbis/vorbisenc.h``.
+``Vorbis_File_INCLUDE_DIR``
+ The directory containing ``vorbis/vorbisenc.h``.
+``Vorbis_Vorbis_LIBRARY``
+ The path to the vorbis library.
+``Vorbis_Enc_LIBRARY``
+ The path to the vorbisenc library.
+``Vorbis_File_LIBRARY``
+ The path to the vorbisfile library.
+
+Hints
+^^^^^
+
+A user may set ``Vorbis_ROOT`` to a vorbis installation root to tell this module where to look.
+
+#]=======================================================================]
+
+if(Vorbis_Vorbis_INCLUDE_DIR)
+ # Already in cache, be silent
+ set(Vorbis_FIND_QUIETLY TRUE)
+endif()
+
+set(Vorbis_Vorbis_FIND_QUIETLY TRUE)
+set(Vorbis_Enc_FIND_QUIETLY TRUE)
+set(Vorbis_File_FIND_QUIETLY TRUE)
+
+find_package(Ogg QUIET)
+
+find_package(PkgConfig QUIET)
+pkg_check_modules(PC_Vorbis_Vorbis QUIET vorbis)
+pkg_check_modules(PC_Vorbis_Enc QUIET vorbisenc)
+pkg_check_modules(PC_Vorbis_File QUIET vorbisfile)
+
+set(Vorbis_VERSION ${PC_Vorbis_Vorbis_VERSION})
+
+find_path(Vorbis_Vorbis_INCLUDE_DIR vorbis/codec.h
+ HINTS
+ ${PC_Vorbis_Vorbis_INCLUDEDIR}
+ ${PC_Vorbis_Vorbis_INCLUDE_DIRS}
+ ${Vorbis_ROOT})
+
+find_path(Vorbis_Enc_INCLUDE_DIR vorbis/vorbisenc.h
+ HINTS
+ ${PC_Vorbis_Enc_INCLUDEDIR}
+ ${PC_Vorbis_Enc_INCLUDE_DIRS}
+ ${Vorbis_ROOT})
+
+find_path(Vorbis_File_INCLUDE_DIR vorbis/vorbisfile.h
+ HINTS
+ ${PC_Vorbis_File_INCLUDEDIR}
+ ${PC_Vorbis_File_INCLUDE_DIRS}
+ ${Vorbis_ROOT})
+
+find_library(Vorbis_Vorbis_LIBRARY
+ NAMES
+ vorbis
+ vorbis_static
+ libvorbis
+ libvorbis_static
+ HINTS
+ ${PC_Vorbis_Vorbis_LIBDIR}
+ ${PC_Vorbis_Vorbis_LIBRARY_DIRS}
+ ${Vorbis_ROOT})
+
+find_library(Vorbis_Enc_LIBRARY
+ NAMES
+ vorbisenc
+ vorbisenc_static
+ libvorbisenc
+ libvorbisenc_static
+ HINTS
+ ${PC_Vorbis_Enc_LIBDIR}
+ ${PC_Vorbis_Enc_LIBRARY_DIRS}
+ ${Vorbis_ROOT})
+
+find_library(Vorbis_File_LIBRARY
+ NAMES
+ vorbisfile
+ vorbisfile_static
+ libvorbisfile
+ libvorbisfile_static
+ HINTS
+ ${PC_Vorbis_File_LIBDIR}
+ ${PC_Vorbis_File_LIBRARY_DIRS}
+ ${Vorbis_ROOT})
+
+include(FindPackageHandleStandardArgs)
+
+if(Vorbis_Vorbis_LIBRARY AND Vorbis_Vorbis_INCLUDE_DIR AND Ogg_FOUND)
+ set(Vorbis_Vorbis_FOUND TRUE)
+endif()
+
+if(Vorbis_Enc_LIBRARY AND Vorbis_Enc_INCLUDE_DIR AND Vorbis_Vorbis_FOUND)
+ set(Vorbis_Enc_FOUND TRUE)
+endif()
+
+if(Vorbis_Vorbis_FOUND AND Vorbis_File_LIBRARY AND Vorbis_File_INCLUDE_DIR)
+ set(Vorbis_File_FOUND TRUE)
+endif()
+
+find_package_handle_standard_args(Vorbis
+ REQUIRED_VARS
+ Vorbis_Vorbis_LIBRARY
+ Vorbis_Vorbis_INCLUDE_DIR
+ Ogg_FOUND
+ HANDLE_COMPONENTS
+ VERSION_VAR Vorbis_VERSION)
+
+
+if(Vorbis_Vorbis_FOUND)
+ set(Vorbis_Vorbis_INCLUDE_DIRS ${Vorbis_Vorbis_INCLUDE_DIR} ${Ogg_INCLUDE_DIRS})
+ set(Vorbis_Vorbis_LIBRARIES ${Vorbis_Vorbis_LIBRARY} ${Ogg_LIBRARIES})
+ if(NOT TARGET Vorbis::vorbis)
+ add_library(Vorbis::vorbis UNKNOWN IMPORTED)
+ set_target_properties(Vorbis::vorbis PROPERTIES
+ INTERFACE_INCLUDE_DIRECTORIES "${Vorbis_Vorbis_INCLUDE_DIR}"
+ IMPORTED_LOCATION "${Vorbis_Vorbis_LIBRARY}"
+ INTERFACE_LINK_LIBRARIES Ogg::ogg
+ )
+ endif()
+
+ if(Vorbis_Enc_FOUND)
+ set(Vorbis_Enc_INCLUDE_DIRS ${Vorbis_Enc_INCLUDE_DIR} ${Ogg_INCLUDE_DIRS})
+ set(Vorbis_Enc_LIBRARIES ${Vorbis_Enc_LIBRARY} ${Vorbis_Vorbis_LIBRARIES})
+ if(NOT TARGET Vorbis::vorbisenc)
+ add_library(Vorbis::vorbisenc UNKNOWN IMPORTED)
+ set_target_properties(Vorbis::vorbisenc PROPERTIES
+ INTERFACE_INCLUDE_DIRECTORIES "${Vorbis_Enc_INCLUDE_DIR}"
+ IMPORTED_LOCATION "${Vorbis_Enc_LIBRARY}"
+ INTERFACE_LINK_LIBRARIES Vorbis::vorbis
+ )
+ endif()
+ endif()
+
+ if(Vorbis_File_FOUND)
+ set(Vorbis_File_INCLUDE_DIRS ${Vorbis_File_INCLUDE_DIR} ${Ogg_INCLUDE_DIRS})
+ set(Vorbis_File_LIBRARIES ${Vorbis_File_LIBRARY} ${Vorbis_Vorbis_LIBRARIES})
+ if(NOT TARGET Vorbis::vorbisfile)
+ add_library(Vorbis::vorbisfile UNKNOWN IMPORTED)
+ set_target_properties(Vorbis::vorbisfile PROPERTIES
+ INTERFACE_INCLUDE_DIRECTORIES "${Vorbis_File_INCLUDE_DIR}"
+ IMPORTED_LOCATION "${Vorbis_File_LIBRARY}"
+ INTERFACE_LINK_LIBRARIES Vorbis::vorbis
+ )
+ endif()
+ endif()
+
+endif()
+
+mark_as_advanced(Vorbis_Vorbis_INCLUDE_DIR Vorbis_Vorbis_LIBRARY)
+mark_as_advanced(Vorbis_Enc_INCLUDE_DIR Vorbis_Enc_LIBRARY)
+mark_as_advanced(Vorbis_File_INCLUDE_DIR Vorbis_File_LIBRARY)
diff --git a/lib/libsamplerate/libsamplerate-0.2.2/cmake/SampleRateConfig.cmake.in b/lib/libsamplerate/libsamplerate-0.2.2/cmake/SampleRateConfig.cmake.in
new file mode 100755
index 00000000..318b0e9d
--- /dev/null
+++ b/lib/libsamplerate/libsamplerate-0.2.2/cmake/SampleRateConfig.cmake.in
@@ -0,0 +1 @@
+include(${CMAKE_CURRENT_LIST_DIR}/SampleRateTargets.cmake)