IDE: fixed IDE restart when project is set to cross compile, issue #36142

git-svn-id: trunk@62022 -
This commit is contained in:
mattias 2019-10-10 12:32:20 +00:00
parent cd76eb1ef2
commit 9c7ef38222

View File

@ -2895,6 +2895,8 @@ begin
end;
function TBuildManager.BuildTargetIDEIsDefault: boolean;
// check if current BuildLazarus creates the normal lazarus exe
// aka not some cross compile
var
NewTargetOS: String;
NewTargetCPU: String;
@ -2908,8 +2910,8 @@ begin
//debugln(['TBuildManager.BuildTargetIDEIsDefault NewTargetOS=',NewTargetOS,' Default=',GetDefaultTargetOS,' NewTargetCPU=',NewTargetCPU,' default=',GetDefaultTargetCPU,' ws=',LCLPlatformDisplayNames[NewLCLWidgetSet],' default=',LCLPlatformDisplayNames[GetDefaultLCLWidgetType]]);
Result:=((NewTargetOS='') or (NewTargetOS=GetCompiledTargetOS))
and ((NewTargetCPU='') or (NewTargetCPU=GetCompiledTargetCPU))
and (NewLCLWidgetSet<>lpNoGUI)
and (GetCompilerFilename=EnvironmentOptions.GetParsedCompilerFilename);
and (NewLCLWidgetSet<>lpNoGUI);
// Note: no need to check if CompilerFilename is the default
end;
end.