summaryrefslogtreecommitdiff
path: root/include/version.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'include/version.cpp')
-rw-r--r--include/version.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/include/version.cpp b/include/version.cpp
index 02fef8975..164fdb525 100644
--- a/include/version.cpp
+++ b/include/version.cpp
@@ -105,8 +105,9 @@ static bool write_build_h(const std::string &buildh, const std::string &git_vers
return false;
}
- fd << "/* This file is automatically generated by version.cpp - do not edit it! */" << std::endl;
- fd << build << std::endl;
+ fd << "/* This file is automatically generated by version.cpp - do not edit it! */" << std::endl
+ << "#pragma once" << std::endl
+ << build << std::endl;
if (!git_version.empty())
fd << "#define VERSION_GIT \"" << git_version << "\"" << std::endl;
fd.close();
@@ -144,6 +145,7 @@ static bool write_version_h(const std::string &versionh, const std::map<std::str
if (!fd.is_open())
return false;
+ fd << "#pragma once" << std::endl;
for (std::map<std::string, std::string>::const_iterator it = versions.begin(); it != versions.end(); ++it)
{
fd << "#define " << it->first << " " << it->second << std::endl;