CYCLUS
Loading...
Searching...
No Matches
version.cc
Go to the documentation of this file.
1#include <sstream>
2#include <cstring>
3
4#include "platform.h"
5#include "version.h"
6
7#if CYCLUS_HAS_COIN
8#include "CbcConfig.h"
9#include "ClpConfig.h"
10// required for coin-cbc v < 2.5
11#ifndef CBC_VERSION
12#define CBC_VERSION CBCVERSION
13#endif
14#else
15#define CBC_VERSION "-1"
16#define CLP_VERSION "-1"
17#endif
18
19#include "boost/version.hpp"
20#include "hdf5.h"
21#include "libxml/xmlversion.h"
22#include "libxml++config.h"
23#include "sqlite3.h"
24
25
26#define INNER(x) #x
27#define SVER(x,y,z) INNER(x.y.z)
28
29namespace cyclus {
30namespace version {
31
32static char h5version[15];
33
34const char* describe() {
35 return "1.6";
36}
37
41
42const char* boost() {
43 return BOOST_LIB_VERSION;
44}
45
46const char* sqlite3() {
47 return SQLITE_VERSION;
48}
49
50const char* hdf5() {
51 if (std::string("") == h5version) {
52 std::stringstream ss;
53 ss << H5_VERS_MAJOR << ".";
54 ss << H5_VERS_MINOR << ".";
55 ss << H5_VERS_RELEASE << "-";
57 memset(h5version, 0, 15);
58 memcpy(h5version, ss.str().c_str(), ss.str().size());
59 }
60 return h5version;
61}
62
63const char* xml2() {
65}
66
67const char* xmlpp() {
68 #ifdef LIBXMLXX_MAJOR_VERSION
71 #else
72 return "<2.37";
73 #endif
74}
75
76const char* coincbc() {
77 return CBC_VERSION;
78}
79
80const char* coinclp() {
81 return CLP_VERSION;
82}
83
84} // namespace version
85} // namespace cyclus
const char * core()
Definition version.cc:38
const char * sqlite3()
Definition version.cc:46
const char * hdf5()
Definition version.cc:50
const char * xmlpp()
Definition version.cc:67
static char h5version[15]
Definition version.cc:32
const char * coinclp()
Definition version.cc:80
const char * xml2()
Definition version.cc:63
const char * describe()
Definition version.cc:34
const char * boost()
Definition version.cc:42
const char * coincbc()
Definition version.cc:76
taken directly from OsiSolverInterface.cpp on 2/17/14 from https://projects.coin-or....
Definition agent.cc:14
T OptionalQuery(InfileTree *tree, std::string query, T default_val)
a query method for optional parameters
#define SVER(x, y, z)
Definition version.cc:27
#define CBC_VERSION
Definition version.cc:12
#define CYCLUS_VERSION_MAJOR
Definition version.h:4
#define CYCLUS_VERSION_MICRO
Definition version.h:6
#define CYCLUS_VERSION_MINOR
Definition version.h:5