Skip to content

fix unrelocatable cmake config #3

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 24, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,13 @@ if(HUNTER_ENABLED)
find_package(libogg CONFIG REQUIRED)
set(OGG_LIBRARY libogg::ogg)
get_target_property(OGG_INCLUDE_DIR libogg::ogg INTERFACE_INCLUDE_DIRECTORIES)
set(OGG_INCLUDE_DIR $<BUILD_INTERFACE:${OGG_INCLUDE_DIR}>)

hunter_add_package(Opus)
find_package(Opus CONFIG REQUIRED)
set(OPUS_LIBRARY Opus::opus)
get_target_property(OPUS_INCLUDE_DIR Opus::opus INTERFACE_INCLUDE_DIRECTORIES)
set(OPUS_INCLUDE_DIR ${OPUS_INCLUDE_DIR} ${OPUS_INCLUDE_DIR}/opus)
set(OPUS_INCLUDE_DIR $<BUILD_INTERFACE:${OPUS_INCLUDE_DIR}> $<BUILD_INTERFACE:${OPUS_INCLUDE_DIR}/opus> $<INSTALL_INTERFACE:include/opus>)
else()
find_path(OGG_INCLUDE_DIR ogg/ogg.h)
find_library(OGG_LIBRARY ogg)
Expand Down