aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArne Morten Kvarving <spiff@kodi.tv>2018-10-17 14:58:49 +0200
committerArne Morten Kvarving <arne.morten.kvarving@sintef.no>2018-10-17 18:52:40 +0200
commitda5b59e0d4793412618abf001e506031b9cda19d (patch)
tree44835d8df7b18688ff71f7a525bdba350ab7d1d7
parent6c5725e3a26bccebdc431d92db3c20f3ef393006 (diff)
added: copyright years to version.txt
-rw-r--r--CMakeLists.txt1
-rw-r--r--cmake/scripts/common/Macros.cmake1
-rw-r--r--version.txt1
-rw-r--r--xbmc/AppParamParser.cpp4
-rw-r--r--xbmc/CompileInfo.cpp.in5
-rw-r--r--xbmc/CompileInfo.h1
6 files changed, 12 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 911560e4e8..d297716029 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -226,6 +226,7 @@ add_custom_command(OUTPUT ${CORE_BUILD_DIR}/xbmc/CompileInfo.cpp
-DCMAKE_BINARY_DIR=${CMAKE_BINARY_DIR}
-DARCH_DEFINES="${ARCH_DEFINES}"
-DAPP_SCMID=${APP_SCMID}
+ -DAPP_COPYRIGHT_YEARS=${APP_COPYRIGHT_YEARS}
-Dprefix=${CMAKE_BINARY_DIR}/${CORE_BUILD_DIR}
-P ${CMAKE_SOURCE_DIR}/cmake/scripts/common/GenerateVersionedFiles.cmake
DEPENDS ${CMAKE_SOURCE_DIR}/version.txt
diff --git a/cmake/scripts/common/Macros.cmake b/cmake/scripts/common/Macros.cmake
index 0d89dd3257..89a20e5759 100644
--- a/cmake/scripts/common/Macros.cmake
+++ b/cmake/scripts/common/Macros.cmake
@@ -721,6 +721,7 @@ macro(core_find_versions)
APP_NAME
APP_PACKAGE
COMPANY_NAME
+ COPYRIGHT_YEARS
JSONRPC_VERSION
PACKAGE_DESCRIPTION
PACKAGE_IDENTITY
diff --git a/version.txt b/version.txt
index c27a42c834..dff2507c93 100644
--- a/version.txt
+++ b/version.txt
@@ -1,5 +1,6 @@
APP_NAME Kodi
COMPANY_NAME XBMC Foundation
+COPYRIGHT_YEARS 2005-2018
WEBSITE http://kodi.tv
VERSION_MAJOR 18
VERSION_MINOR 0
diff --git a/xbmc/AppParamParser.cpp b/xbmc/AppParamParser.cpp
index 20f3c819b8..63920101d0 100644
--- a/xbmc/AppParamParser.cpp
+++ b/xbmc/AppParamParser.cpp
@@ -7,6 +7,7 @@
*/
#include "AppParamParser.h"
+#include "CompileInfo.h"
#include "FileItem.h"
#include "settings/AdvancedSettings.h"
#include "utils/log.h"
@@ -40,7 +41,8 @@ void CAppParamParser::Parse(const char* const* argv, int nArgs)
void CAppParamParser::DisplayVersion()
{
printf("%s Media Center %s\n", CSysInfo::GetVersion().c_str(), CSysInfo::GetAppName().c_str());
- printf("Copyright (C) 2005-2013 Team %s - http://kodi.tv\n", CSysInfo::GetAppName().c_str());
+ printf("Copyright (C) %s Team %s - http://kodi.tv\n",
+ CCompileInfo::GetCopyrightYears(), CSysInfo::GetAppName().c_str());
exit(0);
}
diff --git a/xbmc/CompileInfo.cpp.in b/xbmc/CompileInfo.cpp.in
index e0e15a90e4..eef78ba052 100644
--- a/xbmc/CompileInfo.cpp.in
+++ b/xbmc/CompileInfo.cpp.in
@@ -54,3 +54,8 @@ const char* CCompileInfo::GetSCMID()
{
return "@APP_SCMID@";
}
+
+const char* CCompileInfo::GetCopyrightYears()
+{
+ return "@APP_COPYRIGHT_YEARS@";
+}
diff --git a/xbmc/CompileInfo.h b/xbmc/CompileInfo.h
index 4104141563..855711e5f7 100644
--- a/xbmc/CompileInfo.h
+++ b/xbmc/CompileInfo.h
@@ -18,4 +18,5 @@ public:
static const char* GetAppName();
static const char *GetSuffix(); // Git "Tag", e.g. alpha1
static const char* GetSCMID(); // Git Revision
+ static const char* GetCopyrightYears();
};