diff options
author | Erik Kundiman <erik@megapahit.org> | 2024-05-28 17:55:02 +0800 |
---|---|---|
committer | Erik Kundiman <erik@megapahit.org> | 2024-05-28 17:55:02 +0800 |
commit | 641a0f760f3a44983c527e1a5ce5ecc82b028e80 (patch) | |
tree | 4589b8e3c306fb7e2d475c1ffc014e73e81f78fd /indra/cmake | |
parent | 5c651c1f90be1059fe059dba7bab5c69d211206e (diff) |
BSDs use system OpenJPEG, Linuxes link statically
Cause 2.5.2 on MacPorts and FBSD ports are safe, while 2.5.0 on
Debian/Ubuntu would cause a crash that we stick to LL's 2.5.0.
Diffstat (limited to 'indra/cmake')
-rw-r--r-- | indra/cmake/OpenJPEG.cmake | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/indra/cmake/OpenJPEG.cmake b/indra/cmake/OpenJPEG.cmake index 87c59ad5ae..6de03113ed 100644 --- a/indra/cmake/OpenJPEG.cmake +++ b/indra/cmake/OpenJPEG.cmake @@ -4,17 +4,17 @@ include(Prebuilt) include_guard() add_library( ll::openjpeg INTERFACE IMPORTED ) -if (NOT (USE_AUTOBUILD_3P OR USE_CONAN)) +if (NOT USESYSTEMLIBS) +use_system_binary(openjpeg) +use_prebuilt_binary(openjpeg) +elseif (NOT LINUX) include(FindPkgConfig) pkg_check_modules(Openjpeg REQUIRED libopenjp2) target_include_directories(ll::openjpeg SYSTEM INTERFACE ${Openjpeg_INCLUDE_DIRS}) target_link_directories(ll::openjpeg INTERFACE ${Openjpeg_LIBRARY_DIRS}) target_link_libraries(ll::openjpeg INTERFACE ${Openjpeg_LIBRARIES}) return () -endif () - -use_system_binary(openjpeg) -use_prebuilt_binary(openjpeg) +endif (NOT USESYSTEMLIBS) target_link_libraries(ll::openjpeg INTERFACE openjp2 ) target_include_directories( ll::openjpeg SYSTEM INTERFACE ${LIBS_PREBUILT_DIR}/include) |