fpc/compiler/version.pas
2000-07-13 11:32:24 +00:00

106 lines
2.3 KiB
ObjectPascal

{
$Id$
Copyright (C) 1998-2000 by Florian Klaempfl
Version/target constants
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
****************************************************************************
}
unit version;
interface
const
{ word version for ppu file }
wordversion = (1 shl 14)+0;
{ version string }
version_nr = '1';
release_nr = '00';
patch_nr = '0';
{$ifdef newcg}
minorpatch = ' NCG';
{$else newcg}
{$ifdef newoptimizations}
minorpatch = ' OPT';
{$else}
minorpatch = '';
{$endif}
{$endif newcg}
{ date string }
{$ifdef FPC}
date_string = {$I %DATE%};
{$else}
date_string = 'N/A';
{$endif}
{ target cpu string }
{$ifdef i386}
target_cpu_string = 'i386';
{$endif}
{$ifdef m68k}
target_cpu_string = 'm68k';
{$endif}
{$ifdef alpha}
target_cpu_string = 'alpha';
{$endif}
{$ifdef powerpc}
target_cpu_string = 'powerpc';
{$endif}
{ source cpu string }
{$ifdef cpu86}
source_cpu_string = 'i386';
{$endif}
{$ifdef cpu68}
source_cpu_string = 'm68k';
{$endif}
function version_string:string;
function full_version_string:string;
implementation
function version_string:string;
begin
if patch_nr='0' then
version_string := version_nr+'.'+release_nr
else
version_string := version_nr+'.'+release_nr+'.'+patch_nr;
end;
function full_version_string:string;
begin
if patch_nr='0' then
full_version_string := version_nr+'.'+release_nr+minorpatch
else
full_version_string := version_nr+'.'+release_nr+'.'+patch_nr+minorpatch;
end;
begin
end.
{
$Log$
Revision 1.2 2000-07-13 11:32:54 michael
+ removed logs
}