Reported by rcurtin on 2 Aug 43865191 17:46 UTC
On Mon, Nov 11, 2013 at 12:31:10PM +0100, Giampaolo Bellini wrote:
> Dear all
> I'm using latest mlpack on linux for neighbor search
> I wonder if there is a way to retrieve the library version in order to
> show it in the about box of my application...
> thanks a lot
There are two things we should do here.
There's a bit more, though; a subversion post-commit hook will need to be added to update the definition of the version string, so that it will look something like 'r15886' instead of just 'trunk' if trunk is being used.
Commented by rcurtin on 4 Jun 43995151 03:04 UTC
--version option and C++ function mlpack::util::GetVersion() added in r16090. A post-commit hook is not the right way to update that, though; a better idea is to use CMake+svn at build time to see if the source directory is a repository, and if so, update what GetVersion() returns.
Commented by rcurtin on 15 Jan 44010475 23:04 UTC
Fixed as of r16105. Maybe we should use svnversion instead of svn info though.
Since we switched from svn to git (github) the GetVersion() function doesn't work anymore.
The following files are used to get the version that need to be updated:
For now, Ryan implemented a temporary workaround to fix the problem in 61a1064 which creates the version string 1.x.x.
Fixed in 15c5546.