summaryrefslogtreecommitdiff
path: root/src/util
diff options
context:
space:
mode:
authorMorgan Deters <mdeters@gmail.com>2011-10-21 04:25:19 +0000
committerMorgan Deters <mdeters@gmail.com>2011-10-21 04:25:19 +0000
commitda1f0e9e8479741487a59ad68198262c3730081e (patch)
tree2f764fcd4574ddefd62ad0da44b1bec64df685dd /src/util
parent19b3adf57987584096ca59dc9852fb9573ee1715 (diff)
add gcc version information to Configuration, and warn when building with v4.5.1 which has a buggy optimizer (resolves bug #266)
Diffstat (limited to 'src/util')
-rw-r--r--src/util/configuration.cpp15
-rw-r--r--src/util/configuration.h2
-rw-r--r--src/util/configuration_private.h3
3 files changed, 19 insertions, 1 deletions
diff --git a/src/util/configuration.cpp b/src/util/configuration.cpp
index 7225b8108..3164b75a5 100644
--- a/src/util/configuration.cpp
+++ b/src/util/configuration.cpp
@@ -186,4 +186,19 @@ string Configuration::getSubversionId() {
return ss.str();
}
+string Configuration::getCompiler() {
+ stringstream ss;
+#ifdef __GNUC__
+ ss << "GCC";
+#else /* __GNUC__ */
+ ss << "unknown compiler";
+#endif /* __GNUC__ */
+#ifdef __VERSION__
+ ss << " version " << __VERSION__;
+#else /* __VERSION__ */
+ ss << ", unknown version";
+#endif /* __VERSION__ */
+ return ss.str();
+}
+
}/* CVC4 namespace */
diff --git a/src/util/configuration.h b/src/util/configuration.h
index b4caf842c..c3040f3fb 100644
--- a/src/util/configuration.h
+++ b/src/util/configuration.h
@@ -99,6 +99,8 @@ public:
static bool hasSubversionModifications();
static std::string getSubversionId();
+ static std::string getCompiler();
+
};/* class Configuration */
}/* CVC4 namespace */
diff --git a/src/util/configuration_private.h b/src/util/configuration_private.h
index 13347d970..abff15b3b 100644
--- a/src/util/configuration_private.h
+++ b/src/util/configuration_private.h
@@ -114,7 +114,8 @@ This is CVC4 version " CVC4_RELEASE_STRING ) + \
( ::CVC4::Configuration::isSubversionBuild() \
? ( ::std::string(" [") + ::CVC4::Configuration::getSubversionId() + "]" ) \
: ::std::string("") \
- ) + "\n\n\
+ ) + "\n\
+compiled with " + ::CVC4::Configuration::getCompiler() + "\n\n\
Copyright (C) 2009, 2010, 2011\n\
The ACSys Group\n\
Courant Institute of Mathematical Sciences\n\
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback