IDE: fixed overriding build target OS/CPU/LCL, bug #10915

git-svn-id: trunk@14337 -
This commit is contained in:
mattias 2008-03-01 11:28:43 +00:00
parent 13b1c51267
commit 65a770df87
7 changed files with 12 additions and 12 deletions

View File

@ -240,6 +240,7 @@ var
Info: PWGLControlInfo;
begin
Info:=GetWGLControlInfo(Handle);
// don't use wglSwapLayerBuffers or wglSwapBuffers!
SwapBuffers(Info^.DC);
end;

View File

@ -25,10 +25,10 @@
</RunParams>
<RequiredPackages Count="2">
<Item1>
<PackageName Value="LCL"/>
<PackageName Value="LazOpenGLContext"/>
</Item1>
<Item2>
<PackageName Value="LazOpenGLContext"/>
<PackageName Value="LCL"/>
</Item2>
</RequiredPackages>
<Units Count="2">
@ -46,8 +46,12 @@
</ProjectOptions>
<CompilerOptions>
<Version Value="5"/>
<SearchPaths>
<LCLWidgetType Value="win32"/>
</SearchPaths>
<CodeGeneration>
<Generate Value="Faster"/>
<TargetOS Value="win32"/>
</CodeGeneration>
<Other>
<CompilerPath Value="$(CompPath)"/>

View File

@ -1207,8 +1207,7 @@ begin
// ' New=',NewTargetCPU,'-',NewTargetOS,'-',NewLCLWidgetType,' FPC=',dbgs(FPCTargetChanged),' LCL=',dbgs(LCLTargetChanged));
if LCLTargetChanged then
CodeToolBoss.GlobalValues.Variables[ExternalMacroStart+'LCLWidgetType']:=
NewLCLWidgetType;
CodeToolBoss.SetGlobalValue(ExternalMacroStart+'LCLWidgetType',NewLCLWidgetType);
if FPCTargetChanged then
RescanCompilerDefines(true);

View File

@ -6255,6 +6255,7 @@ begin
UpdateCaption;
EnvironmentOptions.LastSavedProjectFile:=Project1.ProjectInfoFile;
EnvironmentOptions.Save(false);
MainBuildBoss.SetBuildTarget('','','');
MainBuildBoss.RescanCompilerDefines(true);
// load required packages

View File

@ -4500,13 +4500,7 @@ var
Changed: Boolean;
begin
Changed:=false;
if CodeToolBoss.SetGlobalValue(ExternalMacroStart+'LCLWidgetType',
Owner.CompilerOptions.GetEffectiveLCLWidgetType)
then begin
//DebugLn('TProjectDefineTemplates.UpdateGlobalValues '
//,' LCLWidgetType="',CodeToolBoss.GlobalValues.Variables[ExternalMacroStart+'LCLWidgetType'],'" Effective="',Owner.CompilerOptions.GetEffectiveLCLWidgetType,'" Options="',Owner.CompilerOptions.LCLWidgetType,'"');
Changed:=true;
end;
// the LCLWidgetType, TargetCPU and TargetOS is set by the TBuildManager
if Owner.IsVirtual then
NewProjectDir:=VirtualDirectory
else

View File

@ -2573,7 +2573,7 @@ begin
CompilerParams:=APackage.CompilerOptions.MakeOptionsString(Globals,
APackage.CompilerOptions.DefaultMakeOptionsFlags)
+' '+CreateRelativePath(SrcFilename,APackage.Directory);
//DebugLn(['TLazPackageGraph.CompilePackage SrcFilename="',SrcFilename,'" CompilerFilename="',CompilerFilename,'" CompilerParams="',CompilerParams,'"']);
DebugLn(['TLazPackageGraph.CompilePackage SrcFilename="',SrcFilename,'" CompilerFilename="',CompilerFilename,'" CompilerParams="',CompilerParams,'" TargetCPU=',Globals.TargetCPU,' TargetOS=',Globals.TargetOS]);
// check if compilation is needed and if a clean build is needed
Result:=CheckIfPackageNeedsCompilation(APackage,

View File

@ -3726,6 +3726,7 @@ begin
Result:=CheckPackageGraphForCompilation(nil,FirstAutoInstallDependency,
EnvironmentOptions.LazarusDirectory);
if Result<>mrOk then exit;
DebugLn(['TPkgManager.DoCompileAutoInstallPackages LCLUnitPath=',PackageGraph.LCLPackage.CompilerOptions.GetUnitPath(true)]);
// save all open files
if not (pcfDoNotSaveEditorFiles in Flags) then begin