summaryrefslogtreecommitdiff
path: root/src/PlatformUtils.cc
diff options
context:
space:
mode:
authorDon Bright <hugh.m.bright@gmail.com>2013-09-12 05:17:17 (GMT)
committerDon Bright <hugh.m.bright@gmail.com>2013-09-12 05:17:17 (GMT)
commit6af6c311a12a0211545e29666c92f1806ca0c7e8 (patch)
tree5af3769a2bbd2cdc44508152cc1d2c72b2331e77 /src/PlatformUtils.cc
parentb53dde04e2a13c066cfa0c552fe5bd0cdd1b8dbd (diff)
cmdline throwntogether, integrate w chrysn tests, update resize tests
Diffstat (limited to 'src/PlatformUtils.cc')
-rw-r--r--src/PlatformUtils.cc43
1 files changed, 43 insertions, 0 deletions
diff --git a/src/PlatformUtils.cc b/src/PlatformUtils.cc
index 5dd007d..ccc2bc0 100644
--- a/src/PlatformUtils.cc
+++ b/src/PlatformUtils.cc
@@ -38,3 +38,46 @@ std::string PlatformUtils::libraryPath()
}
return boosty::stringy( path );
}
+
+#include "version_check.h"
+#define STRINGIFY(x) #x
+#define TOSTRING(x) STRINGIFY(x)
+std::string PlatformUtils::info()
+{
+ std::stringstream s;
+
+#if defined(__GNUG__) && !defined(__clang__)
+ std::string compiler_info( "GCC " + std::string(TOSTRING(__VERSION__)) );
+#elif defined(_MSC_VER)
+ std::string compiler_info( "MSVC " + std::string(TOSTRING(_MSC_FULL_VER)) );
+#elif defined(__clang__)
+ std::string compiler_info( "Clang " + std::string(TOSTRING(__clang_version__)) );
+#else
+ std::string compiler_info( "unknown compiler" );
+#endif
+
+#if defined( __MINGW64__ )
+ std::string mingwstatus("MingW64");
+#elif defined( __MINGW32__ )
+ std::string mingwstatus("MingW32");
+#else
+ std::string mingwstatus("No");
+#endif
+
+#ifndef OPENCSG_VERSION_STRING
+#define OPENCSG_VERSION_STRING "unknown, <1.3.2"
+#endif
+
+ s << "OpenSCAD Version: " << TOSTRING(OPENSCAD_VERSION)
+ << "\nCompiler: " << compiler_info
+ << "\nCompile date: " << __DATE__
+ << "\nBoost version: " << BOOST_LIB_VERSION
+ << "\nEigen version: " << EIGEN_WORLD_VERSION << "." << EIGEN_MAJOR_VERSION << "." << EIGEN_MINOR_VERSION
+ << "\nCGAL version: " << TOSTRING(CGAL_VERSION)
+ << "\nOpenCSG version: " << OPENCSG_VERSION_STRING
+ << "\nQt version: " << qVersion()
+ << "\nMingW build: " << mingwstatus;
+
+ return s.str();
+}
+
contact: Jan Huwald // Impressum