Made the python __version__ field come from the DLIB_VERSION macro set by

CMake.
This commit is contained in:
Davis King 2016-02-03 08:32:59 -05:00
parent fcf80e1dd0
commit 6b064d3584
1 changed files with 4 additions and 1 deletions

View File

@ -29,7 +29,10 @@ BOOST_PYTHON_MODULE(dlib)
// since it is full of huge amounts of template clutter.
boost::python::docstring_options options(true,true,false);
boost::python::scope().attr("__version__") = "18.18";
#define DLIB_QUOTE_STRING(x) DLIB_QUOTE_STRING2(x)
#define DLIB_QUOTE_STRING2(x) #x
boost::python::scope().attr("__version__") = DLIB_QUOTE_STRING(DLIB_VERSION);
bind_matrix();
bind_vector();