Skip VERSION/SOVERSION/DEBUG_POSTFIX on the header-only INTERFACE target (#4830)

* Skip VERSION/SOVERSION/DEBUG_POSTFIX on the header-only INTERFACE target

* Lint check fixed
This commit is contained in:
Soumik15630m
2026-06-28 21:08:06 +05:30
committed by GitHub
parent d24fef27d1
commit 81516a20d9
+7 -5
View File
@@ -256,11 +256,13 @@ function (setup_target target kind)
target_compile_definitions(${target} ${kind} FMT_UNICODE=0)
endif ()
set_target_properties(
${target}
PROPERTIES VERSION ${FMT_VERSION}
SOVERSION ${CPACK_PACKAGE_VERSION_MAJOR}
DEBUG_POSTFIX "${FMT_DEBUG_POSTFIX}")
if (NOT "${kind}" STREQUAL "INTERFACE")
set_target_properties(
${target}
PROPERTIES VERSION ${FMT_VERSION}
SOVERSION ${CPACK_PACKAGE_VERSION_MAJOR}
DEBUG_POSTFIX "${FMT_DEBUG_POSTFIX}")
endif ()
endfunction ()
set(FMT_HEADERS)