Commit d07f085d authored by Ingo Klöcker's avatar Ingo Klöcker
Browse files

Append a compact release service version to Kleopatra's version number

This ensures that we have different version numbers for different
releases without switching completely to the release service version.
This fixes problems with building flatpaks because appstream-compose
errors out if there are multiple <release> tags with the same version
attribute in the AppStream data (org.kde.kleopatra.appdata.xml).

This approach was suggested by Albert Astals Cid with reference to
khelpcenter from where I borrowed some of the code.
parent 858b7771
set(kleopatra_version 3.1.16)
# The following is for Windows. Keep in line with kleopatra_version.
set(kleopatra_fileversion 3,1,16,0)
cmake_minimum_required(VERSION 3.16 FATAL_ERROR)
project(kleopatra VERSION ${kleopatra_version})
# The RELEASE_SERVICE_VERSION is used by Gpg4win to add the Gpg4win version
if (NOT RELEASE_SERVICE_VERSION)
set (RELEASE_SERVICE_VERSION "21.07.40")
endif()
set(RELEASE_SERVICE_VERSION_MAJOR "21")
set(RELEASE_SERVICE_VERSION_MINOR "07")
set(RELEASE_SERVICE_VERSION_PATCH "40")
set(RELEASE_SERVICE_VERSION "${RELEASE_SERVICE_VERSION_MAJOR}.${RELEASE_SERVICE_VERSION_MINOR}.${RELEASE_SERVICE_VERSION_PATCH}")
set(KDE_APPLICATIONS_COMPACT_VERSION "${RELEASE_SERVICE_VERSION_MAJOR}${RELEASE_SERVICE_VERSION_MINOR}${RELEASE_SERVICE_VERSION_PATCH}")
set(KLEOPATRA_VERSION_MAJOR "3")
set(KLEOPATRA_VERSION_MINOR "1")
set(KLEOPATRA_VERSION_PATCH "16")
set(kleopatra_version "${KLEOPATRA_VERSION_MAJOR}.${KLEOPATRA_VERSION_MINOR}.${KLEOPATRA_VERSION_PATCH}.${KDE_APPLICATIONS_COMPACT_VERSION}")
# The following is for Windows. Keep in line with kleopatra_version.
set(kleopatra_fileversion "${KLEOPATRA_VERSION_MAJOR},${KLEOPATRA_VERSION_MINOR},${KLEOPATRA_VERSION_PATCH},0")
project(kleopatra VERSION ${kleopatra_version})
option(DISABLE_KWATCHGNUPG "Don't build the kwatchgnupg tool [default=OFF]" OFF)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment