fix(cmake): Strip final newline from bundled localisations

Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
This commit is contained in:
Claudio Cambra 2025-05-29 11:47:18 +08:00 committed by Matthieu Gallien
parent a2b12cff72
commit bc102fc06b

View File

@ -28,4 +28,7 @@ foreach(TS_FILE ${TS_FILES})
string(REPLACE "_" "-" LANG_CODE ${LANG_CODE}) # en-GB
set(LOCALIZATIONS_LIST "${LOCALIZATIONS_LIST} <string>${LANG_CODE}</string>\n")
endforeach()
if(LOCALIZATIONS_LIST)
string(STRIP "${LOCALIZATIONS_LIST}" LOCALIZATIONS_LIST)
endif()
set(MACOSX_BUNDLE_LOCALIZATIONS "${LOCALIZATIONS_LIST}" CACHE INTERNAL "Generated list of localizations for macOS bundle" FORCE)