[Mono-devel-list] [PATCH] Added Mono.Runtime.GetVersion()

Ben Maurer bmaurer at ximian.com
Sat Jun 4 13:30:48 EDT 2005

On Sat, 2005-06-04 at 17:58 +0200, Kornél Pál wrote:
> > From: Ben Maurer
> > (the reason here is that I need to be able to make a svn snapshot and
> > easily change it so that there is a revision number based version at the
> > end. However, I can't know if the "real version" is 1.1.7 or
> > Also, this totally restricts the version format to having 4 parts).
> I think having some restrictions on the format of version number is required
> if we want to use the version numbers for any purpose.
> The version of course can be parsed from a string at runtime it has little
> performance loss as long as the version number is in a form that can be used
> in the constructor of System.Version.

I don't care about the performance of this method at all.

> > Btw, if we do this at all, lets also work on killing the horrible
> > version bump procedure we have today. Right now, you need to bump the
> > number of mcs, ilasm, etc.
> For a managed application usually only the version of ther runtime is
> inportant. It can be assumed that a specific version of the runtime comes
> with a specific version of class library as the class library strongly
> depends on the runtime.
> Other utilities like mcs and ilasm are executed as external processes by a
> managed application so their version can be checked using --version and it
> is not required to have the same version number as the runtime.

Right, I am saying: if you want to solve problems related to how we
handle version, lets fix the broken things we have all at once :-). The
AssemblyInfo.cs files for mcs, etc are not generated.

> >From: Rafael Teixeira
> >The configure.ac part doesn't work, as AC_INIT says that $VERSION
> >isn't a literal
> This worked for me but it think using VERSION as a string in icall.c instead
> of four integers would look better.
> I attached a modified patch what do you think of this one?

Your patch will break if there are more than four version parts (which
might happen inside the build system because we munge the version

-- Ben

More information about the Mono-devel-list mailing list