build: Fix various issues with linking, clang and unity builds

This commit is contained in:
WerWolv
2024-01-29 22:57:39 +01:00
parent 2e74a78f46
commit 76e304c34e
22 changed files with 18 additions and 41 deletions

View File

@@ -5,7 +5,6 @@ include(ImHexPlugin)
macro(addOptionalLibrary package library)
find_package(${package})
if (${package}_FOUND)
set_property(TARGET ${package}::${library} PROPERTY POSITION_INDEPENDENT_CODE ON)
string(TOUPPER ${package} PACKAGE)
set(LIBRARIES ${LIBRARIES} ${package}::${library})
message(STATUS "Enabling decompression support using ${package} (${${package}_VERSION})")