X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=lily%2Flily-version.cc;h=5d31b3934271f522bd3da30866b855ee65917b64;hb=99433c54bea756a38ed6b2a70bc8c90cd0d37902;hp=389178bbc3bf14a2d78ed971701da28c86ac137e;hpb=01ddcb81463d7a68530971100469d3e2baf8c94b;p=lilypond.git diff --git a/lily/lily-version.cc b/lily/lily-version.cc index 389178bbc3..5d31b39342 100644 --- a/lily/lily-version.cc +++ b/lily/lily-version.cc @@ -1,16 +1,36 @@ +/* + lily-version.cc -- implement version strings + + source file of the GNU LilyPond music typesetter + + (c) 1999--2004 Jan Nieuwenhuizen +*/ + +#include "config.h" #include "version.hh" -#include +#include "lily-version.hh" -static char *s = "LilyPond " MAJOR_VERSION "." MINOR_VERSION "." PATCH_LEVEL MY_PATCH_LEVEL " #%d"; +String +version_string () +{ + String str = MAJOR_VERSION "." MINOR_VERSION "." PATCH_LEVEL; + String mpl ("." MY_PATCH_LEVEL); + if (mpl != ".") + str += mpl; + return str; +} -static const int build= -#include ".build" -; +String +gnu_lilypond_string () +{ + String str = "GNU LilyPond"; + return str; +} -char const * -lily_version_sz() +String +gnu_lilypond_version_string () { - static char v[1024]; - sprintf(v, s, build); - return v; + String str = gnu_lilypond_string () + " " + version_string (); + return str; } +