diff options
| author | Niels Ole Salscheider <niels_ole@salscheider-online.de> | 2018-06-23 17:20:47 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-06-23 17:20:47 +0200 |
| commit | ed6b199dff15ddb4c6bd72d1565501e9f1a2bf87 (patch) | |
| tree | 7bbb53c40ecf53fe9464b53b7966dd7726eeac5e /cmake/modules/FindTheora.cmake | |
| parent | ea83c77a5a4524cc9778336b10eff60979582980 (diff) | |
| parent | 31f0a42073b68823e85835ec3e25114d79705a04 (diff) | |
| download | qxmpp-ed6b199dff15ddb4c6bd72d1565501e9f1a2bf87.tar.gz | |
Merge pull request #131 from olesalscheider/cmake
Add CMake build system, drop Qt4 support
Diffstat (limited to 'cmake/modules/FindTheora.cmake')
| -rw-r--r-- | cmake/modules/FindTheora.cmake | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/cmake/modules/FindTheora.cmake b/cmake/modules/FindTheora.cmake new file mode 100644 index 00000000..24462794 --- /dev/null +++ b/cmake/modules/FindTheora.cmake @@ -0,0 +1,33 @@ +# Try to find Theora +# Once done this will define +# Theora_FOUND - System has Theora +# Theora_INCLUDE_DIRS - The Theora include directories +# Theora_LIBRARIES - The libraries needed to use Theora + +find_package(PkgConfig) +pkg_check_modules(PC_Theora QUIET libtheora) + +find_path(Theora_INCLUDE_DIR theora/theora.h + HINTS ${PC_Theora_INCLUDEDIR} ${PC_Theora_INCLUDE_DIRS} +) + +find_library(Theora_LIBRARY NAMES theora + HINTS ${PC_Theora_LIBDIR} ${PC_Theora_LIBRARY_DIRS} +) + +find_library(Theora_enc_LIBRARY NAMES theoraenc + HINTS ${PC_Theora_LIBDIR} ${PC_Theora_LIBRARY_DIRS} +) + +find_library(Theora_dec_LIBRARY NAMES theoradec + HINTS ${PC_Theora_LIBDIR} ${PC_Theora_LIBRARY_DIRS} +) + +include(FindPackageHandleStandardArgs) +find_package_handle_standard_args(Theora DEFAULT_MSG Theora_LIBRARY Theora_enc_LIBRARY Theora_dec_LIBRARY Theora_INCLUDE_DIR) + +mark_as_advanced(Theora_INCLUDE_DIR Theora_LIBRARY Theora_enc_LIBRARY Theora_dec_LIBRARY) + +set(Theora_LIBRARIES ${Theora_LIBRARY} ${Theora_enc_LIBRARY} ${Theora_dec_LIBRARY}) +set(Theora_INCLUDE_DIRS ${Theora_INCLUDE_DIR}) + |
