Skip to content

Commit

Permalink
Prefer OBS::libobs in find_package
Browse files Browse the repository at this point in the history
Closes #214
  • Loading branch information
nowrep committed Jul 17, 2024
1 parent eb4b07b commit 8e43192
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,16 @@ endif()
set(CMAKE_C_STANDARD 11)

if (BUILD_PLUGIN)
if (NOT TARGET OBS::libobs)
find_package(libobs QUIET)
endif()
if (NOT TARGET libobs)
find_package(LibObs QUIET)
endif()
if (TARGET libobs)
set(PLUGIN_LIBS libobs)
elseif(TARGET OBS::libobs)
if (TARGET OBS::libobs)
set(PLUGIN_LIBS OBS::libobs)
elseif (TARGET libobs)
set(PLUGIN_LIBS libobs)
else()
pkg_check_modules(LIBOBS libobs IMPORTED_TARGET REQUIRED)
set(PLUGIN_LIBS PkgConfig::LIBOBS)
Expand Down

0 comments on commit 8e43192

Please sign in to comment.