xca/lib/version.cpp
Christian Hohnstädt 8c04bc2b27 Rename PACKAGE_VERSION to XCA_VERSION
For an official release XCA_VERSION == PACKAGE_VERSION.
For any additional commit, XCA_VERSION's path-level is increased.

PACKAGE_VERSION cannot be modified after initially set.
Change any occurance of PACKAGE_VERSION by XCA_VERSION
2021-04-26 10:10:23 +02:00

31 lines
562 B
C++

/* vi: set sw=4 ts=4:
*
* Copyright (C) 2018 Christian Hohnstaedt.
*
* All rights reserved.
* Compiles much faster than MW_help.cpp
* and needs to get recompiled every time
*/
#ifndef QMAKE
#include "local.h"
#endif
#ifndef NO_COMMITHASH
#include "commithash.h"
#else
#define COMMITHASH ""
#endif
#define VERSION XCA_VERSION
const char *version_str(bool html)
{
if (!COMMITHASH[0])
return html ? "<b>" VERSION "</b>" : VERSION;
return html ?
"<b>" VERSION "-dev</b><br/>commit: <b>" COMMITHASH "</b>" :
VERSION "-dev\ncommit: " COMMITHASH;
}