diff options
Diffstat (limited to 'project/cmake/modules/FindBluray.cmake')
| -rw-r--r-- | project/cmake/modules/FindBluray.cmake | 39 |
1 files changed, 20 insertions, 19 deletions
diff --git a/project/cmake/modules/FindBluray.cmake b/project/cmake/modules/FindBluray.cmake index 2b0a449..b8422ed 100644 --- a/project/cmake/modules/FindBluray.cmake +++ b/project/cmake/modules/FindBluray.cmake | |||
| @@ -15,26 +15,27 @@ | |||
| 15 | # Bluray::Bluray - The libblueray library | 15 | # Bluray::Bluray - The libblueray library |
| 16 | 16 | ||
| 17 | if(PKG_CONFIG_FOUND) | 17 | if(PKG_CONFIG_FOUND) |
| 18 | pkg_check_modules(BLURAY libbluray>=0.7.0) | 18 | pkg_check_modules(PC_BLURAY libbluray>=0.7.0 QUIET) |
| 19 | set(BLURAY_VERSION ${PC_BLURAY_VERSION}) | 19 | endif() |
| 20 | |||
| 21 | find_path(BLURAY_INCLUDE_DIR libbluray/bluray.h | ||
| 22 | PATHS ${PC_BLURAY_INCLUDEDIR}) | ||
| 23 | |||
| 24 | set(BLURAY_VERSION ${PC_BLURAY_VERSION}) | ||
| 25 | |||
| 26 | include(FindPackageHandleStandardArgs) | ||
| 27 | if(NOT WIN32) | ||
| 28 | find_library(BLURAY_LIBRARY NAMES bluray | ||
| 29 | PATHS ${PC_BLURAY_LIBDIR}) | ||
| 30 | |||
| 31 | find_package_handle_standard_args(Bluray | ||
| 32 | REQUIRED_VARS BLURAY_LIBRARY BLURAY_INCLUDE_DIR | ||
| 33 | VERSION_VAR BLURAY_VERSION) | ||
| 20 | else() | 34 | else() |
| 21 | find_path(BLURAY_INCLUDE_DIR libbluray/bluray.h | 35 | # Dynamically loaded DLL |
| 22 | PATHS ${PC_BLURAY_INCLUDEDIR}) | 36 | find_package_handle_standard_args(Bluray |
| 23 | 37 | REQUIRED_VARS BLURAY_INCLUDE_DIR | |
| 24 | include(FindPackageHandleStandardArgs) | 38 | VERSION_VAR BLURAY_VERSION) |
| 25 | if(NOT WIN32) | ||
| 26 | find_library(BLURAY_LIBRARY NAMES bluray | ||
| 27 | PATHS ${PC_BLURAY_LIBDIR}) | ||
| 28 | |||
| 29 | find_package_handle_standard_args(BLURAY | ||
| 30 | REQUIRED_VARS BLURAY_LIBRARY BLURAY_INCLUDE_DIR | ||
| 31 | VERSION_VAR BLURAY_VERSION) | ||
| 32 | else() | ||
| 33 | # Dynamically loaded DLL | ||
| 34 | find_package_handle_standard_args(BLURAY | ||
| 35 | REQUIRED_VARS BLURAY_INCLUDE_DIR | ||
| 36 | VERSION_VAR BLURAY_VERSION) | ||
| 37 | endif() | ||
| 38 | endif() | 39 | endif() |
| 39 | 40 | ||
| 40 | if(BLURAY_FOUND) | 41 | if(BLURAY_FOUND) |
