summaryrefslogtreecommitdiffstats
path: root/libversion/fullversion.cpp
diff options
context:
space:
mode:
authorDimitri van Heesch <doxygen@gmail.com>2020-05-15 09:28:16 (GMT)
committerDimitri van Heesch <doxygen@gmail.com>2020-05-15 09:34:17 (GMT)
commit10787eed95266bb1a13c892fe4cf5a695dac1559 (patch)
tree3267c7bc4580d4de7ec5797b5658038ad53e3941 /libversion/fullversion.cpp
parent12843822b09f0aa3f426387986354d9e1303e41e (diff)
downloadDoxygen-10787eed95266bb1a13c892fe4cf5a695dac1559.zip
Doxygen-10787eed95266bb1a13c892fe4cf5a695dac1559.tar.gz
Doxygen-10787eed95266bb1a13c892fe4cf5a695dac1559.tar.bz2
Refactoring
- Makes doxycfg library more self contained - renames _doxygen library to doxymain - Modernizes Debug implementation - Moves Doxygen::runningTime into Debug - Moves full version string to libversion - Removed mentioning of file version in messages (when FILE_VERSION_FILTER is used) - Move substitute functions into QCString
Diffstat (limited to 'libversion/fullversion.cpp')
-rw-r--r--libversion/fullversion.cpp22
1 files changed, 22 insertions, 0 deletions
diff --git a/libversion/fullversion.cpp b/libversion/fullversion.cpp
new file mode 100644
index 0000000..dfc2b0d
--- /dev/null
+++ b/libversion/fullversion.cpp
@@ -0,0 +1,22 @@
+#include <string.h>
+#include <version.h>
+
+const char *getFullVersion(void)
+{
+#define BUF_SIZE 100
+ static char fullVersionString[BUF_SIZE];
+ static bool init = false;
+ if (!init)
+ {
+ strlcpy(fullVersionString,getDoxygenVersion(),BUF_SIZE);
+ if (strlen(getGitVersion())>0)
+ {
+ strlcat(fullVersionString," (",BUF_SIZE);
+ strlcat(fullVersionString,getGitVersion(),BUF_SIZE);
+ strlcat(fullVersionString,")",BUF_SIZE);
+ }
+ fullVersionString[BUF_SIZE-1]='\0';
+ init = true;
+ }
+ return fullVersionString;
+}