diff options
author | Chris Young <chris@unsatisfactorysoftware.co.uk> | 2008-11-15 23:54:09 +0000 |
---|---|---|
committer | Chris Young <chris@unsatisfactorysoftware.co.uk> | 2008-11-15 23:54:09 +0000 |
commit | 52eb07dc5bca882473c5f14db299578ff144a1e4 (patch) | |
tree | 831f96a645e6eac0abc306c74f070ac6454e9467 /amiga/version.rexx | |
parent | d6874d05b1800f3f68cf109fb7818b68b59c213c (diff) | |
download | netsurf-52eb07dc5bca882473c5f14db299578ff144a1e4.tar.gz netsurf-52eb07dc5bca882473c5f14db299578ff144a1e4.tar.bz2 |
Sparse "About" requester - version number, compile date and URL only.
svn path=/trunk/netsurf/; revision=5697
Diffstat (limited to 'amiga/version.rexx')
-rw-r--r-- | amiga/version.rexx | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/amiga/version.rexx b/amiga/version.rexx index b649d7b53..58ccb982a 100644 --- a/amiga/version.rexx +++ b/amiga/version.rexx @@ -16,7 +16,7 @@ * along with this program. If not, see <http://www.gnu.org/licenses/>. */ -/* This file generates an AmigaOS compliant version string in version.h */ +/* This file generates an AmigaOS compliant version string in version.c */ address command 'svn info >t:ns_svn' @@ -38,8 +38,15 @@ if open('tmp','desktop/version.c','R') then do end majorver = compress(word(var,5),";") -date = translate(date('E'),'.','/') - -say '/* This file was automatically generated from version.rexx */' -say 'static __attribute__((used)) char verstag[] = "\0$VER: NetSurf' majorver || '.' || svnrev '(' || date || ')\0";' +/* ARexx only returns two digits for year, but AmigaOS version string dates are + * supposed to have four digits for the year, so the below specifies the prefix + * (century-1 really). This will need to be increased in 2100 and every hundred + * years thereafter, if this script is still in use :-) */ +century = 20 +date = translate(left(date('E'),6) || century || right(date('E'),2),'.','/') + +say '/* This file was automatically generated by version.rexx */' +say 'static const __attribute__((used)) char *verstag = "\0$VER: NetSurf' majorver || '.' || svnrev '(' || date || ')\0";' +say 'const char * const versvn = "SVN' svnrev || '";' +say 'const char * const verdate = "' || date || '";' |