* show full compiler version in About dialog

git-svn-id: trunk@4166 -
This commit is contained in:
Tomas Hajny 2006-07-13 23:08:05 +00:00
parent 419ab6aeac
commit 76ac54b78f
2 changed files with 29 additions and 8 deletions

View File

@ -32,6 +32,7 @@ procedure SetPrimaryFile(const fn:string);
function LinkAfter : boolean;
{$ifdef USE_EXTERNAL_COMPILER}
function version_string : string;
function full_version_string : string;
{$endif USE_EXTERNAL_COMPILER}
@ -227,12 +228,32 @@ end;
function version_string : string;
begin
if not ExecuteRedir(ExternalCompilerExe,'-iV','','ppc___.out','ppc___.err') then
version_string:=version.version_string;
Assign(CompilerOut,'ppc___.out');
Reset(CompilerOut);
Readln(CompilerOut,s);
Close(CompilerOut);
version_string:=s;
version_string:=version.version_string
else
begin
Assign(CompilerOut,'ppc___.out');
Reset(CompilerOut);
Readln(CompilerOut,s);
Close(CompilerOut);
version_string:=s;
end;
end;
function full_version_string : string;
begin
if not ExecuteRedir(ExternalCompilerExe,'-iW','','ppc___.out','ppc___.err') then
full_version_string:=version.full_version_string
else
begin
Assign(CompilerOut,'ppc___.out');
Reset(CompilerOut);
Readln(CompilerOut,s);
Close(CompilerOut);
if Pos ('-iW', S) <> 0 then
(* Unknown option - full version not supported! *)
S := Version_String;
full_version_string:=s;
end;
end;
{$endif USE_EXTERNAL_COMPILER}

View File

@ -4094,7 +4094,7 @@ begin
Insert(New(PStaticText, Init(R2, ^C'With Graphic Support')));
R2.Move(0,1);
{$endif USE_GRAPH_SWITCH}
Insert(New(PStaticText, Init(R2, FormatStrStr2(^C'(%s %s)',label_about_compilerversion,Version_String))));
Insert(New(PStaticText, Init(R2, FormatStrStr2(^C'(%s %s)',label_about_compilerversion,Full_Version_String))));
{$ifndef NODEBUG}
if pos('Fake',GDBVersion)=0 then
begin
@ -4105,7 +4105,7 @@ begin
else
{$endif NODEBUG}
R2.Move(0,2);
Insert(New(PStaticText, Init(R2, ^C'Copyright (C) 1998-2005 by')));
Insert(New(PStaticText, Init(R2, ^C'Copyright (C) 1998-2006 by')));
R2.Move(0,2);
Insert(New(PStaticText, Init(R2, ^C'Brczi G bor')));
R2.Move(0,1);