diff --git a/utils/fppkg/fpmkunitsrc.inc b/utils/fppkg/fpmkunitsrc.inc index 8cb15befac..9132125692 100644 --- a/utils/fppkg/fpmkunitsrc.inc +++ b/utils/fppkg/fpmkunitsrc.inc @@ -1,7 +1,7 @@ {$ifdef Delphi} -const fpmkunitsrc : array[0..547] of string[240]=( +const fpmkunitsrc : array[0..548] of string[240]=( {$else Delphi} -const fpmkunitsrc : array[0..547,1..240] of char=( +const fpmkunitsrc : array[0..548,1..240] of char=( {$endif Delphi} '{'#010+ ' This file is part of the Free Pascal Makefile Package'#010+ @@ -721,75 +721,77 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' FRemove: String;'#010+ ' FTarget: String;'#010+ ' FUnixPaths: Boo','lean;'#010+ + ' FNoFPCCfg: Boolean;'#010+ ' FSourceExt : String;'#010+ ' function GetLocalUnitDir: String;'#010+ ' function GetGlobalUnitDir: String;'#010+ ' function GetBaseInstallDir: String;'#010+ ' function GetBinInstallDir: String;'#010+ - ' function GetCompiler: String;'#010+ - ' function GetDoc','InstallDir: String;'#010+ + ' function GetCompiler: Str','ing;'#010+ + ' function GetDocInstallDir: String;'#010+ ' function GetExamplesInstallDir: String;'#010+ ' function GetUnitInstallDir: String;'#010+ ' procedure SetLocalUnitDir(const AValue: String);'#010+ ' procedure SetGlobalUnitDir(const AValue: String);'#010+ - ' procedure SetBaseInstallD','ir(const AValue: String);'#010+ + ' p','rocedure SetBaseInstallDir(const AValue: String);'#010+ ' procedure SetCPU(const AValue: TCPU);'#010+ ' procedure SetOS(const AValue: TOS);'#010+ ' procedure SetPrefix(const AValue: String);'#010+ ' procedure SetTarget(const AValue: String);'#010+ ' Protected'#010+ - ' procedure RecalcTarget',';'#010+ + ' ',' procedure RecalcTarget;'#010+ ' Public'#010+ ' Constructor Create;'#010+ ' Procedure InitDefaults;'#010+ ' Procedure Assign(ASource : TPersistent);override;'#010+ ' procedure CompilerDefaults; virtual;'#010+ ' Procedure LocalInit(Const AFileName : String);'#010+ - ' Procedure LoadFromFile(Cons','t AFileName : String);'#010+ + ' Pro','cedure LoadFromFile(Const AFileName : String);'#010+ ' Procedure SaveToFile(Const AFileName : String);'#010+ ' procedure SaveToStream(S : TStream);virtual;'#010+ ' procedure LoadFromStream(S : TStream);virtual;'#010+ ' // Compile Information'#010+ - ' Property Target : String Read FTar','get Write SetTarget;'#010+ + ' Property T','arget : String Read FTarget Write SetTarget;'#010+ ' Property OS : TOS Read FOS Write SetOS;'#010+ ' Property CPU : TCPU Read FCPU Write SetCPU;'#010+ ' Property Mode : TCompilerMode Read FMode Write FMode;'#010+ - ' Property UnixPaths : Boolean Read FUnixPaths Write FUnixPaths;'#010+ - ' ',' Property Options : String Read FOptions Write FOptions; // De'+ - 'fault compiler options.'#010+ + ' Property UnixPaths : Boolean Read FUnixPa','ths Write FUnixPaths;'#010+ + ' Property Options : String Read FOptions Write FOptions; // Defa'+ + 'ult compiler options.'#010+ ' Property SourceExt : String Read FSourceExt Write FSourceExt;'#010+ + ' Property NoFPCCfg : Boolean Read FNoFPCCfg Write FNoFPCC','fg;'#010+ ' // paths etc.'#010+ - ' Property LocalUnitDir : String Read GetLocalUnitDir Write SetL','oc'+ - 'alUnitDir;'#010+ + ' Property LocalUnitDir : String Read GetLocalUnitDir Write SetLocal'+ + 'UnitDir;'#010+ ' Property GlobalUnitDir : String Read GetGlobalUnitDir Write SetGlo'+ 'balUnitDir;'#010+ - ' Property Prefix : String Read FPrefix Write SetPrefix;'#010+ + ' Property Prefix : String Read FPrefix Write SetPrefix',';'#010+ ' Property BaseInstallDir : String Read GetBaseInstallDir Write SetB'+ 'aseInstallDir;'#010+ - ' ',' Property UnitInstallDir : String Read GetUnitInstallDir Write FU'+ - 'nitInstallDir;'#010+ - ' Property BinInstallDir : String Read GetBinInstallDir Write FBinIn'+ + ' Property UnitInstallDir : String Read GetUnitInstallDir Write FUni'+ + 'tInstallDir;'#010+ + ' Property BinInstallDir : String Read GetBinInstallDir Write FBinIn', 'stallDir;'#010+ ' Property DocInstallDir : String Read GetDocInstallDir Write FDocIn'+ - 'stallDir',';'#010+ + 'stallDir;'#010+ ' Property ExamplesInstallDir : String Read GetExamplesInstallDir Wr'+ 'ite FExamplesInstallDir;'#010+ - ' // Command tools. If not set, internal commands will be used.'#010+ + ' // Command tools. If not set, internal commands wi','ll be used.'#010+ ' Property Compiler : String Read GetCompiler Write FCompiler; // Co'+ - 'mpiler','. Defaults to fpc'#010+ + 'mpiler. Defaults to fpc'#010+ ' Property Copy : String Read FCopy Write FCopy; // copy'+ ' $(FILES) to $(DEST)'#010+ - ' Property Move : String Read FMove Write FMove; // Move'+ - ' $(FILES) to $(DEST)'#010+ - ' Property Remove : String Read FRemov','e Write FRemove; // De'+ - 'lete $(FILES)'#010+ + ' Property Move : String Read FMove Write',' FMove; // Mo'+ + 've $(FILES) to $(DEST)'#010+ + ' Property Remove : String Read FRemove Write FRemove; // Dele'+ + 'te $(FILES)'#010+ ' Property MkDir : String Read FMkDir write FMkDir; // Make'+ ' $(DIRECTORY)'#010+ - ' Property Archive : String Read FArchive Write FArchive; // zip '+ - '$(ARCHIVE) $(FILESORDIRS)'#010+ + ' Property Archive : Str','ing Read FArchive Write FArchive; // zi'+ + 'p $(ARCHIVE) $(FILESORDIRS)'#010+ ' end;'#010+ #010+ - ' { TBasic','Defaults }'#010+ + ' { TBasicDefaults }'#010+ #010+ ' TBasicDefaults = Class(TCustomDefaults)'#010+ ' end;'#010+ @@ -798,153 +800,152 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ ' TFPCDefaults = Class(TCustomDefaults)'#010+ ' public'#010+ - ' procedure CompilerDefaults; override;'#010+ + ' procedure Compile','rDefaults; override;'#010+ ' end;'#010+ #010+ ' { TBuildEngine }'#010+ #010+ ' TBuildEngine = Class(TComponent)'#010+ - ' pr','ivate'#010+ + ' private'#010+ ' // general variables'#010+ ' FCompiler : String;'#010+ ' FStartDir : String;'#010+ ' FTargetDir : String;'#010+ ' FDefaults : TCustomDefaults;'#010+ - ' FForceCompile : Boolean;'#010+ + ' FForceCompi','le : Boolean;'#010+ ' FListMode : Boolean;'#010+ '{$ifdef HAS_UNIT_ZIPPER}'#010+ ' FZipFile: TZipper;'#010+ - '{','$endif HAS_UNIT_ZIPPER}'#010+ + '{$endif HAS_UNIT_ZIPPER}'#010+ ' // Variables used when compiling a package.'#010+ ' // Only valid during compilation of the package.'#010+ - ' FCurrentOutputDir : String;'#010+ + ' FCurrentOutputDir : Str','ing;'#010+ ' FCurrentPackage: TPackage;'#010+ ' // Events'#010+ ' FOnLog: TLogEvent;'#010+ - ' FAfterArchi','ve: TNotifyEvent;'#010+ + ' FAfterArchive: TNotifyEvent;'#010+ ' FAfterClean: TNotifyEvent;'#010+ ' FAfterCompile: TNotifyEvent;'#010+ ' FAfterInstall: TNotifyEvent;'#010+ ' FAfterManifest: TNotifyEvent;'#010+ - ' FBeforeArchive: TNotifyEvent;'#010+ + ' ',' FBeforeArchive: TNotifyEvent;'#010+ ' FBeforeClean: TNotifyEvent;'#010+ - ' FBeforeCompile: TNoti','fyEvent;'#010+ + ' FBeforeCompile: TNotifyEvent;'#010+ ' FBeforeInstall: TNotifyEvent;'#010+ ' FBeforeManifest: TNotifyEvent;'#010+ ' procedure SetDefaults(const AValue: TCustomDefaults);'#010+ - ' procedure SetTargetDir(const AValue: String);'#010+ + ' procedure Se','tTargetDir(const AValue: String);'#010+ ' Protected'#010+ ' Procedure Error(const Msg : String);'#010+ - ' ',' Procedure Error(const Fmt : String; Args : Array of const);'#010+ + ' Procedure Error(const Fmt : String; Args : Array of const);'#010+ ' // Internal copy/delete/move/archive/mkdir files'#010+ - ' Procedure SysCopyFile(Const Src,Dest : String); virtual;'#010+ + ' Procedure SysCopyFile(Const Src,','Dest : String); virtual;'#010+ ' Procedure SysMoveFile(Const Src,Dest : String); virtual;'#010+ - ' ',' Procedure SysDeleteFile(Const AFileName : String); virtual;'#010+ + ' Procedure SysDeleteFile(Const AFileName : String); virtual;'#010+ ' Procedure SysArchiveFiles(List : TStrings; Const AFileName : Strin'+ 'g); virtual;'#010+ - ' Procedure Log(Level : TVerboseLevel; Const Msg : String);'#010+ - ' Procedure Log(Level : TVerbos','eLevel; Const Fmt : String; Args : '+ - 'Array Of Const);'#010+ + ' Pro','cedure Log(Level : TVerboseLevel; Const Msg : String);'#010+ + ' Procedure Log(Level : TVerboseLevel; Const Fmt : String; Args : Ar'+ + 'ray Of Const);'#010+ ' Procedure EnterDir(ADir : String);'#010+ ' Function GetCompiler : String;'#010+ - ' Procedure InstallPackageFiles(APAckage : TPackage; tt : TTargetTyp'+ - 'e; Const Src,Dest : String); virtual;'#010+ - ' Fu','nction FileNewer(const Src,Dest : String) : Boolean;'#010+ + ' Procedure InstallPacka','geFiles(APAckage : TPackage; tt : TTargetT'+ + 'ype; Const Src,Dest : String); virtual;'#010+ + ' Function FileNewer(const Src,Dest : String) : Boolean;'#010+ ' Function FindFileInPath(Path:TConditionalStrings; AFileName:String'+ - '; var FoundPath:String;ACPU:TCPU;AOS:TOS; Const PathPrefix :String='#039+ + '; var FoundPath:String;ACPU:T','CPU;AOS:TOS; Const PathPrefix :String='#039+ #039'):Boolean;'#010+ #010+ ' //package commands'#010+ - ' Procedure',' ResolveFileNames(APackage : TPackage; ACPU:TCPU;AOS:TO'+ - 'S);'#010+ + ' Procedure ResolveFileNames(APackage : TPackage; ACPU:TCPU;AOS:TOS)'+ + ';'#010+ ' Function GetOutputDir(AName: string; APackage : TPackage; Absolut'+ - 'ePath : Boolean = False) : String;'#010+ + 'ePath : Boolean = False',') : String;'#010+ #010+ ' Public'#010+ ' Constructor Create(AOwner : TComponent); override;'#010+ - ' // Publ','ic Copy/delete/Move/Archive/Mkdir Commands.'#010+ + ' // Public Copy/delete/Move/Archive/Mkdir Commands.'#010+ ' Procedure ExecuteCommand(const Cmd,Args : String; IgnoreError : Bo'+ 'olean = False); virtual;'#010+ - ' Procedure CmdCopyFiles(List : TStrings; Const DestDir : String);'#010+ - ' Procedure CmdCreateDir(const',' DestDir : String);'#010+ + ' Procedure',' CmdCopyFiles(List : TStrings; Const DestDir : String);'+ + #010+ + ' Procedure CmdCreateDir(const DestDir : String);'#010+ ' Procedure CmdMoveFiles(List : TStrings; Const DestDir : String);'#010+ ' Procedure CmdDeleteFiles(List : TStrings);'#010+ - ' Procedure CmdArchiveFiles(List : TStrings; Const ArchiveFile : Str'+ - 'ing);'#010+ - ' Procedure ExecuteCommand','s(Commands : TCommands; At : TCommandAt)'+ - ';'#010+ + ' Procedure Cm','dArchiveFiles(List : TStrings; Const ArchiveFile : S'+ + 'tring);'#010+ + ' Procedure ExecuteCommands(Commands : TCommands; At : TCommandAt);'#010+ ' // Dependency commands'#010+ ' Function DependencyOK(ADependency : TDependency) : Boolean;'#010+ - ' // Target commands'#010+ + ' // Target comm','ands'#010+ ' Function GetTargetDir(APackage : TPackage; ATarget : TTarget; Abs'+ - 'olutePath : B','oolean = False) : String;'#010+ + 'olutePath : Boolean = False) : String;'#010+ ' Function GetCompilerCommand(APackage : TPackage; Target : TTarget'+ ') : String;'#010+ - ' Function TargetOK(ATarget : TTarget) : Boolean;'#010+ + ' Function TargetOK(ATarget : TTarget) : ','Boolean;'#010+ ' Function NeedsCompile(Target : TTarget) : Boolean;'#010+ - ' Procedure Compile(T','arget : TTarget); virtual;'#010+ + ' Procedure Compile(Target : TTarget); virtual;'#010+ ' Procedure MaybeCompile(Target: TTarget);'#010+ ' Procedure CompileDependencies(Target: TTarget);'#010+ ' // Package commands'#010+ - ' Function GetPackageDir(APackage : TPackage; AbsolutePath : Boolea'+ - 'n = False) : String;'#010, + ' ',' Function GetPackageDir(APackage : TPackage; AbsolutePath : Bool'+ + 'ean = False) : String;'#010+ ' Function GetUnitsOutputDir(APackage : TPackage; AbsolutePath : Bo'+ 'olean = False) : String;'#010+ - ' Function GetBinOutputDir(APackage : TPackage; AbsolutePath : Bool'+ - 'ean = False) : String;'#010+ - ' Function PackageOK(APackage : TPackage) : Boole','an; virtual;'#010+ + ' Function GetBinOutputDir(APackage : TPackage; Absolu','tePath : Bo'+ + 'olean = False) : String;'#010+ + ' Function PackageOK(APackage : TPackage) : Boolean; virtual;'#010+ ' Procedure DoBeforeCompile(APackage : TPackage);virtual;'#010+ ' Procedure DoAfterCompile(APackage : TPackage);virtual;'#010+ - ' Procedure DoBeforeInstall(APackage : TPackage);virtual;'#010+ - ' Procedure DoAfterInstall(APackage : TPackage',');virtual;'#010+ + ' Procedure DoBefo','reInstall(APackage : TPackage);virtual;'#010+ + ' Procedure DoAfterInstall(APackage : TPackage);virtual;'#010+ ' Procedure DoBeforeArchive(APackage : TPackage);virtual;'#010+ ' Procedure DoAfterArchive(APackage : TPackage);virtual;'#010+ - ' Procedure DoBeforeClean(APackage : TPackage);virtual;'#010+ - ' Procedure DoAfterClean(APackage : TPackage);virt','ual;'#010+ + ' Procedure DoBefore','Clean(APackage : TPackage);virtual;'#010+ + ' Procedure DoAfterClean(APackage : TPackage);virtual;'#010+ ' Function NeedsCompile(APackage : TPackage) : Boolean; virtual;'#010+ ' Procedure Compile(APackage : TPackage);'#010+ - ' Procedure Install(APackage : TPackage);'#010+ + ' Procedure Install(APackage : TPa','ckage);'#010+ ' Procedure Archive(APackage : TPackage);'#010+ - ' Procedure Clean(APackage : TPack','age);'#010+ + ' Procedure Clean(APackage : TPackage);'#010+ ' Procedure CompileDependencies(APackage : TPackage);'#010+ ' Procedure GetManifest(APackage : TPackage; Manifest : TStrings);'#010+ - ' procedure CheckExternalPackage(Const APackageName : String);'#010+ - ' procedure CreateOutputDir(APackage: TPac','kage);'#010+ + ' procedure CheckEx','ternalPackage(Const APackageName : String);'#010+ + ' procedure CreateOutputDir(APackage: TPackage);'#010+ ' // Packages commands'#010+ ' Procedure Compile(Packages : TPackages);'#010+ ' Procedure Install(Packages : TPackages);'#010+ - ' Procedure Archive(Packages : TPackages);'#010+ + ' Procedure Archive(Packages',' : TPackages);'#010+ ' Procedure Clean(Packages : TPackages);'#010+ - ' Procedure GetManifest(Pack','ages : TPackages; Manifest : TStrings)'+ - ';'#010+ + ' Procedure GetManifest(Packages : TPackages; Manifest : TStrings);'#010+ ' Property ListMode : Boolean Read FListMode Write FListMode;'#010+ - ' Property ForceCompile : Boolean Read FForceCompile Write FForceCom'+ - 'pile;'#010+ - ' Property Defaults : TCustomDefaults Read FDefaults Write',' SetDefa'+ - 'ults;'#010+ + ' Property ForceCompile : Boolean Read FForceC','ompile Write FForceC'+ + 'ompile;'#010+ + ' Property Defaults : TCustomDefaults Read FDefaults Write SetDefaul'+ + 'ts;'#010+ ' Property TargetDir : String Read FTargetDir Write SetTargetDir;'#010+ ' // Events'#010+ - ' Property BeforeCompile : TNotifyEvent Read FBeforeCompile Write FB'+ - 'eforeCompile;'#010+ - ' Property AfterCompile : TNotifyEvent Read FAfterCompile ','Write FA'+ - 'fterCompile;'#010+ + ' Property BeforeCompile : TNotifyEvent Read FBeforeCo','mpile Write '+ + 'FBeforeCompile;'#010+ + ' Property AfterCompile : TNotifyEvent Read FAfterCompile Write FAft'+ + 'erCompile;'#010+ ' Property BeforeInstall : TNotifyEvent Read FBeforeInstall Write FB'+ 'eforeInstall;'#010+ - ' Property AfterInstall : TNotifyEvent Read FAfterInstall Write FAft'+ - 'erInstall;'#010+ - ' Property BeforeClean : TNotifyEvent Read FBeforeCl','ean Write FBef'+ - 'oreClean;'#010+ + ' Property AfterInstall : TNotifyEvent Read F','AfterInstall Write FA'+ + 'fterInstall;'#010+ + ' Property BeforeClean : TNotifyEvent Read FBeforeClean Write FBefor'+ + 'eClean;'#010+ ' Property AfterClean : TNotifyEvent Read FAfterClean Write FAfterCl'+ 'ean;'#010+ - ' Property BeforeArchive : TNotifyEvent Read FBeforeArchive Write FB'+ - 'eforeArchive;'#010+ - ' Property AfterArchive : TNotifyEvent Read FAfterArchi','ve Write FA'+ - 'fterArchive;'#010+ + ' Property BeforeArchive : TNotifyEvent Read FBefor','eArchive Write '+ + 'FBeforeArchive;'#010+ + ' Property AfterArchive : TNotifyEvent Read FAfterArchive Write FAft'+ + 'erArchive;'#010+ ' Property BeforeManifest : TNotifyEvent Read FBeforeManifest Write '+ 'FBeforeManifest;'#010+ - ' Property AfterManifest : TNotifyEvent Read FAfterManifest Write FA'+ - 'fterManifest;'#010+ - ' Property OnLog : TLogEvent Read FOnLog Wr','ite FOnlog;'#010+ + ' Property AfterManifest : TNotifyEvent',' Read FAfterManifest Write '+ + 'FAfterManifest;'#010+ + ' Property OnLog : TLogEvent Read FOnLog Write FOnlog;'#010+ ' end;'#010+ #010+ ' { TCustomInstaller }'#010+ @@ -952,104 +953,104 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' TCustomInstaller = Class(TComponent)'#010+ ' private'#010+ ' FBuildEngine: TBuildEngine;'#010+ - ' FDefaultPackage: TPackage;'#010+ + ' FDefaultPackage: TPacka','ge;'#010+ ' FDefaults: TCustomDefaults;'#010+ ' FPackages: TPackages;'#010+ ' FRunMode: TRunMode;'#010+ - ' ',' FListMode : Boolean;'#010+ + ' FListMode : Boolean;'#010+ ' FLogLevels : TVerboseLevels;'#010+ ' function GetBaseInstallDir: string;'#010+ - ' Function GetPackageString(Index : Integer) : String;'#010+ + ' Function GetPackageString(Index : Integer) : String;',#010+ ' Procedure SetPackageString(Index : Integer; const AValue : String)'+ ';'#010+ - ' function Ge','tConditionalStrings(AIndex : Integer): TConditionalSt'+ - 'rings;'#010+ + ' function GetConditionalStrings(AIndex : Integer): TConditionalStri'+ + 'ngs;'#010+ ' function GetOSes: TOSes;'#010+ ' function GetTargets: TTargets;'#010+ - ' function GetSources: TSources;'#010+ + ' function GetSources: TSo','urces;'#010+ ' procedure SetBaseInstallDir(const AValue: string);'#010+ - ' procedure SetDefaultPa','ckage(const AValue: TPackage);'#010+ + ' procedure SetDefaultPackage(const AValue: TPackage);'#010+ ' procedure SetDefaults(const AValue: TCustomDefaults);'#010+ - ' procedure SetConditionalStrings(AIndex : Integer; const AValue: TC'+ - 'onditionalStrings);'#010+ + ' procedure SetConditionalStrings(AIndex : Integer; const AVa','lue: '+ + 'TConditionalStrings);'#010+ ' procedure SeTOSes(const AValue: TOSes);'#010+ ' Protected'#010+ - ' P','rocedure Log(Level : TVerboseLevel; Const Msg : String);'#010+ + ' Procedure Log(Level : TVerboseLevel; Const Msg : String);'#010+ ' Procedure CreatePackages; virtual;'#010+ ' Procedure CheckPackages; virtual;'#010+ - ' Procedure CreateBuildEngine; virtual;'#010+ + ' Procedure Crea','teBuildEngine; virtual;'#010+ ' Procedure CheckDefaultPackage;'#010+ - ' Procedure Error(const Msg',' : String);'#010+ + ' Procedure Error(const Msg : String);'#010+ ' Procedure Error(const Fmt : String; Args : Array of const);'#010+ ' Procedure AnalyzeOptions;'#010+ - ' Procedure Usage(const FMT : String; Args : Array of const);'#010+ + ' Procedure Usage(const FMT : String; Args :',' Array of const);'#010+ ' Procedure Compile(Force : Boolean); virtual;'#010+ - ' Procedure Clean; ','virtual;'#010+ + ' Procedure Clean; virtual;'#010+ ' Procedure Install; virtual;'#010+ ' Procedure Archive; virtual;'#010+ ' Procedure Manifest; virtual;'#010+ - ' Property BuildEngine : TBuildEngine Read FBuildEngine;'#010+ + ' Property BuildEngine : TBuildEngine Read F','BuildEngine;'#010+ ' Public'#010+ ' Constructor Create(AOwner : TComponent); virtual; abstract;'#010+ - ' ',' Destructor destroy; override;'#010+ + ' Destructor destroy; override;'#010+ ' Function StartPackage(Const AName : String) : TPackage;'#010+ ' Procedure EndPackage;'#010+ ' Function Run : Boolean;'#010+ - ' Function AddTarget(const AName : String) : TTarget;'#010+ - ' Procedure AddDependency(const ANam','e : String);'#010+ + ' Fu','nction AddTarget(const AName : String) : TTarget;'#010+ + ' Procedure AddDependency(const AName : String);'#010+ ' //files in package'#010+ ' Property DefaultPackage : TPackage read FDefaultPackage write SetD'+ 'efaultPackage;'#010+ - ' Property Packages : TPackages Read FPackages;'#010+ - ' Property Dependencies : TConditionalStrings Index 0 Read GetCondi', - 'tionalStrings Write SetConditionalStrings;'#010+ - ' Property InstallFiles : TConditionalStrings Index 1 Read GetCondit'+ + ' Property Packages : TPackag','es Read FPackages;'#010+ + ' Property Dependencies : TConditionalStrings Index 0 Read GetCondit'+ 'ionalStrings Write SetConditionalStrings;'#010+ + ' Property InstallFiles : TConditionalStrings Index 1 Read GetCondit'+ + 'ionalStrings Write SetConditionalString','s;'#010+ ' Property CleanFiles : TConditionalStrings Index 2 Read GetConditio'+ - 'nalStrings Writ','e SetConditionalStrings;'#010+ + 'nalStrings Write SetConditionalStrings;'#010+ ' Property ArchiveFiles : TConditionalStrings Index 3 Read GetCondit'+ 'ionalStrings Write SetConditionalStrings;'#010+ - ' Property Defaults : TCustomDefaults Read FDefaults Write SetDefaul'+ - 'ts;'#010+ - ' Property RunMode : TRunMo','de Read FRunMode;'#010+ + ' Property De','faults : TCustomDefaults Read FDefaults Write SetDefa'+ + 'ults;'#010+ + ' Property RunMode : TRunMode Read FRunMode;'#010+ ' Property ListMode : Boolean Read FListMode;'#010+ ' Property BaseInstallDir : String Read GetBaseInstallDir Write SetB'+ 'aseInstallDir;'#010+ - ' // Default Package redirects.'#010+ + ' ',' // Default Package redirects.'#010+ ' Property Targets : TTargets Read GetTargets;'#010+ - ' Pr','operty Sources : TSources Read GetSources;'#010+ + ' Property Sources : TSources Read GetSources;'#010+ ' Property OS: TOSes Read GetOSes Write SetOSes;'#010+ - ' Property Author : String Index 0 Read GetPackageString Write SetPa'+ - 'ckageString;'#010+ - ' Property Directory : String Index 1 Read GetPackageString W','rite '+ - 'SetPackageString;'#010+ + ' Property Author : String Index 0 Read GetPackageString',' Write Set'+ + 'PackageString;'#010+ + ' Property Directory : String Index 1 Read GetPackageString Write Se'+ + 'tPackageString;'#010+ ' Property License : String Index 2 Read GetPackageString Write SetP'+ 'ackageString;'#010+ - ' Property Options : String Index 3 Read GetPackageString Write SetP'+ - 'ackageString;'#010+ - ' Property ExternalURL : String Index 4 Read Ge','tPackageString Writ'+ - 'e SetPackageString;'#010+ + ' Property Options : String Index 3 Read Ge','tPackageString Write Se'+ + 'tPackageString;'#010+ + ' Property ExternalURL : String Index 4 Read GetPackageString Write '+ + 'SetPackageString;'#010+ ' Property Email : String Index 5 Read GetPackageString Write SetPac'+ 'kageString;'#010+ - ' Property Description: String Index 6 Read GetPackageString Write S'+ - 'etPackageString;'#010+ - ' Property DescriptionFileName',': String Index 7 Read GetPackageStri'+ - 'ng Write SetPackageString;'#010+ + ' Property Description: Strin','g Index 6 Read GetPackageString Write'+ + ' SetPackageString;'#010+ + ' Property DescriptionFileName: String Index 7 Read GetPackageString'+ + ' Write SetPackageString;'#010+ ' Property Version : String Index 8 Read GetPackageString Write SetP'+ 'ackageString;'#010+ - ' Property FileName : String Index 9 Read GetPackageString Write Set'+ - 'PackageString;'#010+ + ' P','roperty FileName : String Index 9 Read GetPackageString Write S'+ + 'etPackageString;'#010+ ' end;'#010+ - #010, + #010+ ' { TFPCInstaller }'#010+ ' TFPCInstaller = class(TCustomInstaller)'#010+ ' public'#010+ ' Constructor Create(AOwner : TComponent); override;'#010+ ' end;'#010+ #010+ - ' { TBasicInstaller }'#010+ + ' { TBasicInstalle','r }'#010+ ' TBasicInstaller = class(TCustomInstaller)'#010+ - ' Constructor Create(AOwner : TCompone','nt); override;'#010+ + ' Constructor Create(AOwner : TComponent); override;'#010+ ' end;'#010+ #010+ ' TReplaceFunction = Function (Const AName,Args : String) : String of '+ @@ -1058,11 +1059,11 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' { TValueItem }'#010+ #010+ ' TValueItem = Class(TObject)'#010+ - ' FValue : String;'#010+ + ' ',' FValue : String;'#010+ ' Constructor Create(AValue : String);'#010+ ' end;'#010+ #010+ - ' { TFunctionItem }'#010, + ' { TFunctionItem }'#010+ #010+ ' TFunctionItem = Class(TObject)'#010+ ' FFunc : TReplaceFunction;'#010+ @@ -1071,248 +1072,250 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ ' { TDictionary }'#010+ #010+ - ' TDictionary = Class(TComponent)'#010+ + ' TDictiona','ry = Class(TComponent)'#010+ ' FList : TStringList;'#010+ ' Public'#010+ - ' Constructor Create(AOwner :',' TComponent); override;'#010+ + ' Constructor Create(AOwner : TComponent); override;'#010+ ' Destructor Destroy;override;'#010+ ' Procedure AddVariable(Const AName,Value : String);'#010+ - ' Procedure AddFunction(Const AName : String; FReplacement : TReplac'+ - 'eFunction);'#010+ - ' Procedure RemoveItem(Const AName : String)',';'#010+ + ' Procedure AddFunction(Const AName : ','String; FReplacement : TRepl'+ + 'aceFunction);'#010+ + ' Procedure RemoveItem(Const AName : String);'#010+ ' Function GetValue(Const AName : String) : String;'#010+ ' Function GetValue(Const AName,Args : String) : String; virtual;'#010+ - ' Function ReplaceStrings(Const ASource : String) : String; virtual;'+ - #010+ + ' Function ReplaceStrings(','Const ASource : String) : String; virtua'+ + 'l;'#010+ ' end;'#010+ #010+ - ' ECollectionError = Class(Exception)',';'#010+ + ' ECollectionError = Class(Exception);'#010+ ' EDictionaryError = Class(Exception);'#010+ ' EInstallerError = Class(Exception);'#010+ #010+ ' TInstallerClass = Class of TCustomInstaller;'#010+ - ' TDictionaryClass = Class of TDictionary;'#010+ + ' TDictionaryClass = Clas','s of TDictionary;'#010+ #010+ 'Type'#010+ - ' TArchiveEvent = Procedure (Const AFileName : String; List : TS','trin'+ - 'gs) of Object;'#010+ + ' TArchiveEvent = Procedure (Const AFileName : String; List : TStrings'+ + ') of Object;'#010+ ' TArchiveProc = Procedure (Const AFileName : String; List : TStrings)'+ ';'#010+ #010+ 'Var'#010+ ' DictionaryClass : TDictionaryClass = TDictionary;'#010+ - ' OnArchiveFiles : TArchiveEvent = Nil;'#010+ + ' On','ArchiveFiles : TArchiveEvent = Nil;'#010+ ' ArchiveFilesProc : TArchiveProc = Nil;'#010+ #010+ - 'Function C','urrentOS : String;'#010+ + 'Function CurrentOS : String;'#010+ 'Function CurrentCPU : String;'#010+ #010+ 'Function Installer(InstallerClass: TInstallerClass) : TCustomInstaller'+ '; overload;'#010+ - 'Function Installer : TCustomInstaller; overload;'#010+ + 'Function Installer :',' TCustomInstaller; overload;'#010+ #010+ - 'Function Defaults : TCustomDefaults; // Set by installer.'#010, + 'Function Defaults : TCustomDefaults; // Set by installer.'#010+ 'Function Dictionary : TDictionary;'#010+ #010+ 'Function OSToString(OS: TOS) : String;'#010+ 'Function OSesToString(OSes: TOSes) : String;'#010+ - 'Function CPUToString(CPU: TCPU) : String;'#010+ + 'Function CPUToString(CPU: TCPU) ',': String;'#010+ 'Function CPUSToString(CPUS: TCPUS) : String;'#010+ - 'Function StringToOS(const S : Str','ing) : TOS;'#010+ + 'Function StringToOS(const S : String) : TOS;'#010+ 'Function OSesToString(const S : String) : TOSes;'#010+ 'Function StringToCPU(const S : String) : TCPU;'#010+ - 'Function StringToCPUS(const S : String) : TCPUS;'#010+ + 'Function StringToCPUS(const S : String) : TC','PUS;'#010+ 'Function ModeToString(Mode: TCompilerMode) : String;'#010+ - 'Function StringToMode(const S ',': String) : TCompilerMode;'#010+ + 'Function StringToMode(const S : String) : TCompilerMode;'#010+ 'Function MakeTargetString(CPU : TCPU;OS: TOS) : String;'#010+ - 'Procedure StringToCPUOS(const S : String; Var CPU : TCPU; Var OS: TOS)'+ - ';'#010+ + 'Procedure StringToCPUOS(const S : String; Var CPU : TCPU; Var OS: TOS', + ');'#010+ 'Function FixPath (const APath : String) : String;'#010+ - 'Procedure ChangeDir(const APath : S','tring);'#010+ + 'Procedure ChangeDir(const APath : String);'#010+ 'Function Substitute(Const Source : String; Macros : Array of string) :'+ ' String;'#010+ - 'Procedure SplitCommand(Const Cmd : String; Var Exe,Options : String);'#010+ + 'Procedure SplitCommand(Const Cmd : String; Var Exe,Options : Stri','ng)'+ + ';'#010+ #010+ 'Implementation'#010+ #010+ 'uses typinfo;'#010+ #010+ 'ResourceString'#010+ - ' SErrInvalidCPU = '#039'Invalid C','PU name : "%s"'#039';'#010+ + ' SErrInvalidCPU = '#039'Invalid CPU name : "%s"'#039';'#010+ ' SErrInvalidOS = '#039'Invalid OS name : "%s"'#039';'#010+ ' SErrInvalidMode = '#039'Invalid compiler mode : "%s"'#039';'#010+ - ' SErrInvalidTarget = '#039'Invalid compiler target: %s'#039';'#010+ - ' SErrNameExists = '#039'Name "%s" already exists in t','he colle'+ - 'ction.'#039';'#010+ + ' SErrInvalidTarget =',' '#039'Invalid compiler target: %s'#039';'#010+ + ' SErrNameExists = '#039'Name "%s" already exists in the collect'+ + 'ion.'#039';'#010+ ' SErrNoSuchName = '#039'Could not find item with name "%s" in t'+ 'he collection.'#039';'#010+ - ' SErrNoPackage = '#039'No package available. Add package with '+ - 'StartPackage Call'#039';'#010+ - ' SErrInValidArgument = '#039'Invalid command-line argume','nt at posi'+ - 'tion %d : %s'#039';'#010+ + ' SErrNoPackage = '#039'No package available. Add',' package wit'+ + 'h StartPackage Call'#039';'#010+ + ' SErrInValidArgument = '#039'Invalid command-line argument at positi'+ + 'on %d : %s'#039';'#010+ ' SErrNeedArgument = '#039'Option at position %d (%s) needs an arg'+ 'ument'#039';'#010+ - ' SErrNoPackagesDefined = '#039'No action pOSesible: No packages were d'+ - 'efined.'#039';'#010+ - ' SErrInstaller = '#039'The installer encountered the followin', - 'g error:'#039';'#010+ + ' SErrNoPackagesDefined = '#039'No action pOSesible: No pa','ckages were'+ + ' defined.'#039';'#010+ + ' SErrInstaller = '#039'The installer encountered the following'+ + ' error:'#039';'#010+ ' SErrDepUnknownTarget = '#039'Unknown target in dependencies for %s: '+ '%s'#039';'#010+ ' SErrExternalCommandFailed = '#039'External command "%s" failed with e'+ - 'xit code: %d'#039';'#010+ + 'xit ','code: %d'#039';'#010+ ' SErrCreatingDirectory = '#039'Failed to create directory: "%s"'#039';'#010+ - ' SErrDeletingF','ile = '#039'Failed to delete file: "%s"'#039';'#010+ + ' SErrDeletingFile = '#039'Failed to delete file: "%s"'#039';'#010+ ' SErrMovingFile = '#039'Failed to move file "%s" to "%s"'#039';'#010+ - ' SErrCopyingFile = '#039'Failed to copy file "%s" to "%s"'#039';'#010+ + ' SErrCopyingFile = '#039'Failed to copy file "','%s" to "%s"'#039';'+ + #010+ ' SErrChangeDirFailed = '#039'Failed to enter directory: %s'#039';'#010+ - ' SErrInvalidAr','gumentToSubstitute = '#039'Invalid number of arguments'+ - ' to Substitute'#039';'#010+ + ' SErrInvalidArgumentToSubstitute = '#039'Invalid number of arguments t'+ + 'o Substitute'#039';'#010+ ' SErrNoArchiveSupport = '#039'This binary contains no archive support'+ - '. Please recompile with archive support'#039';'#010+ + '. Please recompile w','ith archive support'#039';'#010+ ' SErrNoDictionaryItem = '#039'No item called "%s" in the dictionary'#039+ - ';',#010+ + ';'#010+ ' SErrNoDictionaryValue = '#039'The item "%s" in the dictionary is not '+ 'a value.'#039';'#010+ ' SErrNoDictionaryFunc = '#039'The item "%s" in the dictionary is not '+ - 'a function.'#039';'#010+ + 'a functi','on.'#039';'#010+ ' SErrInvalidFPCInfo = '#039'Compiler returns invalid information, c'+ - 'heck if fpc -iV ','works'#039';'#010+ + 'heck if fpc -iV works'#039';'#010+ ' SErrDependencyNotFound = '#039'Could not find unit directory for depe'+ 'ndency package "%s"'#039';'#010+ - ' SWarnCircularDependency = '#039'Warning: Circular dependency detected'+ - ' when compiling target %s: %s'#039';'#010+ - ' SWarnFailedToSetTime = '#039'Warning: Failed to ','set timestamp on f'+ - 'ile : %s'#039';'#010+ + ' SWarnCircularDependency = '#039'Warning: Circular dependenc','y detect'+ + 'ed when compiling target %s: %s'#039';'#010+ + ' SWarnFailedToSetTime = '#039'Warning: Failed to set timestamp on fil'+ + 'e : %s'#039';'#010+ ' SWarnFailedToGetTime = '#039'Warning: Failed to get timestamp from f'+ 'ile : %s'#039';'#010+ - ' SWarnFileDoesNotExist = '#039'Warning: File "%s" does not exist'#039';'+ - #010+ + ' SWarnFileDoesNotExist = '#039'Warning: File "%s" ','does not exist'#039+ + ';'#010+ ' SWarnAttemptingToCompileNonNeutralTarget = '#039'Attempting to compil'+ - 'e non','-neutral target: %s'#039';'#010+ + 'e non-neutral target: %s'#039';'#010+ ' SDebugCompilingDependenciesOfTarget = '#039'Compiling dependencies of'+ ' target: %s'#039';'#010+ - ' SDebugResolvedSourceFile = '#039'Resolved source file %s to "%s"'#039';'+ - #010+ + ' SDebugResolvedSourceFile = '#039'Resolved source file',' %s to "%s"'#039+ + ';'#010+ ' SDebugResolvedIncludeFile = '#039'Resolved include file %s to "%s"'#039+ ';'#010+ - ' SDebug','OutputNotYetAvailable = '#039'Output file %s not available'#039+ - ';'#010+ + ' SDebugOutputNotYetAvailable = '#039'Output file %s not available'#039';'+ + #010+ ' SDebugDependencyOnUnit = '#039'Dependency of %s on unit %s'#039';'#010+ - ' SDebugDependencyUnitRecompiled = '#039'Dependent unit %s is being rec'+ - 'ompiled'#039';'#010+ + ' SDebugDependencyUnitRecompiled = '#039'De','pendent unit %s is being r'+ + 'ecompiled'#039';'#010+ ' SDebugMustCompile = '#039'Must compile %s'#039';'#010+ - ' SD','ebugTargetHasWrongOS = '#039'Target has wrong OS: %s'#039';'#010+ + ' SDebugTargetHasWrongOS = '#039'Target has wrong OS: %s'#039';'#010+ ' SDebugTargetHasWrongCPU = '#039'Target has wrong CPU: %s'#039';'#010+ - ' SDebugTargetIsNotAUnitOrProgram = '#039'Target %s is not a unit or pr'+ - 'ogram'#039';'#010+ + ' SDebugTargetIsNotAUnitOrProgram = '#039'Target',' %s is not a unit or '+ + 'program'#039';'#010+ ' SDebugConsideringTarget = '#039'Considering target: %s'#039';'#010+ - ' S','DebugUnresolvedExternalDependencyS = '#039'Unresolved external dep'+ - 'endency : %s'#039';'#010+ + ' SDebugUnresolvedExternalDependencyS = '#039'Unresolved external depen'+ + 'dency : %s'#039';'#010+ ' SDebugBuildEngineArchiving = '#039'Build engine archiving.'#039';'#010+ - ' SDebugBuildEngineCleaning = '#039'Build engine cleaning.'#039';'#010+ + ' SDebugBuildEngin','eCleaning = '#039'Build engine cleaning.'#039';'#010+ ' SCmdGenerating = '#039'Generating %s'#039';'#010+ - ' SInf','oArchiving = '#039'Archiving : %s'#039';'#010+ + ' SInfoArchiving = '#039'Archiving : %s'#039';'#010+ #010+ ' // Log messages'#010+ ' SLogEnterDir = '#039'Entering directory: %s'#039';'#010+ - ' SLogCompilingPackage = '#039'Compiling package : %s'#039';'#010+ + ' SLogCompilingPackage = '#039'Compiling pac','kage : %s'#039';'#010+ ' SLogCompilingTarget = '#039'Compiling target : %s'#039';'#010+ - ' SLogExecutingCommand ',' = '#039'Executing command : %s %s'#039';'#010+ + ' SLogExecutingCommand = '#039'Executing command : %s %s'#039';'#010+ ' SLogCreatingOutputDir = '#039'Creating output dir : %s'#039';'#010+ ' SLogOutputDirExists = '#039'Output dir exists : %s'#039';'#010+ - ' SLogInstallingPackage = '#039'Installing package : %s'#039';'#010+ - ' SLogArchivingPackage = '#039'Archiving package',' : %s'#039';'#010+ + ' SLogInsta','llingPackage = '#039'Installing package : %s'#039';'#010+ + ' SLogArchivingPackage = '#039'Archiving package : %s'#039';'#010+ ' SLogCleaningPackage = '#039'Cleaning package : %s'#039';'#010+ ' SLogCopyingFile = '#039'Copying file "%s" to "%s"'#039';'#010+ - ' SLogCompilingFileTimes = '#039'Comparing file "%s" time "%s" to "%s" '+ - 'time "%s".'#039';'#010+ - ' SLogSourceNewerDest = '#039'Source file "%s" ','(%s) is newer than '+ - 'destination "%s" (%s).'#039';'#010+ + ' SLogCompilingFileTimes = '#039'Comparin','g file "%s" time "%s" to "%s'+ + '" time "%s".'#039';'#010+ + ' SLogSourceNewerDest = '#039'Source file "%s" (%s) is newer than de'+ + 'stination "%s" (%s).'#039';'#010+ #010+ ' // Help messages for usage'#010+ ' SValue = '#039'Value'#039';'#010+ - ' SHelpUsage = '#039'Usage: %s command [options]'#039';'#010+ + ' SHelpUsage = '#039'Usage: %s command [o','ptions]'#039';'#010+ ' SHelpCommand = '#039'Where command is one of the following:'#039+ ';'#010+ - ' SHelpCompi','le = '#039'Compile all units in the package(s).'#039+ - ';'#010+ - ' SHelpBuild = '#039'Build all units in the package(s).'#039';'#010+ - ' SHelpInstall = '#039'Install all units in the package(s).'#039';'+ + ' SHelpCompile = '#039'Compile all units in the package(s).'#039';'+ #010+ - ' SHelpClean = '#039'Clean (remove) all units in the packa','ge'+ - '(s).'#039';'#010+ + ' SHelpBuild = '#039'Build all units in the package(s).'#039';'#010+ + ' SHelpInstall = '#039'Install all u','nits in the package(s).'#039+ + ';'#010+ + ' SHelpClean = '#039'Clean (remove) all units in the package(s'+ + ').'#039';'#010+ ' SHelpArchive = '#039'Create archive (zip) with all units in th'+ 'e package(s).'#039';'#010+ ' SHelpHelp = '#039'This message.'#039';'#010+ - ' SHelpManifest = '#039'Create a manifest suitable for import in '+ - 'repository.'#039';'#010+ - ' SHelpCmdOptions = '#039'Whe','re options is one or more of the fol'+ - 'lowing:'#039';'#010+ + ' SHelpManifest ',' = '#039'Create a manifest suitable for import i'+ + 'n repository.'#039';'#010+ + ' SHelpCmdOptions = '#039'Where options is one or more of the follo'+ + 'wing:'#039';'#010+ ' SHelpCPU = '#039'Compile for indicated CPU.'#039';'#010+ - ' SHelpOS = '#039'Compile for indicated OS'#039';'#010+ + ' SHelpOS = '#039'Compile for indicated OS'#039';'#010, ' SHelpTarget = '#039'Compile for indicated target'#039';'#010+ - ' SHelpList = '#039'list co','mmands instead of actually execu'+ - 'ting them.'#039';'#010+ + ' SHelpList = '#039'list commands instead of actually executi'+ + 'ng them.'#039';'#010+ ' SHelpPrefix = '#039'Use indicated prefix directory for all co'+ 'mmands.'#039';'#010+ - ' SHelpNoDefaults = '#039'Do not use defaults when compiling.'#039';'+ - #010+ - ' SHelpBaseInstallDir = '#039'Use indicated directory as base',' install'+ - ' dir.'#039';'#010+ + ' SHelpNoFPCCfg = '#039'Compil','er will not use fpc.cfg'#039';'#010+ + ' SHelpBaseInstallDir = '#039'Use indicated directory as base install d'+ + 'ir.'#039';'#010+ ' SHelpLocalUnitDir = '#039'Use indicated directory as local (user) u'+ 'nit dir.'#039';'#010+ - ' SHelpGlobalUnitDir = '#039'Use indicated directory as global unit di'+ - 'r.'#039';'#010+ + ' SHelpGlobalUnitDir = '#039'Use indicated directory as global unit d', + 'ir.'#039';'#010+ ' SHelpCompiler = '#039'Use indicated binary as compiler'#039';'#010+ - ' SHelpConfig ',' = '#039'Use indicated config file when compilin'+ - 'g.'#039';'#010+ + ' SHelpConfig = '#039'Use indicated config file when compiling.'+ + #039';'#010+ ' SHelpVerbose = '#039'Be verbose when working.'#039';'#010+ #010+ #010+ 'Const'#010+ - ' // Keys for Defaults file. Do not localize.'#010+ + ' // Keys for Defaults file. Do not localize.',#010+ ' KeyCompiler = '#039'Compiler'#039';'#010+ ' KeyArchive = '#039'Archive'#039';'#010+ ' KeyCopy = '#039'Copy'#039';'#010+ - ' ','KeyMkDir = '#039'MkDir'#039';'#010+ + ' KeyMkDir = '#039'MkDir'#039';'#010+ ' KeyMove = '#039'Move'#039';'#010+ ' KeyRemove = '#039'Remove'#039';'#010+ ' KeyOptions = '#039'Options'#039';'#010+ ' KeyCPU = '#039'CPU'#039';'#010+ ' KeyOS = '#039'OS'#039';'#010+ - ' KeyMode = '#039'Mode'#039';'#010+ + ' KeyMode ',' = '#039'Mode'#039';'#010+ ' KeyPrefix = '#039'Prefix'#039';'#010+ ' KeyTarget = '#039'Target'#039';'#010+ - ' KeyLocalUnitDir ',' = '#039'LocalUnitDir'#039';'#010+ + ' KeyNoFPCCfg = '#039'NoFPCCfg'#039';'#010+ + ' KeyLocalUnitDir = '#039'LocalUnitDir'#039';'#010+ ' KeyGlobalUnitDir = '#039'GlobalUnitDir'#039';'#010+ ' KeyBaseInstallDir = '#039'BaseInstallDir'#039';'#010+ - ' KeyUnitInstallDir = '#039'UnitInstallDir'#039';'#010+ + ' KeyUnitInstallDir ',' = '#039'UnitInstallDir'#039';'#010+ ' KeyBinInstallDir = '#039'BinInstallDir'#039';'#010+ - ' KeyDocInstallDir = '#039'DocInstallDir'#039';'#010, + ' KeyDocInstallDir = '#039'DocInstallDir'#039';'#010+ ' KeyExamplesInstallDir = '#039'ExamplesInstallDir'#039';'#010+ ' KeySourceExt = '#039'SourceExt'#039';'#010+ #010+ #010+ - '{*********************************************************************'+ - '*******'#010+ + '{*************************************************','******************'+ + '*********'#010+ ' Helpers'#010+ - '******************************************','**************************'+ - '********}'#010+ + '**********************************************************************'+ + '******}'#010+ #010+ 'Procedure SplitVersion(AValue: String; Var Release,Major,Minor : Word;'+ - ' Var Suffix : String);'#010+ + ' Var Suffix : String);'#010, #010+ ' Function NextDigit(sep : Char; var V : string) : integer;'#010+ ' Var'#010+ ' P : Integer;'#010+ ' begin'#010+ - ' P:=Pos(Sep,V);',#010+ + ' P:=Pos(Sep,V);'#010+ ' If (P=0) then'#010+ ' P:=Length(V)+1;'#010+ ' Result:=StrToIntDef(Copy(V,1,P-1),-1);'#010+ ' If Result<>-1 then'#010+ ' Delete(V,1,P)'#010+ - ' else'#010+ + ' ',' else'#010+ ' Result:=0;'#010+ ' end;'#010+ #010+ @@ -1323,13 +1326,13 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Release:=0;'#010+ ' Major:=0;'#010+ ' Minor:=0;'#010+ - ' ','Suffix:='#039#039';'#010+ + ' Suffix:='#039#039';'#010+ ' V:=AValue;'#010+ ' Release:=NextDigit('#039'.'#039',V);'#010+ ' Major:=NextDigit('#039'.'#039',V);'#010+ ' Minor:=NextDigit('#039'-'#039',V);'#010+ ' P:=Pos('#039'-'#039',V);'#010+ - ' If (P<>0) then'#010+ + ' If ','(P<>0) then'#010+ ' Delete(V,1,P);'#010+ ' Suffix:=V;'#010+ 'end;'#010+ @@ -1337,18 +1340,18 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'Function QuoteXML(S : String) : string;'#010+ #010+ - ' Procedure W(Var ','J : Integer; Var R : String; T : String);'#010+ + ' Procedure W(Var J : Integer; Var R : String; T : String);'#010+ ' Var'#010+ ' I: integer;'#010+ ' begin'#010+ ' If J+Length(T)>Length(R) then'#010+ - ' SetLength(R,J+Length(T));'#010+ + ' SetLength(R,J+Leng','th(T));'#010+ ' For I:=1 to Length(t) do'#010+ ' begin'#010+ ' R[J]:=T[i];'#010+ ' If ILength(Result) then'#010+ ' SetLength(Result,J);'#010+ 'end;'#010+ #010+ #010+ - '// Callback for Sysutils',' getapplicationname.'#010+ + '// Callback for Sysutils getapplicationname.'#010+ 'Function GetFPMakeName : String;'#010+ #010+ 'begin'#010+ @@ -1395,14 +1398,14 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'Function CurrentOS : String;'#010+ #010+ 'begin'#010+ - ' Result:=OSToString(Defaults.OS);'#010+ + ' Resu','lt:=OSToString(Defaults.OS);'#010+ 'end;'#010+ #010+ 'Function CurrentCPU : String;'#010+ #010+ 'begin'#010+ ' Result:=CPUToString(Defaults.CPU);'#010+ - 'e','nd;'#010+ + 'end;'#010+ #010+ 'Function OSToString(OS: TOS) : String;'#010+ #010+ @@ -1410,11 +1413,11 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Result:=LowerCase(GetenumName(TypeInfo(TOS),Ord(OS)));'#010+ 'end;'#010+ #010+ - 'Function OSesToString(OSes: TOSes) : String;'#010+ + 'Function OSesToS','tring(OSes: TOSes) : String;'#010+ #010+ 'begin'#010+ ' Result:=LowerCase(SetToString(PtypeInfo(TypeInfo(TOSes)),Integer(OSe'+ - 's),F','alse));'#010+ + 's),False));'#010+ 'end;'#010+ #010+ 'Function CPUToString(CPU: TCPU) : String;'#010+ @@ -1423,11 +1426,11 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Result:=LowerCase(GetenumName(TypeInfo(TCPU),Ord(CPU)));'#010+ 'end;'#010+ #010+ - 'Function CPUSToString(CPUS: TCPUS) : String;'#010+ + 'Fu','nction CPUSToString(CPUS: TCPUS) : String;'#010+ #010+ 'begin'#010+ - ' Result:=LowerCase(SetToString(PTypeInfo(TypeInfo(TCPUS)),I','nteger(C'+ - 'PUS),False));'#010+ + ' Result:=LowerCase(SetToString(PTypeInfo(TypeInfo(TCPUS)),Integer(CPU'+ + 'S),False));'#010+ 'end;'#010+ #010+ 'Function StringToOS(const S : String) : TOS;'#010+ @@ -1436,149 +1439,150 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' I : Integer;'#010+ #010+ 'begin'#010+ - ' I:=GetEnumValue(TypeInfo(TOS),S);'#010+ + ' I:=GetEnumValue(TypeInfo(TOS','),S);'#010+ ' if (I=-1) then'#010+ ' Raise EInstallerError.CreateFmt(SErrInvalidOS,[S]);'#010+ ' Result:=TOS(I);'#010+ 'end;'#010+ #010+ #010+ - 'Functi','on OSesToString(const S : String) : TOSes;'#010+ + 'Function OSesToString(const S : String) : TOSes;'#010+ #010+ 'begin'#010+ ' Result:=TOSes(StringToSet(PTypeInfo(TypeInfo(TOSes)),S));'#010+ 'end;'#010+ #010+ - 'Function StringToCPU(const S : String) : TCPU;'#010+ + 'Function Strin','gToCPU(const S : String) : TCPU;'#010+ #010+ 'Var'#010+ ' I : Integer;'#010+ #010+ 'begin'#010+ ' I:=GetEnumValue(TypeInfo(TCPU),S);'#010+ - ' if (I=-1) t','hen'#010+ + ' if (I=-1) then'#010+ ' Raise EInstallerError.CreateFmt(SErrInvalidCPU,[S]);'#010+ ' Result:=TCPU(I);'#010+ 'end;'#010+ #010+ - 'Function StringToCPUS(const S : String) : TCPUS;'#010+ + 'Function StringToCPUS(const S : String) : TC','PUS;'#010+ #010+ 'begin'#010+ ' Result:=TCPUS(StringToSet(PTypeInfo(TypeInfo(TCPUS)),S));'#010+ 'end;'#010+ #010+ - 'Function ModeToString(Mode: TCom','pilerMode) : String;'#010+ + 'Function ModeToString(Mode: TCompilerMode) : String;'#010+ #010+ 'begin'#010+ ' Result:=LowerCase(GetenumName(TypeInfo(TCompilerMode),Ord(Mode)));'#010+ + ' Delete(Result,1,2);'#010+ 'end;'#010+ #010+ - 'Function StringToMode(const S : String) : TCompilerMode;'#010+ + 'Funct','ion StringToMode(const S : String) : TCompilerMode;'#010+ #010+ 'Var'#010+ ' I : Integer;'#010+ #010+ 'begin'#010+ ' I:=GetEnumValue(TypeInfo(TCompilerMode),S);'#010+ - ' if (I','=-1) then'#010+ + ' if (I=-1) then'#010+ ' Raise EInstallerError.CreateFmt(SErrInvalidMode,[S]);'#010+ ' Result:=TCompilerMode(I);'#010+ 'end;'#010+ #010+ #010+ - 'Function MakeTargetString(CPU : TCPU;OS: TOS) : String;'#010+ + 'Funct','ion MakeTargetString(CPU : TCPU;OS: TOS) : String;'#010+ #010+ 'begin'#010+ ' Result:=CPUToString(CPU)+'#039'-'#039'+OSToString(OS);'#010+ 'end;'#010+ #010+ - 'Procedure StringToCPU','OS(const S : String; Var CPU : TCPU; Var OS: TO'+ - 'S);'#010+ + 'Procedure StringToCPUOS(const S : String; Var CPU : TCPU; Var OS: TOS)'+ + ';'#010+ #010+ 'Var'#010+ ' P : integer;'#010+ #010+ 'begin'#010+ ' P:=Pos('#039'-'#039',S);'#010+ - ' If (P=0) then'#010+ + ' If (P=0) th','en'#010+ ' Raise EInstallerError.CreateFmt(SErrInvalidTarget,[S]);'#010+ ' CPU:=StringToCPU(Copy(S,1,P-1));'#010+ - ' OS:=StringToOs(Copy(S,P+1,Length','(S)-P));'#010+ + ' OS:=StringToOs(Copy(S,P+1,Length(S)-P));'#010+ 'end;'#010+ #010+ #010+ 'Procedure ResolveDependencies(L : TDependencies; P : TNamedCollection)'+ ';'#010+ 'Var'#010+ - ' I,J : Integer;'#010+ + ' I,J : Integer;',#010+ ' C : TDependency;'#010+ 'begin'#010+ ' If Assigned(L) then'#010+ ' For I:=0 to L.Count-1 do'#010+ ' begin'#010+ ' C:=L[i];'#010+ - ' if C.DependencyTyp','e in [depPackage,depUnit] then'#010+ + ' if C.DependencyType in [depPackage,depUnit] then'#010+ ' begin'#010+ ' J:=P.IndexOfName(C.Value);'#010+ - ' If J<>-1 then'#010+ + ' If J<>-1 t','hen'#010+ ' C.Target:=P.Items[J];'#010+ ' end;'#010+ ' end;'#010+ 'end;'#010+ #010+ #010+ - 'function AddConditionalStrings(Dest : TStrings; Src : TCond','itionalSt'+ - 'rings;ACPU:TCPU;AOS:TOS; Const APrefix : String='#039#039') : Integer ;'#010+ + 'function AddConditionalStrings(Dest : TStrings; Src : TConditionalStri'+ + 'ngs;ACPU:TCPU;AOS:TOS; Const APrefix : String='#039#039') : Integer ;'#010+ 'Var'#010+ ' I : Integer;'#010+ - ' C : TConditionalString;'#010+ + ' C : TCondition','alString;'#010+ 'begin'#010+ ' Result:=0;'#010+ ' For I:=0 to Src.Count-1 do'#010+ ' begin'#010+ ' C:=Src[I];'#010+ - ' if (ACPU in C.CPUs) and (AOS in C.OSes) t','hen'#010+ + ' if (ACPU in C.CPUs) and (AOS in C.OSes) then'#010+ ' begin'#010+ ' If (APrefix<>'#039#039') then'#010+ ' Dest.Add(APrefix+C.Value)'#010+ ' else'#010+ - ' Dest.Add(C.Value);'#010+ + ' ',' Dest.Add(C.Value);'#010+ ' Inc(Result);'#010+ ' end;'#010+ ' end;'#010+ 'end;'#010+ #010+ #010+ - 'Procedure AddConditionalStrings(Var S : String; Src : ','TConditionalSt'+ - 'rings;ACPU:TCPU;AOS:TOS; const APrefix : String='#039#039');'#010+ + 'Procedure AddConditionalStrings(Var S : String; Src : TConditionalStri'+ + 'ngs;ACPU:TCPU;AOS:TOS; const APrefix : String='#039#039');'#010+ 'Var'#010+ ' I : Integer;'#010+ - ' C : TConditionalString;'#010+ + ' C : TConditionalStri','ng;'#010+ 'begin'#010+ ' For I:=0 to Src.Count-1 do'#010+ ' begin'#010+ ' C:=Src[I];'#010+ ' if (ACPU in C.CPUs) and (AOS in C.OSes) then'#010+ ' begin'#010+ - ' ',' if (S<>'#039#039') then'#010+ + ' if (S<>'#039#039') then'#010+ ' S:=S+'#039' '#039';'#010+ ' S:=S+APrefix+C.Value;'#010+ ' end;'#010+ ' end;'#010+ 'end;'#010+ #010+ - #010+ + #010, 'Function EnsureConditionalStrings(Var S : TConditionalStrings) : TCond'+ 'itionalStrings;'#010+ 'begin'#010+ ' If (S=Nil) then'#010+ - ' S:=TConditionalStr','ings.Create(TConditionalString);'#010+ + ' S:=TConditionalStrings.Create(TConditionalString);'#010+ ' Result:=S;'#010+ 'end;'#010+ #010+ #010+ - 'function FileListToString(List : TStrings; const APrefix : String) : S'+ - 'tring;'#010+ + 'function FileListToString(List : TStrings; const APrefi','x : String) :'+ + ' String;'#010+ 'Var'#010+ ' I : integer;'#010+ ' S : String;'#010+ @@ -1586,12 +1590,12 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Result:='#039#039';'#010+ ' For I:=0 to List.Count-1 do'#010+ ' begin'#010+ - ' If (I>0) then',#010+ + ' If (I>0) then'#010+ ' Result:=Result+'#039' '#039';'#010+ ' S:=APrefix+List[i];'#010+ ' If (Pos('#039' '#039',S)<>0) then'#010+ ' S:='#039'"'#039'+S+'#039'"'#039';'#010+ - ' Result:=Result+S;'#010+ + ' Resul','t:=Result+S;'#010+ ' end;'#010+ 'end;'#010+ #010+ @@ -1602,13 +1606,13 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'begin'#010+ ' Result:=APath;'#010+ - ' If (result','<>'#039#039') then'#010+ + ' If (result<>'#039#039') then'#010+ ' begin'#010+ ' P:=PChar(Result);'#010+ ' While (P^<>#0) do'#010+ ' begin'#010+ ' If P^ in ['#039'/'#039','#039'\'#039'] then'#010+ - ' P^:=PathDelim;'#010+ + ' ',' P^:=PathDelim;'#010+ ' Inc(P);'#010+ ' end;'#010+ ' end;'#010+ @@ -1617,34 +1621,34 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'procedure ChangeDir(const APath : String);'#010+ #010+ 'begin'#010+ - ' if Not SetCurrentD','ir(APath) then'#010+ + ' if Not SetCurrentDir(APath) then'#010+ ' Raise EInstallerError.CreateFmt(SErrChangeDirFailed,[APath]);'#010+ 'end;'#010+ #010+ #010+ - 'procedure SearchFiles(const AFileName: string; Recursive: boolean; var'+ - ' List: TStrings);'#010+ + 'procedure SearchFile','s(const AFileName: string; Recursive: boolean; v'+ + 'ar List: TStrings);'#010+ #010+ - ' procedure AddRecursiveFiles(const SearchDir, FileMask: string','; Rec'+ - 'ursive: boolean);'#010+ + ' procedure AddRecursiveFiles(const SearchDir, FileMask: string; Recur'+ + 'sive: boolean);'#010+ ' const'#010+ ' IgnoreCase = {$ifdef UNIX}False{$else}True{$endif};'#010+ ' var'#010+ - ' Info : TSearchRec;'#010+ + ' Info : TSea','rchRec;'#010+ ' begin'#010+ ' if FindFirst(SearchDir+'#039'*'#039',faAnyFile and faDirectory,Info)'+ '=0 then'#010+ ' begin'#010+ ' repeat'#010+ - ' if ((Info.Att','r and faDirectory) = faDirectory) and (Info.N'+ - 'ame <> '#039'.'#039') and (Info.Name <> '#039'..'#039') and (Recursive) th'+ - 'en'#010+ - ' AddRecursiveFiles(SearchDir + Info.Name + PathDelim, FileM'+ - 'ask, Recursive);'#010+ - ' if ((Info.Attr and faDirectory) <> faDire','ctory) and IsWild'+ - '(Info.Name, FileMask, IgnoreCase) then'#010+ + ' if ((Info.Attr and faDirectory) = faDirectory) and (Info.Nam'+ + 'e <> '#039'.'#039') and (Info.Name <> '#039'..'#039') and (Recursive) then'+ + #010+ + ' ',' AddRecursiveFiles(SearchDir + Info.Name + PathDelim, Fil'+ + 'eMask, Recursive);'#010+ + ' if ((Info.Attr and faDirectory) <> faDirectory) and IsWild(I'+ + 'nfo.Name, FileMask, IgnoreCase) then'#010+ ' List.Add(SearchDir + Info.Name);'#010+ - ' until FindNext(Info)<>0;'#010+ + ' u','ntil FindNext(Info)<>0;'#010+ ' end;'#010+ ' FindClose(Info);'#010+ ' end;'#010+ @@ -1654,8 +1658,9 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' BasePath: string;'#010+ ' i: integer;'#010+ 'begin'#010+ - ' BasePath := E','xtractFilePath(ExpandFileName(AFileName));'#010+ - ' AddRecursiveFiles(BasePath, ExtractFileName(AFileName), Recursive);'#010+ + ' BasePath := ExtractFilePath(ExpandFileName(AFileName));'#010+ + ' AddRecursiveFiles(BasePath, ExtractFileName(AFileName), Recursi','ve)'+ + ';'#010+ #010+ ' CurrDir:=GetCurrentDir;'#010+ ' for i := 0 to Pred(List.Count) do'#010+ @@ -1663,11 +1668,11 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'pro','cedure SplitCommand(const Cmd : String; var Exe, Options : String'+ - ');'#010+ + 'procedure SplitCommand(const Cmd : String; var Exe, Options : String);'+ + #010+ #010+ 'Const'#010+ - ' WhiteSpace = [#9,#10,#13,'#039' '#039'];'#010+ + ' WhiteSpace = [#9,#10,#13,'#039' '#039'];'#010, ' QuoteChars = ['#039#039#039#039','#039'"'#039'];'#010+ #010+ 'Var'#010+ @@ -1678,23 +1683,23 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'begin'#010+ ' S:=Trim(Cmd);'#010+ - ' InQuo','te:=False;'#010+ + ' InQuote:=False;'#010+ ' LastQuote:=#0;'#010+ ' I:=1;'#010+ ' While (I<=Length(S)) and (Inquote or not (S[I] in whiteSpace)) do'#010+ - ' begin'#010+ + ' ','begin'#010+ ' If S[i] in QuoteChars then'#010+ ' begin'#010+ ' InQuote:=Not (S[i]=LastQuote);'#010+ ' If InQuote then'#010+ - ' LastQuote:=S[i]',#010+ + ' LastQuote:=S[i]'#010+ ' else'#010+ ' LastQuote:=#0;'#010+ ' end;'#010+ ' Inc(I);'#010+ ' end;'#010+ ' Exe:=Copy(S,1,I-1);'#010+ - ' Delete(S,1,I);'#010+ + ' Delete(S,1,I);'#010, ' Options:=Trim(S);'#010+ 'end;'#010+ #010+ @@ -1702,54 +1707,55 @@ const fpmkunitsrc : array[0..547,1..240] of char=( '{$ifdef HAS_UNIT_PROCESS}'#010+ 'function GetCompilerInfo(const ACompiler,AOptions:string):string;'#010+ 'const'#010+ - ' BufSi','ze = 1024;'#010+ + ' BufSize = 1024;'#010+ 'var'#010+ ' S: TProcess;'#010+ ' Buf: array [0..BufSize - 1] of char;'#010+ ' Count: longint;'#010+ 'begin'#010+ - ' S:=TProcess.Create(Nil);'#010+ + ' S:=TProcess.C','reate(Nil);'#010+ ' S.Commandline:=ACompiler+'#039' '#039'+AOptions;'#010+ ' S.Options:=[poUsePipes];'#010+ ' S.execute;'#010+ ' Count:=s.output.read(buf,BufSize);'#010+ - ' ','S.Free;'#010+ + ' S.Free;'#010+ ' SetLength(Result,Count);'#010+ ' Move(Buf,Result[1],Count);'#010+ 'end;'#010+ '{$endif HAS_UNIT_PROCESS}'#010+ #010+ #010+ - '{*********************************************************************'+ - '*******'#010+ + '{**********','*********************************************************'+ + '*********'#010+ ' TNamedItem'#010+ - '**********************','**********************************************'+ - '********}'#010+ + '**********************************************************************'+ + '******}'#010+ #010+ - 'procedure TNamedItem.SetName(const AValue: String);'#010+ + 'procedure TNamedItem.SetName(const AValue: String);',#010+ #010+ 'begin'#010+ ' if FName=AValue then exit;'#010+ ' With TNamedCollection(Collection) do'#010+ ' If UniqueNames then'#010+ - ' If (IndexOfName(AVAlue)<>-','1) then'#010+ + ' If (IndexOfName(AVAlue)<>-1) then'#010+ ' Raise ECollectionError.CreateFmt(SErrNameExists,[AValue]);'#010+ ' FName:=AValue;'#010+ 'end;'#010+ #010+ #010+ - '{*********************************************************************'+ - '*******'#010+ + '{********','***********************************************************'+ + '*********'#010+ ' TNamedCollection'#010+ - '**************','******************************************************'+ - '********}'#010+ + '**********************************************************************'+ + '******}'#010+ + #010+ + 'function TNamedCollection.IndexOfName(const',' AName: String): Integer;'+ #010+ - 'function TNamedCollection.IndexOfName(const AName: String): Integer;'#010+ #010+ 'begin'#010+ ' Result:=Count-1;'#010+ ' While (Result>=0) and (CompareText(TNamedItem(Items[Result]).FName,A'+ - 'Name)<>0) ','do'#010+ + 'Name)<>0) do'#010+ ' Dec(Result);'#010+ 'end;'#010+ #010+ @@ -1757,96 +1763,95 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ #010+ 'Var'#010+ - ' I : Integer;'#010+ + ' I : ','Integer;'#010+ #010+ 'begin'#010+ ' I:=IndexOfName(AName);'#010+ ' If (I=-1) Then'#010+ ' Raise ECollectionError.CreateFmt(SErrNoSuchName,[AName]);'#010+ - ' Result:=TN','amedItem(Items[i]);'#010+ - 'end;'#010+ - #010+ - #010+ - '{*********************************************************************'+ - '*******'#010+ - ' TNamedItemList'#010+ - '**********************************************************************'+ - '******}'#010+ - #010+ - 'function TNa','medItemList.GetNamedItem(Index : Integer): TNamedItem;'#010+ - 'begin'#010+ - ' Result:=TNamedItem(Items[Index]);'#010+ - 'end;'#010+ - #010+ - #010+ - 'procedure TNamedItemList.SetNamedItem(Index : Integer; const AValue: T'+ - 'NamedItem);'#010+ - 'begin'#010+ - ' Items[Index]:=AValue;'#010+ - 'end;'#010+ - #010+ - #010+ - 'function TNamedIt','emList.IndexOfName(const AName: String): Integer;'#010+ - 'begin'#010+ - ' Result:=Count-1;'#010+ - ' While (Result>=0) and (CompareText(GetNamedItem(Result).Name,AName)<'+ - '>0) do'#010+ - ' Dec(Result);'#010+ - 'end;'#010+ - #010+ - #010+ - 'function TNamedItemList.ItemByName(const ANAme: String): TNamedI','tem;'+ - #010+ - 'Var'#010+ - ' I : Integer;'#010+ - 'begin'#010+ - ' I:=IndexOfName(AName);'#010+ - ' If (I=-1) Then'#010+ - ' Raise ECollectionError.CreateFmt(SErrNoSuchName,[AName]);'#010+ ' Result:=TNamedItem(Items[i]);'#010+ 'end;'#010+ #010+ #010+ - '{******************************************************************','*'+ - '*********'#010+ - ' TTargets'#010+ + '{*********************************************************************'+ + '*******'#010+ + ' ',' TNamedItemList'#010+ '**********************************************************************'+ '******}'#010+ #010+ + 'function TNamedItemList.GetNamedItem(Index : Integer): TNamedItem;'#010+ + 'begin'#010+ + ' Result:=TNamedItem(Items[Index]);'#010+ + 'end;'#010+ + #010+ + #010+ + 'proc','edure TNamedItemList.SetNamedItem(Index : Integer; const AValue:'+ + ' TNamedItem);'#010+ + 'begin'#010+ + ' Items[Index]:=AValue;'#010+ + 'end;'#010+ + #010+ + #010+ + 'function TNamedItemList.IndexOfName(const AName: String): Integer;'#010+ + 'begin'#010+ + ' Result:=Count-1;'#010+ + ' While (Result>=0) and (CompareT','ext(GetNamedItem(Result).Name,AName'+ + ')<>0) do'#010+ + ' Dec(Result);'#010+ + 'end;'#010+ + #010+ + #010+ + 'function TNamedItemList.ItemByName(const ANAme: String): TNamedItem;'#010+ + 'Var'#010+ + ' I : Integer;'#010+ + 'begin'#010+ + ' I:=IndexOfName(AName);'#010+ + ' If (I=-1) Then'#010+ + ' Raise ECollectionError.CreateFmt','(SErrNoSuchName,[AName]);'#010+ + ' Result:=TNamedItem(Items[i]);'#010+ + 'end;'#010+ + #010+ + #010+ + '{*********************************************************************'+ + '*******'#010+ + ' TTargets'#010+ + '********************************************************','************'+ + '********}'#010+ + #010+ 'function TTargets.GetTargetItem(Index : Integer): TTarget;'#010+ 'begin'#010+ ' Result:=TTarget(Items[Index]);'#010+ 'end;'#010+ #010+ #010+ - 'func','tion TTargets.GetTarget(const AName : String): TTarget;'#010+ + 'function TTargets.GetTarget(const AName : String): TTarget;'#010+ 'begin'#010+ ' Result:=TTarget(ItemByName(AName));'#010+ 'end;'#010+ #010+ #010+ - 'procedure TTargets.SetTargetItem(Index : Integer; const AValue: TTarge'+ - 't);'#010+ + 'p','rocedure TTargets.SetTargetItem(Index : Integer; const AValue: TTar'+ + 'get);'#010+ 'begin'#010+ ' Items[Index]:=AValue;'#010+ 'end;'#010+ #010+ #010+ - 'Function TTargets.AddU','nit(const AUnitName : String) : TTarget;'#010+ + 'Function TTargets.AddUnit(const AUnitName : String) : TTarget;'#010+ 'begin'#010+ ' Result:=Add as TTarget;'#010+ ' Result.Name:=AUnitName;'#010+ - ' Result.TargetType:=TTUnit;'#010+ + ' Result.','TargetType:=TTUnit;'#010+ 'end;'#010+ #010+ #010+ 'Function TTargets.AddImplicitUnit(const AUnitName : String;InstallUnit'+ ':boolean=true) : TTarget;'#010+ 'begin'#010+ - ' R','esult:=Add as TTarget;'#010+ + ' Result:=Add as TTarget;'#010+ ' Result.Name:=AUnitName;'#010+ ' if InstallUnit then'#010+ - ' Result.TargetType:=TTImplicitUnit'#010+ + ' Result.TargetType:=TTImplicitUnit',#010+ ' else'#010+ ' Result.TargetType:=TTCleanOnlyUnit;'#010+ 'end;'#010+ @@ -1854,57 +1859,57 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'Function TTargets.AddProgram(const AProgramName: String) : TTarget;'#010+ 'begin'#010+ - ' R','esult:=Add as TTarget;'#010+ + ' Result:=Add as TTarget;'#010+ ' Result.Name:=AProgramName;'#010+ ' Result.TargetType:=ttProgram;'#010+ 'end;'#010+ #010+ #010+ - 'Function TTargets.AddExampleUnit(const AUnitName: String): TTarget;'#010+ + 'Function TTargets','.AddExampleUnit(const AUnitName: String): TTarget;'#010+ 'begin'#010+ ' Result:=Add as TTarget;'#010+ ' Result.Name:=AUnitName;'#010+ - ' Result.TargetType:=tt','ExampleUnit;'#010+ + ' Result.TargetType:=ttExampleUnit;'#010+ 'end;'#010+ #010+ #010+ 'Function TTargets.AddExampleProgram(const AProgramName: String): TTarg'+ 'et;'#010+ 'begin'#010+ - ' Result:=Add as TTarget;'#010+ + ' Result',':=Add as TTarget;'#010+ ' Result.Name:=AProgramName;'#010+ ' Result.TargetType:=ttExampleProgram;'#010+ 'end;'#010+ #010+ #010+ - '{**************************************','*****************************'+ - '*********'#010+ + '{*********************************************************************'+ + '*******'#010+ ' TSources'#010+ - '**********************************************************************'+ - '******}'#010+ + '****************************','****************************************'+ + '********}'#010+ #010+ 'function TSources.GetSourceItem(Index : Integer): TSource;'#010+ 'begin'#010+ - ' Result:=TSourc','e(Items[Index]);'#010+ + ' Result:=TSource(Items[Index]);'#010+ 'end;'#010+ #010+ #010+ 'procedure TSources.SetSourceItem(Index : Integer; const AValue: TSourc'+ 'e);'#010+ 'begin'#010+ - ' Items[Index]:=AValue;'#010+ + ' It','ems[Index]:=AValue;'#010+ 'end;'#010+ #010+ #010+ 'function TSources.AddDocFiles(const AFiles : String) : TSource;'#010+ 'begin'#010+ ' Result:=Add as TSource;'#010+ - ' Result.','Name:=AFiles;'#010+ + ' Result.Name:=AFiles;'#010+ ' Result.FSourceType:=stDoc;'#010+ 'end;'#010+ #010+ #010+ - 'function TSources.AddSrcFiles(const AFiles : String) : TSource;'#010+ + 'function TSources.AddSrcFiles(const AFiles : String) : TSo','urce;'#010+ 'begin'#010+ ' Result:=Add as TSource;'#010+ ' Result.Name:=AFiles;'#010+ @@ -1912,101 +1917,102 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'function TSources.AddExampleFiles(c','onst AFiles : String) : TSource;'#010+ + 'function TSources.AddExampleFiles(const AFiles : String) : TSource;'#010+ 'begin'#010+ ' Result:=Add as TSource;'#010+ ' Result.Name:=AFiles;'#010+ - ' Result.FSourceType:=stExample;'#010+ + ' Result.FSourceType',':=stExample;'#010+ 'end;'#010+ #010+ #010+ 'function TSources.AddTestFiles(const AFiles : String) : TSource;'#010+ 'begin'#010+ ' Result:=Add as TSource;'#010+ - ' Result.Name:=','AFiles;'#010+ + ' Result.Name:=AFiles;'#010+ ' Result.FSourceType:=stTest;'#010+ 'end;'#010+ #010+ #010+ - '{*********************************************************************'+ - '*******'#010+ + '{**************************************************************','*****'+ + '*********'#010+ ' TPackage'#010+ '**********************************************************************'+ '******}'#010+ - #010, + #010+ 'function TPackage.GetHasConditionalStrings(AIndex: integer): Boolean;'#010+ 'begin'#010+ ' Result:=False;'#010+ - ' Case AIndex Of'#010+ + ' Case AIndex O','f'#010+ ' 0 : Result:=FUnitPath<>Nil;'#010+ ' 1 : Result:=FObjectPath<>Nil;'#010+ ' 2 : Result:=FIncludePath<>Nil;'#010+ - ' 3 : Result:=FSourcePath<>','Nil;'#010+ + ' 3 : Result:=FSourcePath<>Nil;'#010+ ' 4 : Result:=FExamplePath<>Nil;'#010+ ' 5 : Result:=FTestPath<>Nil;'#010+ - ' 6 : Result:=FInstallFiles<>Nil;'#010+ + ' 6 : Result:=FInstallFiles<>Nil;'#010, ' 7 : Result:=FCleanFiles<>Nil;'#010+ ' 8 : Result:=FArchiveFiles<>Nil;'#010+ ' end;'#010+ 'end;'#010+ #010+ 'function TPackage.GetHasDependencies: Boolean;'#010+ - 'be','gin'#010+ + 'begin'#010+ ' Result:=FDependencies<>Nil;'#010+ 'end;'#010+ #010+ 'function TPackage.GetCommands: TCommands;'#010+ 'begin'#010+ - ' If Not Assigned(FCommands) then'#010+ + ' If Not Assigned(FC','ommands) then'#010+ ' FCommands:=TCommands.Create(TCommand);'#010+ ' Result:=FCommands;'#010+ 'end;'#010+ #010+ 'function TPackage.GetHasCommands: Boolean;'#010+ - 'begin',#010+ + 'begin'#010+ ' Result:=Assigned(FCommands);'#010+ 'end;'#010+ #010+ #010+ 'Procedure TPackage.GetManifest(Manifest : TStrings);'#010+ 'Var'#010+ - ' S : String;'#010+ + ' S : String',';'#010+ ' Release,Minor,Major : Word;'#010+ ' i : Integer;'#010+ ' D : TConditionalString;'#010+ 'begin'#010+ ' With Manifest do'#010+ ' begin'#010+ - ' Add(Format('#039''#039',[QuoteXml(Name)]));'#010+ + ' Add(Format('#039''#039',[QuoteXml(Name)]));'#010+ ' SplitVersion(Version,Release,Minor,Major,S);'#010+ - ' Add(Format('#039''#039',[Release,Minor,Major,QuoteXMl(S)]));'#010+ - ' Add(Format('#039'%s'#039',[Quot','eXml(FileName '+ - '+ ZipExt)]));'#010+ + ' Add(Format('#039''#039',[Release,Minor,Major,QuoteXMl(S)]));'#010+ + ' Add(Format('#039'%s'#039',[QuoteXml(FileName + '+ + 'ZipExt)]));'#010+ ' Add(Format('#039'%s'#039',[QuoteXml(Author)]));'#010+ - ' Add(Format('#039'%s'#039',[QuoteXml(License)]));'#010+ + ' Add(Format('#039'%s'#039',[QuoteXml(License)]))'+ + ';'#010+ ' if ExternalURL<>'#039#039' then'#010+ ' Add(Format('#039'%s'#039',[QuoteXml(Ext'+ - 'e','rnalURL)]));'#010+ + 'ernalURL)]));'#010+ ' Add(Format('#039'%s'#039',[QuoteXMl(Email)]));'#010+ ' S:=Description;'#010+ - ' If (S<>'#039#039') then'#010+ + ' If (S<>'#039#039') then',#010+ ' Add(Format('#039'%s'#039',[QuoteXML(S)]'+ '));'#010+ ' if HasDependencies then'#010+ ' begin'#010+ - ' If (Dependencies.','Count>0) then'#010+ + ' If (Dependencies.Count>0) then'#010+ ' begin'#010+ ' Add('#039''#039');'#010+ - ' for I:=0 to Dependencies.Count-1 do'#010+ + ' for I:=0 to Dependencies.Count-','1 do'#010+ ' begin'#010+ ' D:=Dependencies[i];'#010+ ' Add(Format('#039''#039',[QuoteXML(D.Value)]));'#010+ + '>'#039',[QuoteXML(D.Value)]));'#010+ ' end;'#010+ ' Add('#039''#039');'#010+ ' end;'#010+ - ' end;'#010+ + ' ',' end;'#010+ ' Add('#039''#039');'#010+ ' end;'#010+ 'end;'#010+ @@ -2014,129 +2020,129 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'function TPackage.GetConditionalStrings(AIndex: integer): TConditional'+ 'Strings;'#010+ 'begin'#010+ - ' ','Result:=Nil;'#010+ + ' Result:=Nil;'#010+ ' Case AIndex Of'#010+ ' 0 : Result:=EnsureConditionalStrings(FUnitPath);'#010+ - ' 1 : Result:=EnsureConditionalStrings(FObjectPath);'#010+ + ' 1 : Result:=EnsureCon','ditionalStrings(FObjectPath);'#010+ ' 2 : Result:=EnsureConditionalStrings(FIncludePath);'#010+ - ' 3 : Result:=EnsureConditionalStrings(FSour','cePath);'#010+ + ' 3 : Result:=EnsureConditionalStrings(FSourcePath);'#010+ ' 4 : Result:=EnsureConditionalStrings(FExamplePath);'#010+ - ' 5 : Result:=EnsureConditionalStrings(FTestPath);'#010+ + ' 5 : Result:=EnsureConditionalStrings(FT','estPath);'#010+ ' 6 : Result:=EnsureConditionalStrings(FInstallFiles);'#010+ ' 7 : Result:=EnsureConditionalStrings(FCleanFiles);'#010+ - ' 8 : Re','sult:=EnsureConditionalStrings(FArchiveFiles);'#010+ + ' 8 : Result:=EnsureConditionalStrings(FArchiveFiles);'#010+ ' end;'#010+ 'end;'#010+ #010+ - 'function TPackage.GetDependencies: TDependencies;'#010+ + 'function TPackage.GetDependencies: TDependencies',';'#010+ 'begin'#010+ ' If FDependencies=Nil then'#010+ ' FDependencies:=TDependencies.Create(TDependency);'#010+ ' Result:=FDependencies;'#010+ 'end;'#010+ #010+ - 'procedure T','Package.SetCommands(const AValue: TCommands);'#010+ + 'procedure TPackage.SetCommands(const AValue: TCommands);'#010+ 'begin'#010+ ' Commands.Assign(AValue);'#010+ 'end;'#010+ #010+ - 'procedure TPackage.SetConditionalStrings(AIndex: integer; const AValue'+ - ': TConditionalStrings);'#010+ + 'procedure TPackage.SetC','onditionalStrings(AIndex: integer; const AVal'+ + 'ue: TConditionalStrings);'#010+ 'begin'#010+ ' GetConditionalStrings(AIndex).Assign(AValue);'#010+ 'end;'#010+ #010+ - 'p','rocedure TPackage.SetDependencies(const AValue: TDependencies);'#010+ + 'procedure TPackage.SetDependencies(const AValue: TDependencies);'#010+ 'begin'#010+ ' GetDependencies.Assign(AValue);'#010+ - 'end;'#010+ + 'end;',#010+ #010+ 'constructor TPackage.Create(ACollection: TCollection);'#010+ #010+ 'begin'#010+ ' inherited Create(ACollection);'#010+ - ' FTargets:=TTargets.Create(TTarget',');'#010+ + ' FTargets:=TTargets.Create(TTarget);'#010+ ' FSources:=TSources.Create(TSource);'#010+ ' FDependencies:=TDependencies.Create(TDependency);'#010+ - ' FInstallFiles:=TConditionalStrings.Create(TConditionalString);'#010+ + ' FInstallFiles',':=TConditionalStrings.Create(TConditionalString);'#010+ ' FCleanFiles:=TConditionalStrings.Create(TConditionalString);'#010+ - ' FArchiveFiles:=TC','onditionalStrings.Create(TConditionalString);'#010+ + ' FArchiveFiles:=TConditionalStrings.Create(TConditionalString);'#010+ ' FCPUs:=AllCPUs;'#010+ ' FOSes:=AllOSes;'#010+ 'end;'#010+ #010+ - 'destructor TPackage.destroy;'#010+ + 'destructor TPackage.','destroy;'#010+ 'begin'#010+ ' FreeAndNil(FDependencies);'#010+ ' FreeAndNil(FInstallFiles);'#010+ ' FreeAndNil(FCleanFiles);'#010+ ' FreeAndNil(FArchiveFiles);'#010+ - ' F','reeAndNil(FIncludePath);'#010+ + ' FreeAndNil(FIncludePath);'#010+ ' FreeAndNil(FSourcePath);'#010+ ' FreeAndNil(FExamplePath);'#010+ ' FreeAndNil(FTestPath);'#010+ - ' FreeAndNil(FObjectPath);'#010+ + ' F','reeAndNil(FObjectPath);'#010+ ' FreeAndNil(FUnitPath);'#010+ ' FreeAndNil(FSources);'#010+ ' FreeAndNil(FTargets);'#010+ ' inherited destroy;'#010+ 'end;'#010+ #010+ - 'function',' TPackage.AddTarget(AName: String): TTarget;'#010+ + 'function TPackage.AddTarget(AName: String): TTarget;'#010+ 'begin'#010+ ' Result:=Targets.Add as TTarget;'#010+ ' Result.Name:=AName;'#010+ - 'end;'#010+ + 'e','nd;'#010+ #010+ 'procedure TPackage.AddDependency(AName: String);'#010+ 'begin'#010+ ' FDependencies.Add(AName);'#010+ 'end;'#010+ #010+ - 'procedure TPackage.AddInstallFile(AFil','eName: String);'#010+ + 'procedure TPackage.AddInstallFile(AFileName: String);'#010+ 'begin'#010+ ' FInstallFiles.add(AFileName);'#010+ 'end;'#010+ #010+ #010+ - 'procedure TPackage.GetCleanFiles(List: TStrings; Const APrefixU, APref'+ - 'ixB : String; ACPU:TCPU; AOS : TOS);'#010+ + 'procedure TPackage.GetCleanFiles(List: TStrings','; Const APrefixU, APr'+ + 'efixB : String; ACPU:TCPU; AOS : TOS);'#010+ 'Var'#010+ ' I : Integer;'#010+ 'begin'#010+ - ' AddConditionalStrings(List,CleanFiles,ACPU,AO','S,APrefixU);'#010+ + ' AddConditionalStrings(List,CleanFiles,ACPU,AOS,APrefixU);'#010+ ' For I:=0 to FTargets.Count-1 do'#010+ - ' FTargets.TargetItems[I].GetCleanFiles(List, APrefixU, APrefixB, AC'+ - 'PU, AOS);'#010+ + ' FTargets.TargetItems[I].GetCleanFiles(List, APrefixU, APr','efixB, '+ + 'ACPU, AOS);'#010+ 'end;'#010+ #010+ #010+ 'procedure TPackage.GetInstallFiles(List: TStrings;Types : TTargetTypes'+ - ';Const APrefix, APrefixU, APrefixB: ','String; ACPU:TCPU; AOS : TOS);'#010+ + ';Const APrefix, APrefixU, APrefixB: String; ACPU:TCPU; AOS : TOS);'#010+ 'Var'#010+ ' I : Integer;'#010+ ' T : TTarget;'#010+ 'begin'#010+ - ' AddConditionalStrings(List,InstallFiles,ACPU,AOS,APrefix);'#010+ + ' AddConditionalStrings(List,InstallF','iles,ACPU,AOS,APrefix);'#010+ ' For I:=0 to FTargets.Count-1 do'#010+ ' begin'#010+ ' T:=FTargets.TargetItems[I];'#010+ - ' if (T.TargetType in Type','s) then'#010+ + ' if (T.TargetType in Types) then'#010+ ' T.GetInstallFiles(List, APrefixU, APrefixB, ACPU, AOS);'#010+ ' end;'#010+ 'end;'#010+ #010+ #010+ - 'procedure TPackage.GetArchiveFiles(List: TStrings; ACPU:TCPU; AOS : TO'+ - 'S);'#010+ + 'procedure TPackage.','GetArchiveFiles(List: TStrings; ACPU:TCPU; AOS : '+ + 'TOS);'#010+ 'Var'#010+ ' I : Integer;'#010+ 'begin'#010+ ' // Targets only'#010+ - ' For I:=0 to FTargets.Count-1 do'#010, + ' For I:=0 to FTargets.Count-1 do'#010+ ' FTargets.TargetItems[I].GetArchiveFiles(List,ACPU,AOS);'#010+ ' // Additional archive files'#010+ - ' AddConditionalStrings(List,ArchiveFiles,ACPU,AOS);'#010+ + ' AddConditionalSt','rings(List,ArchiveFiles,ACPU,AOS);'#010+ 'end;'#010+ #010+ #010+ @@ -2145,19 +2151,19 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' FN : String;'#010+ ' L : TStringList;'#010+ 'begin'#010+ - ' I','f (FDescription<>'#039#039') then'#010+ + ' If (FDescription<>'#039#039') then'#010+ ' Result:=FDescription'#010+ ' else'#010+ ' If (FDescriptionFile<>'#039#039') then'#010+ ' begin'#010+ - ' // Always relative to binary name.'#010+ + ' ',' // Always relative to binary name.'#010+ ' FN:=ExtractFilePath(ParamStr(0));'#010+ ' FN:=FN+FDescriptionFile;'#010+ - ' If FileEx','ists(FN) then'#010+ + ' If FileExists(FN) then'#010+ ' begin'#010+ ' L:=TStringList.Create;'#010+ ' Try'#010+ - ' L.LoadFromFile(FN);'#010+ + ' L.LoadFromFil','e(FN);'#010+ ' Result:=L.Text;'#010+ ' Finally'#010+ ' L.Free;'#010+ @@ -2167,58 +2173,58 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'Fun','ction TPackage.GetFileName : string;'#010+ + 'Function TPackage.GetFileName : string;'#010+ 'begin'#010+ ' If (FFileName<>'#039#039') then'#010+ ' Result:=FFileName'#010+ ' else'#010+ - ' if Version <> '#039#039' then'#010+ + ' if Ver','sion <> '#039#039' then'#010+ ' Result := Name + '#039'-'#039' + Version'#010+ ' else'#010+ ' Result := Name;'#010+ 'end;'#010+ #010+ #010+ - 'procedure TPackage.AddDocFiles(const AFil','eMask: string; Recursive: b'+ - 'oolean);'#010+ + 'procedure TPackage.AddDocFiles(const AFileMask: string; Recursive: boo'+ + 'lean);'#010+ 'var'#010+ ' List : TStrings;'#010+ ' i: integer;'#010+ 'begin'#010+ - ' List := TStringList.Create;'#010+ + ' List := TStringList.Create;',#010+ ' SearchFiles(AFileMask, Recursive, List);'#010+ #010+ ' for i:= 0 to Pred(List.Count) do'#010+ ' Sources.AddDocFiles(List[i]);'#010+ #010+ ' List.Free;'#010+ - 'end;',#010+ + 'end;'#010+ #010+ #010+ 'procedure TPackage.AddSrcFiles(const AFileMask: string; Recursive: boo'+ 'lean);'#010+ 'var'#010+ ' List : TStrings;'#010+ - ' i: integer;'#010+ + ' i: ','integer;'#010+ 'begin'#010+ ' List := TStringList.Create;'#010+ ' SearchFiles(AFileMask, Recursive, List);'#010+ #010+ ' for i:= 0 to Pred(List.Count) do'#010+ - ' Sour','ces.AddSrcFiles(List[i]);'#010+ + ' Sources.AddSrcFiles(List[i]);'#010+ #010+ ' List.Free;'#010+ 'end;'#010+ #010+ #010+ - 'procedure TPackage.AddExampleFiles(const AFileMask: string; Recursive:'+ - ' boolean);'#010+ + 'procedure TPackage.AddExampleFiles(const AFileMask: string; R','ecursiv'+ + 'e: boolean);'#010+ 'var'#010+ ' List : TStrings;'#010+ ' i: integer;'#010+ 'begin'#010+ ' List := TStringList.Create;'#010+ - ' SearchFiles(AFileMask, Recursive, Lis','t);'#010+ + ' SearchFiles(AFileMask, Recursive, List);'#010+ #010+ ' for i:= 0 to Pred(List.Count) do'#010+ ' Sources.AddExampleFiles(List[i]);'#010+ @@ -2227,17 +2233,17 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'procedure TPackage.AddTestFiles(const AFileMask: string; Recursive: bo'+ - 'olean);'#010+ + 'procedure',' TPackage.AddTestFiles(const AFileMask: string; Recursive: '+ + 'boolean);'#010+ 'var'#010+ ' List : TStrings;'#010+ ' i: integer;'#010+ 'begin'#010+ - ' List := TStringLis','t.Create;'#010+ + ' List := TStringList.Create;'#010+ ' SearchFiles(AFileMask, Recursive, List);'#010+ #010+ ' for i:= 0 to Pred(List.Count) do'#010+ - ' Sources.AddTestFiles(List[i]);'#010+ + ' Sources.AddTest','Files(List[i]);'#010+ #010+ ' List.Free;'#010+ 'end;'#010+ @@ -2245,43 +2251,43 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ '{*********************************************************************'+ '*******'#010+ - ' ',' TPackages'#010+ + ' TPackages'#010+ '**********************************************************************'+ '******}'#010+ #010+ - 'function TPackages.GetPackage(const AName : String): TPackage;'#010+ + 'functi','on TPackages.GetPackage(const AName : String): TPackage;'#010+ 'begin'#010+ ' Result:=TPackage(ItemByName(AName))'#010+ 'end;'#010+ #010+ - 'function TPackages.GetPac','kageItem(AIndex : Integer): TPackage;'#010+ + 'function TPackages.GetPackageItem(AIndex : Integer): TPackage;'#010+ 'begin'#010+ ' Result:=TPackage(Items[AIndex]);'#010+ 'end;'#010+ #010+ #010+ - 'procedure TPackages.SetPackageItem(AIndex : Integer; const AValue: TPa'+ - 'ckage);'#010+ + 'procedure TPackages.Se','tPackageItem(AIndex : Integer; const AValue: T'+ + 'Package);'#010+ 'begin'#010+ ' Items[AIndex]:=AValue;'#010+ 'end;'#010+ #010+ #010+ - 'function TPackages.AddPackage(const AN','ame: String): TPackage;'#010+ + 'function TPackages.AddPackage(const AName: String): TPackage;'#010+ 'begin'#010+ ' Result:=Add as TPackage;'#010+ ' Result.Name:=AName;'#010+ 'end;'#010+ #010+ #010+ - '{*********************************************************************'+ - '*******'#010+ + '{*********************','**********************************************'+ + '*********'#010+ ' TCustomDefaults'#010+ - '*******************************','*************************************'+ - '********}'#010+ + '**********************************************************************'+ + '******}'#010+ #010+ 'procedure TCustomDefaults.SetCPU(const AValue: TCPU);'#010+ - 'begin'#010+ + 'begin'#010, ' FCPU:=AValue;'#010+ ' RecalcTarget;'#010+ 'end;'#010+ @@ -2290,10 +2296,10 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'function TCustomDefaults.GetBaseInstallDir: String;'#010+ 'begin'#010+ ' If (FBaseInstallDir<>'#039#039') then'#010+ - ' ',' Result:=FBaseInstallDir'#010+ + ' Result:=FBaseInstallDir'#010+ ' else'#010+ ' if UnixPaths then'#010+ - ' Result:=Prefix +'#039'lib'#039' + PathDelim + '#039'fpc'#039' + Path'+ + ' Result:=Prefix +'#039'lib'#039' + PathDelim + '#039'fpc'#039' + Path', 'Delim'#010+ ' else'#010+ ' Result:=Prefix;'#010+ @@ -2302,20 +2308,20 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'function TCustomDefaults.GetBinInstallDir: String;'#010+ 'begin'#010+ - ' If (FBinInstallDir<>'#039#039') then'#010, + ' If (FBinInstallDir<>'#039#039') then'#010+ ' Result:=FBinInstallDir'#010+ ' else'#010+ ' If UnixPaths then'#010+ ' Result:=BaseInstallDir+'#039'bin'#039#010+ ' else'#010+ - ' Result:=BaseInstallDir+'#039'bin'#039';'#010+ + ' Re','sult:=BaseInstallDir+'#039'bin'#039';'#010+ 'end;'#010+ #010+ #010+ 'function TCustomDefaults.GetCompiler: String;'#010+ 'begin'#010+ ' If (FCompiler<>'#039#039') then'#010+ - ' Result:=FCompil','er'#010+ + ' Result:=FCompiler'#010+ ' else'#010+ ' Result:='#039'fpc'#039';'#010+ 'end;'#010+ @@ -2323,39 +2329,39 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'function TCustomDefaults.GetDocInstallDir: String;'#010+ 'begin'#010+ - ' If (FBinInstallDir<>'#039#039') then'#010+ + ' If (FBinInsta','llDir<>'#039#039') then'#010+ ' Result:=FBinInstallDir'#010+ ' else'#010+ ' If UnixPaths then'#010+ ' Result:=Prefix+'#039'share'#039'+PathDelim+'#039'docs'#039#010+ ' else'#010+ - ' ',' Result:=BaseInstallDir+'#039'docs'#039';'#010+ + ' Result:=BaseInstallDir+'#039'docs'#039';'#010+ 'end;'#010+ #010+ #010+ 'function TCustomDefaults.GetExamplesInstallDir: String;'#010+ 'begin'#010+ - ' If (FExamplesInstallDir<>'#039#039') then'#010+ + ' If (F','ExamplesInstallDir<>'#039#039') then'#010+ ' Result:=FExamplesInstallDir'#010+ ' else'#010+ ' If UnixPaths then'#010+ - ' Result:=Prefix+'#039'share'#039'+PathDelim+'#039'do','cs'#039'+PathDe'+ - 'lim+'#039'examples'#039#010+ + ' Result:=Prefix+'#039'share'#039'+PathDelim+'#039'docs'#039'+PathDeli'+ + 'm+'#039'examples'#039#010+ ' else'#010+ ' Result:=BaseInstallDir+'#039'examples'#039';'#010+ 'end;'#010+ #010+ #010+ - 'function TCustomDefaults.GetUnitInstallDir: String;'#010+ + 'function TCustomDefaults.G','etUnitInstallDir: String;'#010+ 'begin'#010+ ' If (FUnitInstallDir<>'#039#039') then'#010+ ' Result:=FUnitInstallDir'#010+ ' else'#010+ ' If UnixPaths then'#010+ - ' Resul','t:=BaseInstallDir+'#039'units'#039'+PathDelim+Target'#010+ + ' Result:=BaseInstallDir+'#039'units'#039'+PathDelim+Target'#010+ ' else'#010+ ' Result:=BaseInstallDir+'#039'units'#039'+PathDelim+Target;'#010+ - 'end;'#010+ + 'e','nd;'#010+ #010+ #010+ 'function TCustomDefaults.GetLocalUnitDir: String;'#010+ @@ -2364,41 +2370,41 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'function TCustomDefaults.GetGlobalUnit','Dir: String;'#010+ + 'function TCustomDefaults.GetGlobalUnitDir: String;'#010+ 'begin'#010+ ' If (FGlobalUnitDir<>'#039#039') then'#010+ ' Result:=FGlobalUnitDir'#010+ ' else'#010+ - ' Result:=UnitInstallDir;'#010+ + ' Result:=UnitInstallD','ir;'#010+ 'end;'#010+ #010+ 'procedure TCustomDefaults.SetLocalUnitDir(const AValue: String);'#010+ 'begin'#010+ ' // Use ExpandFileName to support ~/ expansion'#010+ - ' F','LocalUnitDir:=IncludeTrailingPathDelimiter(ExpandFileName(AValue)'+ - ');'#010+ + ' FLocalUnitDir:=IncludeTrailingPathDelimiter(ExpandFileName(AValue));'+ + #010+ 'end;'#010+ #010+ - 'procedure TCustomDefaults.SetGlobalUnitDir(const AValue: String);'#010+ + 'procedure TCustomDefaults.SetGloba','lUnitDir(const AValue: String);'#010+ 'begin'#010+ ' // Use ExpandFileName to support ~/ expansion'#010+ - ' FGlobalUnitDir:=IncludeTrailingPathDelimiter','(ExpandFileName(AValue'+ - '));'#010+ + ' FGlobalUnitDir:=IncludeTrailingPathDelimiter(ExpandFileName(AValue))'+ + ';'#010+ 'end;'#010+ #010+ #010+ 'procedure TCustomDefaults.SetBaseInstallDir(const AValue: String);'#010+ 'begin'#010+ - ' // Use ExpandFileName to support ~/ expansion'#010+ + ' ','// Use ExpandFileName to support ~/ expansion'#010+ ' FBaseInstallDir:=IncludeTrailingPathDelimiter(ExpandFileName(AValue)'+ ');'#010+ - ' UnitInstall','Dir:='#039#039';'#010+ + ' UnitInstallDir:='#039#039';'#010+ ' BinInstallDir:='#039#039';'#010+ ' ExamplesInstallDir:='#039#039';'#010+ 'end;'#010+ #010+ #010+ - 'procedure TCustomDefaults.SetOS(const AValue: TOS);'#010+ + 'procedure TCustomDefaults.SetOS(const AValue:',' TOS);'#010+ 'begin'#010+ ' FOS:=AValue;'#010+ ' Recalctarget;'#010+ @@ -2407,34 +2413,34 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'procedure TCustomDefaults.SetPrefix(const AValue: String);'#010+ 'begin'#010+ - ' if FPrefix=AVa','lue then exit;'#010+ + ' if FPrefix=AValue then exit;'#010+ ' FPrefix:=IncludeTrailingPathDelimiter(AValue);'#010+ ' BaseInstallDir:='#039#039';'#010+ 'end;'#010+ #010+ #010+ - 'procedure TCustomDefaults.SetTarget(const AValue: String);'#010+ + 'procedure TCust','omDefaults.SetTarget(const AValue: String);'#010+ 'Var'#010+ ' P : Integer;'#010+ 'begin'#010+ ' if FTarget<>AValue then'#010+ ' begin'#010+ ' P:=Pos('#039'-'#039',AValue);'#010+ - ' ',' If (P<>0) then'#010+ + ' If (P<>0) then'#010+ ' begin'#010+ ' FOS:=StringToOS(System.Copy(Avalue,P+1,Length(AValue)-P));'#010+ - ' FCPU:=StringToCPU(System.Copy(Avalue,1,P-1));'#010+ + ' ',' FCPU:=StringToCPU(System.Copy(Avalue,1,P-1));'#010+ ' end'#010+ ' else'#010+ ' FOS:=StringToOS(AValue);'#010+ ' FTarget:=AValue;'#010+ - ' ',' end;'#010+ + ' end;'#010+ 'end;'#010+ #010+ #010+ 'procedure TCustomDefaults.RecalcTarget;'#010+ 'begin'#010+ - ' Ftarget:=CPUToString(FCPU)+'#039'-'#039'+OStoString(FOS);'#010+ + ' Ftarget:=CPUToString(FCPU)+'#039'-'#039'+OStoString(FOS)',';'#010+ 'end;'#010+ #010+ #010+ @@ -2446,13 +2452,14 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'procedure TCustomDefaults.InitDefaults;'#010+ 'begin'#010+ - ' {$ifdef un','ix}'#010+ + ' {$ifdef unix}'#010+ ' UnixPaths:=True;'#010+ ' {$else}'#010+ ' UnixPaths:=False;'#010+ ' {$endif}'#010+ ' FSourceExt:=PPExt;'#010+ - 'end;'#010+ + ' FNoFPCCfg:=False;'#010+ + 'end',';'#010+ #010+ #010+ 'procedure TCustomDefaults.Assign(ASource: TPersistent);'#010+ @@ -2461,26 +2468,26 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' If ASource is TCustomDefaults then'#010+ ' begin'#010+ - ' D:=ASour','ce as TCustomDefaults;'#010+ + ' D:=ASource as TCustomDefaults;'#010+ ' FArchive:=D.Farchive;'#010+ ' FCompiler:=D.Compiler;'#010+ - ' FCopy:=D.FCopy;'#010+ + ' FCopy:=D','.FCopy;'#010+ ' FCPU:=D.FCPU;'#010+ ' FMode:=D.FMode;'#010+ ' FMkDir:=D.FMkDir;'#010+ ' FMove:=D.FMove;'#010+ ' FOptions:=D.FOptions;'#010+ ' FOS:=D.FOS;'#010+ - ' FLocalUnitDir:=D.F','LocalUnitDir;'#010+ + ' FLocalUnitDir:=D.FLocalUnitDir;'#010+ ' FGlobalUnitDir:=D.FGlobalUnitDir;'#010+ ' FPrefix:=D.FPrefix;'#010+ - ' FBaseInstallDir:=D.FBaseInstallDir;'#010+ + ' FBaseIns','tallDir:=D.FBaseInstallDir;'#010+ ' FUnitInstallDir:=D.FUnitInstallDir;'#010+ ' FBinInstallDir:=D.FBinInstallDir;'#010+ ' FDocInstallDir:=D.FDocInstallDir;'#010+ - ' FExa','mplesInstallDir:=D.FExamplesInstallDir;'#010+ + ' FExamplesInstallDir:=D.FExamplesInstallDir;'#010+ ' FRemove:=D.FRemove;'#010+ - ' FTarget:=D.FTarget;'#010+ + ' FTarget:=D.FTarget;'#010, ' FUnixPaths:=D.FUnixPaths;'#010+ ' FSourceExt:=D.SourceExt;'#010+ ' end'#010+ @@ -2488,7 +2495,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Inherited;'#010+ 'end;'#010+ #010+ - 'procedure TCustomDefaults.LocalInit(Const AFileName : Str','ing);'#010+ + 'procedure TCustomDefaults.LocalInit(Const AFileName : String);'#010+ #010+ 'Var'#010+ ' FN : String;'#010+ @@ -2497,27 +2504,27 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' FN:=AFileName;'#010+ ' If (FN='#039#039') then'#010+ ' begin'#010+ - ' // Environment variable.'#010+ + ' // Env','ironment variable.'#010+ ' FN:=GetEnvironmentVariable('#039'FPMAKECFG'#039');'#010+ ' If (FN<>'#039#039') then'#010+ ' If not FileExists(FN) then'#010+ ' FN:='#039#039';'#010+ - ' // User config',' file fpmake.cfg'#010+ + ' // User config file fpmake.cfg'#010+ ' If (FN='#039#039') then'#010+ ' begin'#010+ ' FN:=GetAppConfigFile(False);'#010+ - ' If Not FileExists(FN) then'#010+ + ' ',' If Not FileExists(FN) then'#010+ ' FN:='#039#039';'#010+ ' end;'#010+ ' // Global config file fpmake.cfg'#010+ ' If (FN='#039#039') then'#010+ ' begin'#010+ - ' FN:=GetAppConfigFile(','True);'#010+ + ' FN:=GetAppConfigFile(True);'#010+ ' If Not FileExists(FN) then'#010+ ' FN:='#039#039';'#010+ ' end;'#010+ ' end;'#010+ - ' If (FN<>'#039#039') and FileExists(FN) then'#010+ + ' If (FN<>'#039#039,') and FileExists(FN) then'#010+ ' LoadFromFile(FN);'#010+ 'end;'#010+ #010+ @@ -2525,38 +2532,38 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'procedure TCustomDefaults.CompilerDefaults;'#010+ '{$ifdef HAS_UNIT_PROCESS}'#010+ 'var'#010+ - ' infoSL : TStringList;',#010+ + ' infoSL : TStringList;'#010+ '{$endif HAS_UNIT_PROCESS}'#010+ 'begin'#010+ '{$ifdef HAS_UNIT_PROCESS}'#010+ - ' // Detect compiler version/target from -i option'#010+ + ' // Detect compiler version/','target from -i option'#010+ ' infosl:=TStringList.Create;'#010+ ' infosl.Delimiter:='#039' '#039';'#010+ ' infosl.DelimitedText:=GetCompilerInfo(GetCompiler,'#039'-iVTPTO'#039')'+ ';'#010+ - ' if infosl','.Count<>3 then'#010+ + ' if infosl.Count<>3 then'#010+ ' Raise EInstallerError.Create(SErrInvalidFPCInfo);'#010+ - ' FCompilerVersion:=infosl[0];'#010+ + ' FCompilerVersion:','=infosl[0];'#010+ ' CPU:=StringToCPU(infosl[1]);'#010+ ' OS:=StringToOS(infosl[2]);'#010+ '{$else HAS_UNIT_PROCESS}'#010+ ' if CPU=cpuNone then'#010+ - ' CPU:=StringToCPU({$I %FPCTARG','ETCPU%});'#010+ + ' CPU:=StringToCPU({$I %FPCTARGETCPU%});'#010+ ' if OS=osNone then'#010+ ' OS:=StringToOS({$I %FPCTARGETOS%});'#010+ - ' if FCompilerVersion='#039#039' then'#010+ + ' if FCompilerVers','ion='#039#039' then'#010+ ' FCompilerVersion:={$I %FPCVERSION%};'#010+ '{$endif HAS_UNIT_PROCESS}'#010+ 'end;'#010+ #010+ #010+ 'procedure TCustomDefaults.LoadFromFile(Const AFileName: String);'#010+ - 'V','ar'#010+ + 'Var'#010+ ' F : TFileStream;'#010+ 'begin'#010+ ' F:=TFileStream.Create(AFileName,fmOpenRead);'#010+ ' Try'#010+ - ' LoadFromStream(F);'#010+ + ' Loa','dFromStream(F);'#010+ ' Finally'#010+ ' F.Free;'#010+ ' end;'#010+ @@ -2567,12 +2574,12 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'Var'#010+ ' F : TFileStream;'#010+ 'begin'#010+ - ' F:=TFi','leStream.Create(AFileName,fmCreate);'#010+ + ' F:=TFileStream.Create(AFileName,fmCreate);'#010+ ' Try'#010+ ' SaveToStream(F);'#010+ ' Finally'#010+ ' F.Free;'#010+ - ' end;'#010+ + ' ','end;'#010+ 'end;'#010+ #010+ #010+ @@ -2584,26 +2591,28 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' try'#010+ ' With L do'#010+ ' begin'#010+ - ' ',' Values[KeyArchive]:=FArchive;'#010+ + ' Values[KeyArchive]:=FArchive;'#010+ ' Values[KeyCompiler]:=FCompiler;'#010+ - ' Values[KeyCopy]:=FCopy;'#010+ + ' Values[Ke','yCopy]:=FCopy;'#010+ ' Values[KeyMkDir]:=FMkDir;'#010+ ' Values[KeyMove]:=FMove;'#010+ ' Values[KeyOptions]:=FOptions;'#010+ - ' Values[KeyCPU]:=CPUToString(FCPU)',';'#010+ + ' Values[KeyCPU]:=CPUToString(FCPU);'#010+ ' Values[KeyOS]:=OSToString(FOS);'#010+ ' Values[KeyMode]:=ModeToString(FMode);'#010+ - ' Values[KeyLocalUnitDir]:=FLocalUnitDir;'#010+ + ' ',' Values[KeyLocalUnitDir]:=FLocalUnitDir;'#010+ ' Values[KeyGlobalUnitDir]:=FGlobalUnitDir;'#010+ ' Values[KeyPrefix]:=FPrefix;'#010+ - ' Values[KeyBaseInstallD','ir]:=FBaseInstallDir;'#010+ + ' Values[KeyBaseInstallDir]:=FBaseInstallDir;'#010+ ' Values[KeyUnitInstallDir]:=FUnitInstallDir;'#010+ - ' Values[KeyBinInstallDir]:=FBinInstallDir;'#010+ + ' Values[Key','BinInstallDir]:=FBinInstallDir;'#010+ ' Values[KeyDocInstallDir]:=FDocInstallDir;'#010+ ' Values[KeyExamplesInstallDir]:=FExamplesInstallDir;'#010+ - ' Values[K','eyRemove]:=FRemove;'#010+ + ' Values[KeyRemove]:=FRemove;'#010+ ' Values[KeyTarget]:=FTarget;'#010+ - ' Values[KeySourceExt]:=FSourceExt;'#010+ + ' Values[KeySourceExt]:=FSourc','eExt;'#010+ + ' if FNoFPCCfg then'#010+ + ' Values[KeyNoFPCCfg]:='#039'Y'#039';'#010+ ' end;'#010+ ' L.SaveToStream(S);'#010+ ' Finally'#010+ @@ -2615,8 +2624,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'procedure TCustomDefaults.LoadFromStream(S: TStream);'#010+ 'Var'#010+ ' L : TStrings;'#010+ - ' ','Line : String;'#010+ - ' I,P,PC : Integer;'#010+ + ' Line : String;'#010+ + ' I,P,PC : Inte','ger;'#010+ 'begin'#010+ ' L:=TStringList.Create;'#010+ ' Try'#010+ @@ -2626,8 +2635,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' begin'#010+ ' Line:=L[I];'#010+ ' P:=Pos('#039'='#039',Line);'#010+ - ' PC:=Pos('#039';'#039',Line); // Comment l','ine.'#010+ - ' If (P=0) or ((PC<>0) and (PC0',') and (PC'#039#039') then'#010+ - ' FCPU:=StringToCPU(Line);'#010+ + ' If (Line<>'#039#039') then'#010+ + ' FCPU',':=StringToCPU(Line);'#010+ ' Line:=Values[KeyOS];'#010+ ' If (Line<>'#039#039') then'#010+ ' FOS:=StringToOS(Line);'#010+ ' Line:=Values[KeyMode];'#010+ ' If (Line<>'#039#039') then'#010+ ' FMode:=StringToMode(Line);'#010+ - ' FTarget:=Va','lues[KeyTarget];'#010+ - ' FLocalUnitDir:=Values[KeyLocalUnitDir];'#010+ + ' FTarget:=Values[KeyTarget];'#010+ + ' FLocalU','nitDir:=Values[KeyLocalUnitDir];'#010+ ' FGlobalUnitDir:=Values[KeyGlobalUnitDir];'#010+ ' FPrefix:=Values[KeyPrefix];'#010+ ' FBaseInstallDir:=Values[KeyBaseInstallDir];'#010+ - ' FUnitInstallDir:=Values[KeyUnitInstallD','ir];'#010+ - ' FBinInstallDir:=Values[KeyBinInstallDir];'#010+ + ' FUnitInstallDir:=Values[KeyUnitInstallDir];'#010+ + ' FBinInstallDir:=Val','ues[KeyBinInstallDir];'#010+ ' FDocInstallDir:=Values[KeyDocInstallDir];'#010+ ' FExamplesInstallDir:=Values[KeyExamplesInstallDir];'#010+ ' FSourceExt:=Values[KeySourceExt];'#010+ ' If (FSourceExt='#039#039') then'#010+ - ' FSo','urceExt:=PPExt;'#010+ + ' FSourceExt:=PPExt;'#010+ + ' FNoFPCCf','g:=(Upcase(Values[KeyNoFPCCfg])='#039'Y'#039');'#010+ ' end;'#010+ ' Finally'#010+ ' L.Free;'#010+ @@ -2673,7 +2683,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( '{*********************************************************************'+ '*******'#010+ ' TFPCDefaults'#010+ - '*********************************************************','***********'+ + '***********************************','*********************************'+ '********}'#010+ #010+ 'procedure TFPCDefaults.CompilerDefaults;'#010+ @@ -2684,14 +2694,14 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ ' if (FBaseInstallDir='#039#039') and (FPrefix='#039#039') then'#010+ ' begin'#010+ - ' // Use the same algorithm as the compiler, see options.pa','s'#010+ + ' // Use the same algorithm as the co','mpiler, see options.pas'#010+ '{$ifdef Unix}'#010+ ' BD:=FixPath(GetEnvironmentVariable('#039'FPCDIR'#039'));'#010+ ' if BD='#039#039' then'#010+ ' begin'#010+ ' BD:='#039'/usr/local/lib/fpc/'#039'+FCompilerVersion;'#010+ ' if not DirectoryExists(BD) and'#010+ - ' DirectoryExists('#039'/usr/lib/fpc','/'#039'+FCompilerVersio'+ + ' Directo','ryExists('#039'/usr/lib/fpc/'#039'+FCompilerVersio'+ 'n) then'#010+ ' BD:='#039'/usr/lib/fpc/'#039'+FCompilerVersion;'#010+ ' end;'#010+ @@ -2699,8 +2709,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' BD:=FixPath(GetEnvironmentVariable('#039'FPCDIR'#039'));'#010+ ' if BD='#039#039' then'#010+ ' begin'#010+ - ' BD:=ExtractFilePath(FCompiler)+'#039'..'#039';'#010+ - ' ',' if not(DirectoryExists(BD+'#039'/units'#039')) and'#010+ + ' BD:=ExtractFilePath','(FCompiler)+'#039'..'#039';'#010+ + ' if not(DirectoryExists(BD+'#039'/units'#039')) and'#010+ ' not(DirectoryExists(BD+'#039'/rtl'#039')) then'#010+ ' BD:=FBaseInstallDir+'#039'..'#039';'#010+ ' end;'#010+ @@ -2710,22 +2720,22 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - '{***********************************','********************************'+ + '{*************','******************************************************'+ '*********'#010+ ' TCustomInstaller'#010+ '**********************************************************************'+ '******}'#010+ #010+ - 'function TCustomInstaller.GetConditionalStrings(AIndex : Integer): TCo'+ - 'ndit','ionalStrings;'#010+ + 'function TCustomInstaller.GetConditionalStrings(AInd','ex : Integer): T'+ + 'ConditionalStrings;'#010+ 'begin'#010+ ' CheckDefaultPackage;'#010+ ' Case AIndex of'#010+ ' 0: Result:=DefaultPackage.Dependencies;'#010+ ' 1: Result:=DefaultPackage.InstallFiles;'#010+ ' 2: Result:=DefaultPackage.CleanFiles;'#010+ - ' 3: Result:=DefaultPackage.ArchiveFiles;'#010+ - ' ','end;'#010+ + ' 3: Result:=DefaultPa','ckage.ArchiveFiles;'#010+ + ' end;'#010+ 'end;'#010+ #010+ #010+ @@ -2739,8 +2749,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'Var'#010+ ' P : TPackage;'#010+ 'begin'#010+ - ' CheckDefaultPackage;'#010+ - ' P:=D','efaultPackage;'#010+ + ' Check','DefaultPackage;'#010+ + ' P:=DefaultPackage;'#010+ ' Case Index of'#010+ ' 0 : Result:=P.Author;'#010+ ' 1 : Result:=P.Directory;'#010+ @@ -2748,8 +2758,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' 3 : Result:=P.Options;'#010+ ' 4 : Result:=P.ExternalURL;'#010+ ' 5 : Result:=P.Email;'#010+ - ' 6 : Result:=P.Description;'#010+ - ' 7 : Resul','t:=P.DescriptionFile;'#010+ + ' 6 : Result:=P.Desc','ription;'#010+ + ' 7 : Result:=P.DescriptionFile;'#010+ ' 8 : Result:=P.Version;'#010+ ' 9 : Result:=P.FileName + ZipExt;'#010+ ' end;'#010+ @@ -2761,8 +2771,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'Var'#010+ ' P : TPackage;'#010+ 'begin'#010+ - ' CheckDefaultPackage;'#010+ - ' P:=D','efaultPackage;'#010+ + ' Check','DefaultPackage;'#010+ + ' P:=DefaultPackage;'#010+ ' Case Index of'#010+ ' 0 : P.Author:=AValue;'#010+ ' 1 : P.Directory:=AValue;'#010+ @@ -2770,8 +2780,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' 3 : P.Options:=AValue;'#010+ ' 4 : P.ExternalURL:=AValue;'#010+ ' 5 : P.Email:=AValue;'#010+ - ' 6 : P.Description:=AValue;'#010+ - ' 7 : P.Des','criptionFile:=AValue;'#010+ + ' 6 : P.Description:','=AValue;'#010+ + ' 7 : P.DescriptionFile:=AValue;'#010+ ' 8 : P.Version:=AValue;'#010+ ' 9 : P.FileName:=AValue;'#010+ ' end;'#010+ @@ -2785,7 +2795,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'function TCustomInstaller.GetTargets: TT','argets;'#010+ + 'function TCustomIn','staller.GetTargets: TTargets;'#010+ 'begin'#010+ ' CheckDefaultPackage;'#010+ ' Result:=DefaultPackage.Targets;'#010+ @@ -2797,7 +2807,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Result:=DefaultPackage.Sources;'#010+ 'end;'#010+ #010+ - 'procedure TCustomInstaller.SetBaseInstallDir(c','onst AValue: string);'#010+ + 'procedure TCustomInstall','er.SetBaseInstallDir(const AValue: string);'#010+ 'begin'#010+ ' if AValue <> Defaults.BaseInstallDir then'#010+ ' Defaults.BaseInstallDir := AValue;'#010+ @@ -2805,8 +2815,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'procedure TCustomInstaller.SetDefaultPackage(const AValue: TPackage);'#010+ 'begin'#010+ - ' if FDefaultPackage=AValue then exit;'#010+ - ' FDefau','ltPackage:=AValue;'#010+ + ' if FDefaultPackage=AVal','ue then exit;'#010+ + ' FDefaultPackage:=AValue;'#010+ 'end;'#010+ #010+ 'procedure TCustomInstaller.SetDefaults(const AValue: TCustomDefaults);'+ @@ -2816,8 +2826,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ 'procedure TCustomInstaller.SetConditionalStrings(AIndex : Integer; con'+ - 'st AValue: TConditionalStrings);'#010+ - #010, + 'st AValue: T','ConditionalStrings);'#010+ + #010+ 'Var'#010+ ' Res : TConditionalStrings;'#010+ #010+ @@ -2827,7 +2837,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' 0: Res:=DefaultPackage.Dependencies;'#010+ ' 1: Res:=DefaultPackage.InstallFiles;'#010+ ' 2: Res:=DefaultPackage.CleanFiles;'#010+ - ' 3: Res:=DefaultPackage.ArchiveF','iles;'#010+ + ' 3: Res:=D','efaultPackage.ArchiveFiles;'#010+ ' end;'#010+ ' Res.Assign(Avalue);'#010+ 'end;'#010+ @@ -2839,9 +2849,9 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'procedure TCustomInstaller.Log(Level: TVerboseLevel; const Msg: String'+ - ');'#010+ - 'be','gin'#010+ + 'procedure TCustomInstaller.Log(Level: TVerboseLevel; ','const Msg: Stri'+ + 'ng);'#010+ + 'begin'#010+ ' If Level in FLogLevels then'#010+ ' Writeln(StdErr,Msg);'#010+ 'end;'#010+ @@ -2855,7 +2865,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'procedure TCustomInstaller.CreateBuildEngine;'#010+ 'begin'#010+ - ' FBuildEngine:=TBuildEng','ine.Create(Self);'#010+ + ' F','BuildEngine:=TBuildEngine.Create(Self);'#010+ ' FBuildEngine.Defaults:=Defaults;'#010+ ' FBuildEngine.ListMode:=FListMode;'#010+ ' FBuildEngine.OnLog:=@Self.Log;'#010+ @@ -2865,7 +2875,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'procedure TCustomInstaller.CheckDefaultPackage;'#010+ 'begin'#010+ ' If (FDefaultPackage=Nil) then'#010+ - ' Raise EInstallerError','.Create(SErrNoPackage);'#010+ + ' ',' Raise EInstallerError.Create(SErrNoPackage);'#010+ 'end;'#010+ #010+ #010+ @@ -2878,7 +2888,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'procedure TCustomInstaller.Error(const Fmt: String; Args: array of con'+ 'st);'#010+ 'begin'#010+ - ' Raise EInstallerError.C','reateFmt(Fmt,Args);'#010+ + ' R','aise EInstallerError.CreateFmt(Fmt,Args);'#010+ 'end;'#010+ #010+ #010+ @@ -2889,9 +2899,9 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Result:=FDefaultPackage;'#010+ 'end;'#010+ #010+ - 'procedure TCustomInstaller.EndPackage;'#010+ + 'procedure TCustomInstaller.EndPa','ckage;'#010+ 'begin'#010+ - ' FDefaul','tPackage:=Nil;'#010+ + ' FDefaultPackage:=Nil;'#010+ 'end;'#010+ #010+ 'procedure TCustomInstaller.AnalyzeOptions;'#010+ @@ -2904,7 +2914,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ ' begin'#010+ ' O:=Paramstr(Index);'#010+ - ' Result:=(O='#039'-'#039'+short) or (O='#039'--'#039'+long) ','or (copy('+ + ' Result:=(O='#039'-'#039'+sh','ort) or (O='#039'--'#039'+long) or (copy('+ 'O,1,Length(Long)+3)=('#039'--'#039'+long+'#039'='#039'));'#010+ ' end;'#010+ #010+ @@ -2916,10 +2926,10 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ ' begin'#010+ ' O:=Paramstr(Index);'#010+ - ' Result:=(O='#039'-'#039'+short) or (O=long);'#010+ + ' Result:=(O='#039'-'#039'+short) or (','O=long);'#010+ ' end;'#010+ #010+ - ' Fun','ction OptionArg(Var Index : Integer) : String;'#010+ + ' Function OptionArg(Var Index : Integer) : String;'#010+ #010+ ' Var'#010+ ' P : Integer;'#010+ @@ -2930,8 +2940,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' begin'#010+ ' If Index2 then'#010+ ' begin'#010+ ' P:=Pos('#039'='#039',Paramstr(Index));'#010+ - ' If (P=0) then'#010+ - ' Error(SErrNe','edArgument,[Index,ParamStr(Index)])'#010+ + ' If (P=0) the','n'#010+ + ' Error(SErrNeedArgument,[Index,ParamStr(Index)])'#010+ ' else'#010+ ' begin'#010+ ' Result:=Paramstr(Index);'#010+ @@ -2951,13 +2961,11 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'Var'#010+ ' I : Integer;'#010+ - ' Nodefaults : Boolean;'#010+ ' DefaultsFileName : string;'#010+ #010+ 'begin'#010+ - ' I:=0;',#010+ - ' NoDefaults:=False;'#010+ - ' FListMode:=False;'#010+ + ' I:=0;'#010+ + ' ',' FListMode:=False;'#010+ ' FLogLevels := [vlError,vlWarning,vlInfo];'#010+ ' While (I'#039#039' then'#010+ ' Defaults.LocalInit(DefaultsFileName);'#010+ ' Defaults.CompilerDefaults;'#010+ '{$ifdef debug}'#010+ @@ -3023,7 +3030,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( '{$endif}'#010+ 'end;'#010+ #010+ - 'procedure TCustomInstaller.Usa','ge(const FMT: String; Args: array of c'+ + 'procedure TCustomInstaller.Usage(const FMT',': String; Args: array of c'+ 'onst);'#010+ #010+ ' Procedure LogCmd(const LC,Msg : String);'#010+ @@ -3033,7 +3040,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ ' Procedure LogOption(const C,LC,Msg : String);'#010+ ' begin'#010+ - ' Log(vlInfo,Format('#039' -%s --%-1','6s %s'#039',[C,LC,MSG]));'#010+ + ' Log(vlInfo,Format('#039' -%s --%-16s %s'#039',[C,LC',',MSG]));'#010+ ' end;'#010+ #010+ ' Procedure LogArgOption(const C,LC,Msg : String);'#010+ @@ -3045,29 +3052,29 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' If (FMT<>'#039#039') then'#010+ ' Log(vlInfo,Format(Fmt,Args));'#010+ - ' Log(vlInfo,Format','(SHelpUsage,[Paramstr(0)]));'#010+ + ' Log(vlInfo,Format(SHelpUsage,','[Paramstr(0)]));'#010+ ' Log(vlInfo,SHelpCommand);'#010+ ' LogCmd('#039'compile'#039',SHelpCompile);'#010+ ' LogCmd('#039'build'#039',SHelpBuild);'#010+ ' LogCmd('#039'install'#039',SHelpInstall);'#010+ ' LogCmd('#039'clean'#039',SHelpClean);'#010+ ' LogCmd('#039'archive'#039',SHelpArchive);'#010+ - ' LogCmd('#039'manifest'#039',S','HelpManifest);'#010+ + ' LogCmd('#039'manifest'#039',SHelpManifest',');'#010+ ' Log(vlInfo,SHelpCmdOptions);'#010+ ' LogOption('#039'h'#039','#039'help'#039',SHelpHelp);'#010+ ' LogOption('#039'l'#039','#039'list-commands'#039',SHelpList);'#010+ - ' LogOption('#039'n'#039','#039'nodefaults'#039',SHelpNoDefaults);'#010+ + ' LogOption('#039'n'#039','#039'nofpccfg'#039',SHelpNoFPCCfg);'#010+ ' LogOption('#039'v'#039','#039'verbose'#039',SHelpVerbose);'#010+ - ' LogArgOption('#039'C'#039','#039'CPU'#039',SH','elpCPU);'#010+ - ' LogArgOption('#039'O'#039','#039'OS'#039',SHelpOS);'#010+ + ' LogArgOption('#039'C'#039','#039'CPU'#039',SHelpCPU);'#010+ + ' LogAr','gOption('#039'O'#039','#039'OS'#039',SHelpOS);'#010+ ' LogArgOption('#039't'#039','#039'target'#039',SHelpTarget);'#010+ ' LogArgOption('#039'P'#039','#039'prefix'#039',SHelpPrefix);'#010+ ' LogArgOption('#039'B'#039','#039'baseinstalldir'#039',SHelpBaseInstalldi'+ 'r);'#010+ ' LogArgOption('#039'UL'#039','#039'localunitdir'#039',SHelpLocalUnitdir);'+ - #010, - ' LogArgOption('#039'UG'#039','#039'globalunitdir'#039',SHelpGlobalUnitdir'+ - ');'#010+ + #010+ + ' LogArgOption('#039,'UG'#039','#039'globalunitdir'#039',SHelpGlobalUnitdi'+ + 'r);'#010+ ' LogArgOption('#039'r'#039','#039'compiler'#039',SHelpCompiler);'#010+ ' LogArgOption('#039'f'#039','#039'config'#039',SHelpConfig);'#010+ ' Log(vlInfo,'#039#039');'#010+ @@ -3077,7 +3084,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' halt(0);'#010+ 'end;'#010+ #010+ - 'procedure TCustomIn','staller.Compile(Force: Boolean);'#010+ + 'procedure TCustomInstaller.Compile(','Force: Boolean);'#010+ 'begin'#010+ ' FBuildEngine.ForceCompile:=Force;'#010+ ' FBuildEngine.Compile(FPackages);'#010+ @@ -3090,7 +3097,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'procedure TCustomInstaller.Install;'#010+ 'begin'#010+ - ' Bu','ildEngine.Install(FPackages);'#010+ + ' BuildEngine.Instal','l(FPackages);'#010+ 'end;'#010+ #010+ 'procedure TCustomInstaller.Archive;'#010+ @@ -3101,10 +3108,10 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' FBuildEngine.Archive(FPackages);'#010+ 'end;'#010+ #010+ - 'procedure TCustomInstaller.Manifes','t;'#010+ + 'procedure TCustomInstaller.Manifest;'#010+ #010+ 'Var'#010+ - ' L : TStrings;'#010+ + ' L : TS','trings;'#010+ 'begin'#010+ ' L:=TStringList.Create;'#010+ ' Try'#010+ @@ -3112,9 +3119,9 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' L.Add('#039''#039');'#010+ ' BuildEngine.GetManifest(FPackages,L);'#010+ ' L.SaveToFile(ManifestFile);'#010+ - ' Finally',#010+ + ' Finally'#010+ ' L.Free;'#010+ - ' end;'#010+ + ' e','nd;'#010+ 'end;'#010+ #010+ #010+ @@ -3129,7 +3136,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' If (FPackages.Count=0) then'#010+ ' Error(SErrNoPackagesDefined);'#010+ - ' // ','Check for other obvious errors ?'#010+ + ' // Check for other ','obvious errors ?'#010+ 'end;'#010+ #010+ #010+ @@ -3142,7 +3149,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Case RunMode of'#010+ ' rmCompile : Compile(False);'#010+ ' rmBuild : Compile(True);'#010+ - ' ',' rmInstall : Install;'#010+ + ' rmInstall : ','Install;'#010+ ' rmArchive : Archive;'#010+ ' rmClean : Clean;'#010+ ' rmManifest : Manifest;'#010+ @@ -3152,8 +3159,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' begin'#010+ ' Log(vlError,SErrInstaller);'#010+ ' Log(vlError,E.Message);'#010+ - ' Result:=F','alse;'#010+ - ' end;'#010+ + ' Result:=False;'#010+ + ' end;',#010+ ' end;'#010+ ' // Force returning an exitcode to the shell'#010+ ' if not Result then'#010+ @@ -3163,8 +3170,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'function TCustomInstaller.AddTarget(const AName: String): TTarget;'#010+ 'begin'#010+ ' CheckDefaultPackage;'#010+ - ' Result:=DefaultPackage.AddTa','rget(AName);'#010+ - 'end;'#010+ + ' Result:=DefaultPackage.AddTarget(AName);'#010+ + 'end',';'#010+ #010+ 'procedure TCustomInstaller.AddDependency(const AName: String);'#010+ 'begin'#010+ @@ -3176,7 +3183,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ '{*********************************************************************'+ '*******'#010+ - ' ',' TFPCInstaller'#010+ + ' ',' TFPCInstaller'#010+ '**********************************************************************'+ '******}'#010+ #010+ @@ -3184,8 +3191,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' FDefaults:=TFPCDefaults.Create;'#010+ ' AnalyzeOptions;'#010+ - ' Creat','ePackages;'#010+ - 'end;'#010+ + ' CreatePackages;'#010+ + 'end;'#010, #010+ #010+ '{*********************************************************************'+ @@ -3194,7 +3201,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( '**********************************************************************'+ '******}'#010+ #010+ - 'constructor TBas','icInstaller.Create(AOwner: TComponent);'#010+ + 'constructor TBasicInstaller.Crea','te(AOwner: TComponent);'#010+ 'begin'#010+ ' FDefaults:=TBasicDefaults.Create;'#010+ ' AnalyzeOptions;'#010+ @@ -3204,17 +3211,17 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ '{*********************************************************************'+ '*******'#010+ - ' TBui','ldEngine'#010+ - '**********************************************************************'+ - '******}'#010+ + ' TBuildEngine'#010+ + '*******','*************************************************************'+ + '********}'#010+ #010+ 'procedure TBuildEngine.SetDefaults(const AValue: TCustomDefaults);'#010+ 'begin'#010+ ' FDefaults.Assign(AValue);'#010+ 'end;'#010+ #010+ - 'procedure TBuildEngine.SetTargetDir(const AVa','lue: String);'#010+ - 'begin'#010+ + 'procedure TBuildEngine.SetTargetDir(const AValue: String);'#010+ + 'be','gin'#010+ ' if FTargetDir=AValue then exit;'#010+ ' FTargetDir:=AValue;'#010+ 'end;'#010+ @@ -3224,9 +3231,9 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Raise EInstallerError.Create(Msg);'#010+ 'end;'#010+ #010+ - 'procedure TBuildEngine.Error(const Fmt: String; Args: array ','of const'+ - ');'#010+ - 'begin'#010+ + 'procedure TBuildEngine.Error(const Fmt: String; Args: array of const);'+ + #010+ + 'begin',#010+ ' Raise EInstallerError.CreateFmt(Fmt,Args);'#010+ 'end;'#010+ #010+ @@ -3234,15 +3241,15 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' inherited Create(AOwner);'#010+ ' FDefaults:=TCustomDefaults.Create;'#010+ - ' // Maybe this should be the current directory ','?'#010+ - ' // Or have it as a command-line option.'#010+ + ' // Maybe this should be the current directory ?'#010+ + ' // Or have i','t as a command-line option.'#010+ ' // Would allow to put all '#039'installers'#039' in one dir and call t'+ 'hem'#010+ ' // With --start-dir=/path/to/sources.'#010+ ' FStartDir:=includeTrailingPathDelimiter(GetCurrentDir);'#010+ 'end;'#010+ #010+ - 'procedure TBuildEngine.Exe','cuteCommand(const Cmd,Args : String; Ignor'+ + 'procedure TBuildEngine.ExecuteCommand(cons','t Cmd,Args : String; Ignor'+ 'eError : Boolean = False);'#010+ #010+ 'Var'#010+ @@ -3252,8 +3259,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Log(vlCommand,SLogExecutingCommand,[Cmd,Args]);'#010+ ' // We should check cmd for spaces, and move all after first space to'+ ' args.'#010+ - ' E:=ExecuteProce','ss(cmd,args);'#010+ - ' If (E<>0) and (not IgnoreError) then'#010+ + ' E:=ExecuteProcess(cmd,args);'#010+ + ' ','If (E<>0) and (not IgnoreError) then'#010+ ' Error(SErrExternalCommandFailed,[Cmd,E]);'#010+ 'end;'#010+ #010+ @@ -3263,10 +3270,10 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' D,S : String;'#010+ ' Fin,FOut : TFileStream;'#010+ ' Count : Int64;'#010+ - ' A : Inte','ger;'#010+ + ' A : Integer;'#010+ #010+ 'begin'#010+ - ' Log(vlCommand,SLogCopyingFile,[Src,Dest]);'#010+ + ' Lo','g(vlCommand,SLogCopyingFile,[Src,Dest]);'#010+ ' FIn:=TFileStream.Create(Src,fmopenRead);'#010+ ' Try'#010+ ' D:=IncludeTrailingPathDelimiter(Dest);'#010+ @@ -3274,7 +3281,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' S:=D+ExtractFileName(Src)'#010+ ' else'#010+ ' S:=Dest;'#010+ - ' ','FOut:=TFileStream.Create(S,fmCreate);'#010+ + ' FOut:=TFileStrea','m.Create(S,fmCreate);'#010+ ' Try'#010+ ' Count:=Fout.CopyFrom(FIn,0);'#010+ ' If (Count<>Fin.Size) then'#010+ @@ -3283,8 +3290,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' FreeAndNil(Fout);'#010+ ' end;'#010+ ' A:=FileGetDate(FIn.Handle);'#010+ - ' If (A=','-1) then'#010+ - ' log(vlWarning,SWarnFailedToGetTime,[Src])'#010+ + ' If (A=-1) then'#010+ + ' l','og(vlWarning,SWarnFailedToGetTime,[Src])'#010+ ' else'#010+ ' if FileSetDate(S,A)<>0 then'#010+ ' Log(vlWarning,SWarnFailedToSetTime,[S]);'#010+ @@ -3293,9 +3300,9 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' end;'#010+ 'end;'#010+ #010+ - 'procedure TBuildEngine.SysMoveFile(Const Src,De','st : String);'#010+ + 'procedure TBuildEngine.SysMoveFile(Const Src,Dest : String);'#010+ #010+ - 'Var'#010+ + 'V','ar'#010+ ' S : String;'#010+ #010+ 'begin'#010+ @@ -3305,8 +3312,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' S:=Dest;'#010+ ' If Not RenameFile(Src,S) then'#010+ ' begin'#010+ - ' T','ry'#010+ - ' SysCopyFile(Src,S);'#010+ + ' Try'#010+ + ' SysCopy','File(Src,S);'#010+ ' SysDeleteFile(Src);'#010+ ' Except'#010+ ' On E : Exception Do'#010+ @@ -3318,7 +3325,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'procedure TBuildEngine.SysDeleteFile(Const AFileName : String);'#010+ #010+ 'begin'#010+ - ' if not FileE','xists(AFileName) then'#010+ + ' if not FileExists(AFileName)',' then'#010+ ' Log(vlWarning,SWarnFileDoesNotExist,[AFileName])'#010+ ' else If Not DeleteFile(AFileName) then'#010+ ' Error(SErrDeletingFile,[AFileName]);'#010+ @@ -3326,16 +3333,16 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ #010+ 'procedure TBuildEngine.SysArchiveFiles(List: TStrings;Const AFileName:'+ - ' Strin','g);'#010+ + ' String);'#010+ 'begin'#010+ - ' If Not (Assigned(OnArchivefiles) or Assigned(ArchiveFilesProc)) then'+ - #010+ + ' If N','ot (Assigned(OnArchivefiles) or Assigned(ArchiveFilesProc)) th'+ + 'en'#010+ ' Raise EInstallerError.Create(SErrNoArchiveSupport);'#010+ ' If Assigned(ArchiveFilesProc) then'#010+ ' ArchiveFilesProc(AFileName,List)'#010+ ' else'#010+ - ' OnArchiveFiles(AFi','leName,List);'#010+ - 'end;'#010+ + ' OnArchiveFiles(AFileName,List);'#010+ + 'en','d;'#010+ #010+ 'procedure TBuildEngine.Log(Level: TVerboseLevel; const Msg: String);'#010+ 'begin'#010+ @@ -3344,9 +3351,9 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ 'procedure TBuildEngine.Log(Level: TVerboseLevel; const Fmt: String;'#010+ - ' Args: array of cons','t);'#010+ + ' Args: array of const);'#010+ 'begin'#010+ - ' Log(Level,Format(Fmt,Args));'#010+ + ' Log(','Level,Format(Fmt,Args));'#010+ 'end;'#010+ #010+ 'procedure TBuildEngine.EnterDir(ADir: String);'#010+ @@ -3359,12 +3366,12 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' D:=D+ADir;'#010+ ' Log(vlInfo,SLogEnterDir,[D]);'#010+ ' If Not SetCurrentDir(D) then'#010+ - ' Error(SErrChangeDirFaile','d,[D]);'#010+ + ' Error(SErrChangeDirFailed,[D]);'#010+ 'end;'#010+ #010+ #010+ - 'procedure TBuildEngine.CmdCopyFiles(List: TStrings; Const DestDir: Str'+ - 'ing);'#010+ + 'p','rocedure TBuildEngine.CmdCopyFiles(List: TStrings; Const DestDir: S'+ + 'tring);'#010+ #010+ 'Var'#010+ ' Args : String;'#010+ @@ -3375,7 +3382,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' If (Defaults.Copy<>'#039#039') then'#010+ ' begin'#010+ ' Args:=FileListToString(List,'#039#039');'#010+ - ' ',' Args:=Args+'#039' '#039'+DestDir;'#010+ + ' Args:=Args+'#039' '#039'+','DestDir;'#010+ ' ExecuteCommand(Defaults.Copy,Args);'#010+ ' end'#010+ ' else'#010+ @@ -3386,8 +3393,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'procedure TBuildEngine.CmdCreateDir(const DestDir: String);'#010+ #010+ 'begin'#010+ - ' If (Defaults.MkDi','r<>'#039#039') then'#010+ - ' ExecuteCommand(Defaults.MkDir,DestDir)'#010+ + ' If (Defaults.MkDir<>'#039#039') then'#010+ + ' ','ExecuteCommand(Defaults.MkDir,DestDir)'#010+ ' else'#010+ ' If not ForceDirectories(DestDir) then'#010+ ' Error(SErrCreatingDirectory,[DestDir]);'#010+ @@ -3397,8 +3404,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'ing);'#010+ #010+ 'Var'#010+ - ' A','rgs : String;'#010+ - ' I : Integer;'#010+ + ' Args : String;'#010+ + ' ','I : Integer;'#010+ #010+ 'begin'#010+ ' CmdCreateDir(DestDir);'#010+ @@ -3409,8 +3416,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' ExecuteCommand(Defaults.Move,Args);'#010+ ' end'#010+ ' else'#010+ - ' For I:=0 to Lis','t.Count-1 do'#010+ - ' SysMoveFile(List[i],DestDir);'#010+ + ' For I:=0 to List.Count-1 do'#010+ + ' ',' SysMoveFile(List[i],DestDir);'#010+ 'end;'#010+ #010+ 'procedure TBuildEngine.CmdDeleteFiles(List: TStrings);'#010+ @@ -3423,7 +3430,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' If (Defaults.Remove<>'#039#039') then'#010+ ' begin'#010+ ' Args:=FileListToString(List,'#039#039');'#010+ - ' Exe','cuteCommand(Defaults.Remove,Args);'#010+ + ' ExecuteCommand(Defa','ults.Remove,Args);'#010+ ' end'#010+ ' else'#010+ ' For I:=0 to List.Count-1 do'#010+ @@ -3437,7 +3444,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' S,C,O : String;'#010+ #010+ 'begin'#010+ - ' If (Def','aults.Archive='#039#039') then'#010+ + ' If (Defaults.Archive='#039#039,') then'#010+ ' SysArchiveFiles(List,ArchiveFile)'#010+ ' else'#010+ ' begin'#010+ @@ -3446,7 +3453,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' If (O='#039#039') then'#010+ ' O:=ArchiveFile+'#039' '#039'+S'#010+ ' else'#010+ - ' O:=Substitute(O,['#039'ARCHIVE'#039',','ArchiveFile,'#039'FILESORDIR'+ + ' O:=Substitute(O,['#039'ARCHIVE'#039',ArchiveFile,'#039'FIL','ESORDIR'+ 'S'#039']);'#010+ ' ExecuteCommand(C,O);'#010+ ' end;'#010+ @@ -3461,14 +3468,14 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' DS:=FileAge(Src);'#010+ ' DD:=FileAge(Dest);'#010+ - ' D1:=File','DateToDateTime(DS);'#010+ + ' D1:=FileDateToDateTime(D','S);'#010+ ' D2:=FileDateToDateTime(DD);'#010+ ' Log(vlDebug,SLogCompilingFileTimes,[Src,DateTimeToStr(D1),Dest,DateT'+ 'imeToStr(D2)]);'#010+ ' Result:=D1>=D2;'#010+ ' If Result then'#010+ - ' Log(vlCompare,SLogSourceNewerDest,[Src,DateTimeToStr(D1),Dest,Dat', - 'eTimeToStr(D2)]);'#010+ + ' Log(vlCompare,SLogSourceNewerDest,[Src,DateTimeToStr(D1),Dest,Date'+ + 'TimeToStr(D2)])',';'#010+ 'end;'#010+ #010+ 'procedure TBuildEngine.ExecuteCommands(Commands: TCommands; At: TComma'+ @@ -3483,22 +3490,22 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' For I:=0 to Commands.Count-1 do'#010+ ' begin'#010+ - ' C:=Commands.Com','mandItems[i];'#010+ - ' if (C.At=At) then'#010+ + ' C:=Commands.CommandItems[i];'#010+ + ' ',' if (C.At=At) then'#010+ ' begin'#010+ ' E:=True;'#010+ ' If (C.SourceFile<>'#039#039') and (C.DestFile<>'#039#039') then'#010+ ' E:=FileNewer(C.SourceFile,IncludeTrailingPathDelimiter(Diction'+ 'ary.GetValue('#039'OUTPUTDIR'#039'))+C.DestFile);'#010+ - ' If E t','hen'#010+ - ' begin'#010+ + ' If E then'#010+ + ' begi','n'#010+ ' If Assigned(C.BeforeCommand) then'#010+ ' C.BeforeCommand(C);'#010+ ' O:=Substitute(C.Options,['#039'SOURCE'#039',C.SourceFile,'#039'DE'+ 'ST'#039',C.DestFile]);'#010+ ' Cmd:=C.Command;'#010+ ' If (ExtractFilePath(Cmd)='#039#039') then'#010+ - ' ',' Cmd:=FileSearch(Cmd,GetEnvironmentvariable('#039'PATH'#039')'+ + ' Cmd:=FileSearc','h(Cmd,GetEnvironmentvariable('#039'PATH'#039')'+ ');'#010+ ' ExecuteCommand(Cmd,O,C.IgnoreResult);'#010+ ' If Assigned(C.AfterCommand) then'#010+ @@ -3509,7 +3516,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ '// Relative to startdir.'#010+ - 'Funct','ion TBuildEngine.GetTargetDir(APackage : TPackage; ATarget : TT'+ + 'Function TBuildEngine','.GetTargetDir(APackage : TPackage; ATarget : TT'+ 'arget; AbsolutePath : Boolean = False) : String;'#010+ #010+ 'begin'#010+ @@ -3517,15 +3524,16 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Result:=IncludeTrailingPathDelimiter(FStartDir)'#010+ ' else'#010+ ' Result:='#039#039';'#010+ - ' If (APackage.Director','y<>'#039#039') then'#010+ - ' Result:=Result+IncludeTrailingPathDelimiter(APackage.Directory);'#010+ + ' If (APackage.Directory<>'#039#039') then'#010+ + ' ','Result:=Result+IncludeTrailingPathDelimiter(APackage.Directory);'+ + #010+ ' If (ATarget.Directory<>'#039#039') then'#010+ ' Result:=IncludeTrailingPathDelimiter(Result+ATarget.Directory);'#010+ #010+ 'end;'#010+ #010+ #010+ - 'Function TBuildEngine.FindFileInPath(Path:TCondit','ionalStrings; AFile'+ + 'Function TBuildEngine.FindFileInPath(Path:TConditionalStrings; AF','ile'+ 'Name:String; var FoundPath:String;ACPU:TCPU;AOS:TOS; Const PathPrefix '+ ':String='#039#039'):Boolean;'#010+ 'var'#010+ @@ -3535,7 +3543,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' Result:=false;'#010+ ' if PathPrefix<>'#039#039' then'#010+ - ' Prefix:=Includ','eTrailingPathDelimiter(PathPrefix)'#010+ + ' Prefix:=IncludeTrailingPathDel','imiter(PathPrefix)'#010+ ' else'#010+ ' Prefix:='#039#039';'#010+ ' for i:=0 to Path.Count-1 do'#010+ @@ -3543,8 +3551,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' C:=Path[I];'#010+ ' if (ACPU in C.CPUs) and (AOS in C.OSes) then'#010+ ' begin'#010+ - ' FoundPath:=IncludeTrailingPathDelimiter(Dictionar','y.Replace'+ - 'Strings(Prefix+C.Value));'#010+ + ' FoundPath:=IncludeTrailingPathDelimiter(Dictionary.ReplaceSt'+ + 'rings','(Prefix+C.Value));'#010+ ' if FileExists(FoundPath+AFileName) then'#010+ ' begin'#010+ ' result:=true;'#010+ @@ -3556,7 +3564,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'Procedure TBuildEngine.Res','olveFileNames(APackage : TPackage; ACPU:TC'+ + 'Procedure TBuildEngine.ResolveFileNames(AP','ackage : TPackage; ACPU:TC'+ 'PU;AOS:TOS);'#010+ 'var'#010+ ' SD : String;'#010+ @@ -3566,41 +3574,42 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' Dictionary.AddVariable('#039'CPU'#039',CPUToString(ACPU));'#010+ ' Dictionary.AddVariable('#039'OS'#039',OSToString(AOS));'#010+ - ' ',' For I:=0 to APackage.Targets.Count-1 do'#010+ + ' For I:=0 to APa','ckage.Targets.Count-1 do'#010+ ' begin'#010+ ' Target:=APackage.FTargets.TargetItems[I];'#010+ #010+ ' // Main source file'#010+ ' SD:=Target.Directory;'#010+ ' if SD='#039#039' then'#010+ - ' FindFileInPath(APackage.SourcePath,Target.SourceFileName,S','D,'+ - 'ACPU,AOS,APackage.Directory)'#010+ + ' FindFileInPath(APackage.SourcePath,Target.SourceFileName,SD,AC'+ + 'PU,AOS,APack','age.Directory)'#010+ ' else'#010+ ' if APackage.Directory<>'#039#039' then'#010+ ' SD:=IncludeTrailingPathDelimiter(APackage.Directory)+SD;'#010+ ' if SD<>'#039#039' then'#010+ ' SD:=IncludeTrailingPathDelimiter(SD);'#010+ - ' Target.FFullSourceF','ileName:=SD+Target.SourceFileName;'#010+ + ' Target.FFullSourceFileName:=SD+Targ','et.SourceFileName;'#010+ ' Log(vlDebug,SDebugResolvedSourceFile,[Target.SourceFileName,Targ'+ 'et.FFullSourceFileName]);'#010+ #010+ ' // Include files'#010+ ' for j:=0 to Target.Dependencies.Count-1 do'#010+ ' begin'#010+ - ' D:=Target.De','pendencies[j];'#010+ - ' if (D.DependencyType=depInclude) and DependencyOK(D) then'#010+ + ' D:=Target.Dependencies[j];'#010+ + ' ',' if (D.DependencyType=depInclude) and DependencyOK(D) then'+ + #010+ ' begin'#010+ ' SD:=D.Directory;'#010+ ' if SD='#039#039' then'#010+ ' FindFileInPath(APackage.IncludePath,D.Value,SD,ACPU,AO'+ - 'S,APackag','e.Directory)'#010+ - ' else'#010+ + 'S,APackage.Directory)'#010+ + ' ',' else'#010+ ' if APackage.Directory<>'#039#039' then'#010+ ' SD:=IncludeTrailingPathDelimiter(APackage.Directory)'+ '+SD;'#010+ ' if SD<>'#039#039' then'#010+ ' SD:=IncludeTrailingPathDelimiter(SD);'#010+ - ' ',' D.FFullFileName:=SD+D.Value;'#010+ + ' D.','FFullFileName:=SD+D.Value;'#010+ ' Log(vlDebug,SDebugResolvedIncludeFile,[D.Value,D.FFullF'+ 'ileName]);'#010+ ' end;'#010+ @@ -3611,8 +3620,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'Function TBuildEngine.NeedsCompile(Target: TTarget): Boolean;'#010+ 'Var'#010+ - ' I',' : Integer;'#010+ - ' T : TTarget;'#010+ + ' I : Integer;'#010+ + ' T ',': TTarget;'#010+ ' D : TDependency;'#010+ ' OD,OFN : String;'#010+ 'begin'#010+ @@ -3625,17 +3634,17 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' end;'#010+ ' tsNoCompile,'#010+ ' tsCompiled :'#010+ - ' exi','t;'#010+ + ' exit;'#010+ ' end;'#010+ #010+ - ' Log(vlDebug, Format(SDebugConsideringTarget, [Target.Name]));'#010+ + ' Log','(vlDebug, Format(SDebugConsideringTarget, [Target.Name]));'#010+ #010+ ' if Target.TargetType in ProgramTargets then'#010+ ' OD:=GetBinOutputDir(FCurrentPackage, True)'#010+ ' else'#010+ ' OD:=GetUnitsOutputDir(FCurrentPackage, True);'#010+ - ' If (OD<>'#039#039') ','then'#010+ - ' OD:=IncludeTrailingPathDelimiter(OD);'#010+ + ' If (OD<>'#039#039') then'#010+ + ' OD:=Inc','ludeTrailingPathDelimiter(OD);'#010+ ' OFN:=OD+Target.GetOutPutFileName(Defaults.OS);'#010+ #010+ ' Result:=Not FileExists(OFN);'#010+ @@ -3643,23 +3652,23 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Log(vlDebug,SDebugOutputNotYetAvailable,[OFN]);'#010+ #010+ ' // Check main source'#010+ - ' If not Result the','n'#010+ + ' If not Result then'#010+ ' begin'#010+ - ' if FileExists(Target.FullSourceFileName) then'#010+ + ' ',' if FileExists(Target.FullSourceFileName) then'#010+ ' Result:=FileNewer(Target.FullSourceFileName,OFN)'#010+ ' end;'#010+ #010+ ' // Check unit and include dependencies'#010+ ' If not Result then'#010+ ' If Target.HasDependencies then'#010+ - ' begin'#010, - ' ResolveDependencies(Target.Dependencies,Target.Collection as T'+ - 'Targets);'#010+ + ' begin'#010+ + ' ResolveD','ependencies(Target.Dependencies,Target.Collection as'+ + ' TTargets);'#010+ ' I:=0;'#010+ ' for i:=0 to Target.Dependencies.Count-1 do'#010+ ' begin'#010+ ' D:=Target.Dependencies[i];'#010+ - ' if (Defaults.CPU in D.CPUs) ','and (Defaults.OS in D.OSes) '+ + ' if (Defaults.CPU in D.CPUs) and (Defaults.OS',' in D.OSes) '+ 'then'#010+ ' begin'#010+ ' case D.DependencyType of'#010+ @@ -3667,26 +3676,26 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' begin'#010+ ' T:=TTarget(D.Target);'#010+ ' If (T=Nil) then'#010+ - ' ',' Error(SErrDepUnknownTarget,[Target.Name,D.Va'+ + ' Er','ror(SErrDepUnknownTarget,[Target.Name,D.Va'+ 'lue]);'#010+ ' // If a dependent package is compiled we always '+ 'need to recompile'#010+ ' Log(vldebug, SDebugDependencyOnUnit, [Target.Nam'+ 'e,T.Name]);'#010+ - ' ',' Result:=(T.State in [tsNeedCompile,tsCompiled]'+ + ' ',' Result:=(T.State in [tsNeedCompile,tsCompiled]'+ ') or NeedsCompile(T);'#010+ ' if Result then'#010+ ' Log(vldebug, SDebugDependencyUnitRecompiled, ['+ 'T.Name]);'#010+ ' end;'#010+ - ' ',' depInclude :'#010+ + ' depInclude ',':'#010+ ' begin'#010+ ' if FileExists(D.FullFileName) then'#010+ ' Result:=FileNewer(D.FullFileName,OFN)'#010+ ' end;'#010+ ' end;'#010+ - ' if result then'#010, - ' break;'#010+ + ' if result then'#010+ + ' ',' break;'#010+ ' end;'#010+ ' end;'#010+ ' end;'#010+ @@ -3695,8 +3704,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' if result then'#010+ ' begin'#010+ ' Target.FTargetState:=tsNeedCompile;'#010+ - ' Log(vlDebug,SDebugMustCompile,[Target','.Name]);'#010+ - ' end'#010+ + ' Log(vlDebug,SDebugMustCompile,[Target.Name]);'#010+ + ' end',#010+ ' else'#010+ ' Target.FTargetState:=tsNoCompile;'#010+ 'end;'#010+ @@ -3711,53 +3720,53 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' PD:=GetPackageDir(APackage,True);'#010+ #010+ - ' Result := '#039'-','n'#039';'#010+ - ' // Compile mode'#010+ + ' Result := '#039'-n'#039';'#010+ + ' // Compile',' mode'#010+ ' If Target.Mode<>cmFPC then'#010+ ' Result:=Result+'#039' -M'#039'+ModeToString(Target.Mode)'#010+ ' else If Defaults.Mode<>cmFPC then'#010+ ' Result:=Result+'#039' -M'#039'+ModeToString(Defaults.Mode);'#010+ ' // Output file paths'#010+ - ' If Target.TargetType in',' ProgramTargets then'#010+ + ' If Target.TargetType in ProgramTargets ','then'#010+ ' begin'#010+ ' OD:=GetBinOutputDir(APackage,True);'#010+ ' Result:=Result+'#039' -FE'#039' + ExtractRelativePath(PD,OD);'#010+ ' end;'#010+ ' OD:=GetUnitsOutputDir(APackage,True);'#010+ ' Result := Result + '#039' -FU'#039' + ExtractRelativePath(PD,OD);'#010+ - ' ','// Package Input file paths'#010+ + ' // Package Input',' file paths'#010+ ' If APackage.HasUnitPath then'#010+ ' AddConditionalStrings(Result,APackage.UnitPath,Defaults.CPU,Defaul'+ 'ts.OS,'#039'-Fu'#039');'#010+ ' If APackage.HasIncludePath then'#010+ - ' AddConditionalStrings(Result,APackage.IncludePath,Defaults.','CPU,D'+ - 'efaults.OS,'#039'-Fi'#039');'#010+ + ' AddConditionalStrings(Result,APackage.IncludePath,Defaults.CPU,Def'+ + 'aults.OS,',#039'-Fi'#039');'#010+ ' If APackage.HasObjectPath then'#010+ ' AddConditionalStrings(Result,APackage.ObjectPath,Defaults.CPU,Defa'+ 'ults.OS,'#039'-Fo'#039');'#010+ ' If Target.HasUnitPath then'#010+ - ' AddConditionalStrings(Result,Target.UnitPath,Defaults.CPU,Defaul','t'+ - 's.OS,'#039'-Fu'#039');'#010+ - ' If Target.HasIncludePath then'#010+ + ' AddConditionalStrings(Result,Target.UnitPath,Defaults.CPU,Defaults'+ + '.OS,'#039'-Fu'#039');'#010+ + ' ','If Target.HasIncludePath then'#010+ ' AddConditionalStrings(Result,Target.IncludePath,Defaults.CPU,Defau'+ 'lts.OS,'#039'-Fi'#039');'#010+ ' If Target.HasObjectPath then'#010+ ' AddConditionalStrings(Result,Target.ObjectPath,Defaults.CPU,Defaul'+ - 'ts.OS,'#039'-','Fo'#039');'#010+ - ' // Global unit dirs'#010+ + 'ts.OS,'#039'-Fo'#039');'#010+ + ' // Globa','l unit dirs'#010+ ' If Defaults.LocalUnitDir<>'#039#039' then'#010+ ' Result:=Result+'#039' -Fu'#039'+includeTrailingPathDelimiter(Default'+ 's.LocalUnitDir)+'#039'*'#039';'#010+ ' If Defaults.GlobalUnitDir<>'#039#039' then'#010+ - ' Result:=Result+'#039' -Fu'#039'+includeTrailingPathDelimiter(D','efau'+ - 'lts.GlobalUnitDir)+'#039'*'#039';'#010+ + ' Result:=Result+'#039' -Fu'#039'+includeTrailingPathDelimiter(Default'+ + 's.GlobalUn','itDir)+'#039'*'#039';'#010+ ' // Custom Options'#010+ ' If (Defaults.Options<>'#039#039') then'#010+ ' Result:=Result+'#039' '#039'+Defaults.Options;'#010+ ' If (APackage.Options<>'#039#039') then'#010+ ' Result:=Result+'#039' '#039'+APackage.Options;'#010+ ' If (Target.Options<>'#039#039') then'#010+ - ' Result:=R','esult+'#039' '#039'+Target.Options;'#010+ + ' Result:=Result+'#039' '#039'+Target','.Options;'#010+ ' // Add Filename to compile'#010+ ' Result:=Result+'#039' '#039'+Target.FullSourceFileName;'#010+ 'end;'#010+ @@ -3769,8 +3778,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' // Cache in FCompiler for speed.'#010+ ' If (FCompiler='#039#039') then'#010+ - ' ',' begin'#010+ - ' FCompiler:=Defaults.Compiler;'#010+ + ' begin'#010+ + ' FCom','piler:=Defaults.Compiler;'#010+ ' If (ExtractFilePath(FCompiler)='#039#039') then'#010+ ' begin'#010+ ' S:=FileSearch(FCompiler,GetEnvironmentVariable('#039'PATH'#039'));'+ @@ -3779,11 +3788,11 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' FCompiler:=S;'#010+ ' end;'#010+ ' end;'#010+ - ' Result:=FCom','piler;'#010+ + ' Result:=FCompiler;'#010+ 'end;'#010+ #010+ #010+ - 'procedure TBuildEngine.Compile(Target: TTarget);'#010+ + 'pr','ocedure TBuildEngine.Compile(Target: TTarget);'#010+ 'Var'#010+ ' S : String;'#010+ 'begin'#010+ @@ -3791,20 +3800,20 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' begin'#010+ ' Log(vlInfo,SLogCompilingTarget,[Target.Name]);'#010+ ' If Target.HasCommands then'#010+ - ' ',' ExecuteCommands(Target.Commands,caBeforeCompile);'#010+ + ' ExecuteComman','ds(Target.Commands,caBeforeCompile);'#010+ ' If Assigned(Target.BeforeCompile) then'#010+ ' Target.BeforeCompile(Target);'#010+ ' S:=GetCompilerCommand(FCurrentPackage,Target);'#010+ ' ExecuteCommand(GetCompiler,S);'#010+ - ' Target.F','TargetState:=tsCompiled;'#010+ + ' Target.FTargetState:=tsC','ompiled;'#010+ ' If Assigned(Target.AfterCompile) then'#010+ ' Target.AfterCompile(Target);'#010+ ' If Target.HasCommands then'#010+ ' ExecuteCommands(Target.Commands,caAfterCompile);'#010+ ' end'#010+ - ' else if Target.State<>tsCompiled t','hen'#010+ - ' Log(vlWarning, Format(SWarnAttemptingToCompileNonNeutralTarget, [T'+ - 'arget.Name]));'#010+ + ' else if Target.State<>tsCompiled then'#010+ + ' Log(vlWa','rning, Format(SWarnAttemptingToCompileNonNeutralTarget, '+ + '[Target.Name]));'#010+ 'end;'#010+ #010+ #010+ @@ -3814,28 +3823,28 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' T : TTarget;'#010+ ' D : TDependency;'#010+ 'begin'#010+ - ' if Target.State in [ts','Compiled,tsNoCompile] then'#010+ + ' if Target.State in [tsCompiled,tsNoCom','pile] then'#010+ ' exit;'#010+ ' Log(vlDebug, Format(SDebugCompilingDependenciesOfTarget, [Target.Nam'+ 'e]));'#010+ ' For I:=0 to Target.Dependencies.Count-1 do'#010+ ' begin'#010+ ' D:=Target.Dependencies[i];'#010+ - ' if (D.DependencyType=depUnit) and',#010+ - ' (Defaults.CPU in D.CPUs) and (Defaults.OS in D.OSes) then'#010+ + ' if (D.DependencyType=depUnit) and'#010+ + ' (Defau','lts.CPU in D.CPUs) and (Defaults.OS in D.OSes) then'#010+ ' begin'#010+ ' T:=TTarget(D.Target);'#010+ ' If Assigned(T) then'#010+ ' begin'#010+ ' // We don'#039't need to compile implicit units, they are'+ ' only'#010+ - ' ',' // used for dependency checking'#010+ + ' // used ','for dependency checking'#010+ ' if (T.TargetType<>ttImplicitUnit) then'#010+ ' begin'#010+ '{$warning Circular dependency check is disabled}'#010+ '// Log(vlWarning,SWarnCircularDependency,[Target.Na'+ - 'me,T.N','ame])'#010+ - ' MaybeCompile(T);'#010+ + 'me,T.Name])'#010+ + ' ',' MaybeCompile(T);'#010+ ' end;'#010+ ' end'#010+ ' else'#010+ @@ -3846,9 +3855,9 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ #010+ 'procedure TBuildEngine.MaybeCompile(Target: TTarget);'#010+ - 'b','egin'#010+ - ' ResolveDependencies(Target.Dependencies,Target.Collection as TTarget'+ - 's);'#010+ + 'begin'#010+ + ' ResolveDe','pendencies(Target.Dependencies,Target.Collection as TTarg'+ + 'ets);'#010+ ' CompileDependencies(Target);'#010+ ' if NeedsCompile(Target) then'#010+ ' begin'#010+ @@ -3858,7 +3867,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'function TB','uildEngine.GetPackageDir(APackage: TPackage; AbsolutePath'+ + 'function TBuildEngine.GetPa','ckageDir(APackage: TPackage; AbsolutePath'+ ': Boolean): String;'#010+ 'begin'#010+ ' If AbsolutePath then'#010+ @@ -3866,8 +3875,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' else'#010+ ' Result:='#039#039';'#010+ ' Result:=Result+APackage.Directory;'#010+ - ' If (Result<>'#039#039') the','n'#010+ - ' Result:= IncludeTrailingPathDelimiter(Result);'#010+ + ' If (Result<>'#039#039') then'#010+ + ' Result:= I','ncludeTrailingPathDelimiter(Result);'#010+ 'end;'#010+ #010+ #010+ @@ -3875,7 +3884,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' AbsolutePath : Boolean = False) : String;'#010+ 'begin'#010+ ' If (TargetDir<>'#039#039') then'#010+ - ' Result:=IncludeTrailingPathDeli','miter(TargetDir)'#010+ + ' Result:=IncludeTrailingPathDelimiter(TargetDir)',#010+ ' else'#010+ ' begin'#010+ ' If AbsolutePath then'#010+ @@ -3883,8 +3892,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' else'#010+ ' Result:='#039#039';'#010+ ' If (APackage.Directory<>'#039#039') then'#010+ - ' Result:=IncludeTrailingPathDelimiter(Result+A','Package.Directo'+ - 'ry);'#010+ + ' Result:=IncludeTrailingPathDelimiter(Result+APackage.Director', + 'y);'#010+ ' Result := IncludeTrailingPathDelimiter(Result + AName + PathDeli'+ 'm + Defaults.Target);'#010+ ' end;'#010+ @@ -3894,7 +3903,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'Function TBuildEngine.GetUnitsOutputDir(APackage : TPackage; AbsoluteP'+ 'ath : Boolean = False) : String;'#010+ 'begin'#010+ - ' R','esult := GetOutputDir('#039'units'#039', APackage, AbsolutePath);'#010+ + ' Result := GetOutp','utDir('#039'units'#039', APackage, AbsolutePath);'#010+ 'end;'#010+ #010+ #010+ @@ -3905,7 +3914,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'proced','ure TBuildEngine.CreateOutputDir(APackage: TPackage);'#010+ + 'procedure TBuildEngine','.CreateOutputDir(APackage: TPackage);'#010+ 'Var'#010+ ' D : String;'#010+ ' i: integer;'#010+ @@ -3915,15 +3924,15 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' If DirectoryExists(D) then'#010+ ' Log(vlInfo,SLogOutputDirExists,[D])'#010+ ' else'#010+ - ' ','begin'#010+ - ' Log(vlInfo,SLogCreatingOutputDir,[D]);'#010+ + ' begin'#010+ + ' Log(','vlInfo,SLogCreatingOutputDir,[D]);'#010+ ' CmdCreateDir(D);'#010+ ' end;'#010+ #010+ ' //also create a bin directory for programtargets'#010+ ' For i := 0 to Pred(APackage.Targets.Count) do'#010+ ' begin'#010+ - ' if APackage.Targets.TargetItems[i].TargetType',' in ProgramTargets '+ + ' if APackage.Targets.TargetItems[i].TargetType in ProgramTarge','ts '+ 'then'#010+ ' begin'#010+ ' D:=GetBinOutputDir(APackage,True);'#010+ @@ -3932,8 +3941,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' else'#010+ ' begin'#010+ ' Log(vlInfo,SLogCreatingOutputDir,[D]);'#010+ - ' CmdCreateD','ir(D);'#010+ - ' end;'#010+ + ' CmdCreateDir(D);'#010+ + ' end',';'#010+ #010+ ' exit; //do not continue loop, directory is made anyway'#010+ ' end;'#010+ @@ -3944,8 +3953,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'Function TBuildEngine.DependencyOK(ADependency : TDependency) : Boolea'+ 'n;'#010+ 'begin'#010+ - ' Result:=(Defaults.CPU in ADependency.CPUs) and (Defaults','.OS in ADe'+ - 'pendency.OSes);'#010+ + ' Result:=(Defaults.CPU in ADependency.CPUs) and (Defaults.OS in ADepe'+ + 'nden','cy.OSes);'#010+ 'end;'#010+ #010+ #010+ @@ -3956,18 +3965,18 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'Function TBuildEngine.PackageOK(APackage : TPackage) : Bo','olean;'#010+ + 'Function TBuildEngine.PackageOK(APackage : TPackage) : Boolean;'#010+ 'begin'#010+ - ' Result:=(Defaults.CPU in APackage.CPUs) and (Defaults.OS in APackage'+ - '.OSes);'#010+ + ' R','esult:=(Defaults.CPU in APackage.CPUs) and (Defaults.OS in APacka'+ + 'ge.OSes);'#010+ 'end;'#010+ #010+ #010+ 'procedure TBuildEngine.DoBeforeCompile(APackage: TPackage);'#010+ 'begin'#010+ ' If APackage.HasCommands then'#010+ - ' ExecuteCommands(APackage.Commands,caBefor','eCompile);'#010+ - ' If Assigned(APackage.BeforeCompile) then'#010+ + ' ExecuteCommands(APackage.Commands,caBeforeCompile);'#010+ + ' If ','Assigned(APackage.BeforeCompile) then'#010+ ' APackage.BeforeCompile(APackage);'#010+ 'end;'#010+ #010+ @@ -3975,8 +3984,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'procedure TBuildEngine.DoAfterCompile(APackage: TPackage);'#010+ 'begin'#010+ ' If Assigned(APackage.AfterCompile) then'#010+ - ' APackage.AfterCompile(APackage',');'#010+ - ' If APackage.HasCommands then'#010+ + ' APackage.AfterCompile(APackage);'#010+ + ' If APackage','.HasCommands then'#010+ ' ExecuteCommands(APackage.Commands,caAfterCompile);'#010+ 'end;'#010+ #010+ @@ -3986,22 +3995,22 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' T : TTarget;'#010+ ' I : Integer;'#010+ 'begin'#010+ - ' Log(vlInfo,SLogCompilingPackage,[APackage.Name]);'#010, - ' FCurrentPackage:=APackage;'#010+ + ' Log(vlInfo,SLogCompilingPackage,[APackage.Name]);'#010+ + ' FCurrentPackag','e:=APackage;'#010+ ' FCurrentOutputDir:=GetUnitsOutputDir(APackage,True);'#010+ ' Try'#010+ ' If (APackage.Directory<>'#039#039') then'#010+ ' EnterDir(APackage.Directory);'#010+ ' CreateOutputDir(APackage);'#010+ - ' Dictionary.AddVariable('#039'OUTPUTDIR'#039',FCurren','tOutputDir);'#010+ - ' DoBeforeCompile(APackage);'#010+ + ' Dictionary.AddVariable('#039'OUTPUTDIR'#039',FCurrentOutputDir);'#010+ + ' ',' DoBeforeCompile(APackage);'#010+ ' Try'#010+ ' For I:=0 to APackage.Targets.Count-1 do'#010+ ' begin'#010+ ' T:=APackage.Targets.TargetItems[i];'#010+ ' if (T.TargetType in [ttUnit,ttProgram]) then'#010+ ' begin'#010+ - ' ',' if TargetOK(T) then'#010+ + ' if TargetOK','(T) then'#010+ ' begin'#010+ ' if FForceCompile then'#010+ ' T.FTargetState:=tsNeedCompile;'#010+ @@ -4009,11 +4018,11 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' end'#010+ ' else'#010+ ' begin'#010+ - ' ',' if not(Defaults.CPU in T.CPUs) then'#010+ + ' if n','ot(Defaults.CPU in T.CPUs) then'#010+ ' Log(vldebug, Format(SDebugTargetHasWrongCPU, [CPUs'+ 'ToString(T.CPUs)]));'#010+ ' if not(Defaults.OS in T.OSes) then'#010+ - ' Log(vldebug, Format(SDebugTa','rgetHasWrongOS, [OSe'+ + ' Log(vldebug, Format(SDebugTargetHasWrongOS, ','[OSe'+ 'sToString(T.OSes)]));'#010+ ' end;'#010+ ' end'#010+ @@ -4022,7 +4031,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' end;'#010+ ' DoAfterCompile(APackage);'#010+ ' Finally'#010+ - ' If (APackage.Di','rectory<>'#039#039') then'#010+ + ' If (APackage.Directory<>'#039#039') the','n'#010+ ' EnterDir('#039#039');'#010+ ' end;'#010+ ' Finally'#010+ @@ -4035,15 +4044,15 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'procedure TBuildEngine.CheckExternalPackage(Const APackageName : Strin'+ 'g);'#010+ 'begin'#010+ - ' Log(vldebug, SDebugUnresolvedExt','ernalDependencyS, [APackageName]);'+ + ' Log(vldebug, SDebugUnresolvedExternalDependencyS',', [APackageName]);'+ #010+ #010+ ' If not DirectoryExists(IncludeTrailingPathDelimiter(Defaults.GlobalU'+ 'nitDir)+APackageName) and'#010+ ' ('#010+ ' (Defaults.LocalUnitDir='#039#039') or'#010+ - ' not DirectoryExists(IncludeTrailingPathDelimiter(Defaults.L','oca'+ - 'lUnitDir)+APackageName)'#010+ + ' not DirectoryExists(IncludeTrailingPathDelimiter(Defaults.LocalU'+ + 'nitDir)+APa','ckageName)'#010+ ' ) then'#010+ ' Error(SErrDependencyNotFound,[APackageName]);'#010+ 'end;'#010+ @@ -4055,21 +4064,21 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' P : TPackage;'#010+ ' D : TDependency;'#010+ 'begin'#010+ - ' if APackage.HasDep','endencies then'#010+ - ' For I:=0 to APackage.Dependencies.Count-1 do'#010+ + ' if APackage.HasDependencies then'#010+ + ' ',' For I:=0 to APackage.Dependencies.Count-1 do'#010+ ' begin'#010+ ' D:=APackage.Dependencies[i];'#010+ ' if (D.DependencyType=depPackage) and'#010+ ' (Defaults.CPU in D.CPUs) and (Defaults.OS in D.OSes) then'#010+ - ' beg','in'#010+ - ' P:=TPackage(D.Target);'#010+ + ' begin'#010+ + ' P',':=TPackage(D.Target);'#010+ ' // If it already was compiled, then State<>tsNeutral, and '+ 'it won'#039't be compiled again.'#010+ ' If Assigned(P) then'#010+ ' Compile(P)'#010+ ' else'#010+ - ' CheckExternalPac','kage(D.Value);'#010+ - ' end;'#010+ + ' CheckExternalPackage(D.Value);'#010+ + ' ',' end;'#010+ ' end;'#010+ 'end;'#010+ #010+ @@ -4081,15 +4090,15 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' UnitsDir: string;'#010+ ' BinDir: string;'#010+ 'begin'#010+ - ' List:=TStrin','gList.Create;'#010+ - ' Try'#010+ + ' List:=TStringList.Create;'#010+ + ' ','Try'#010+ ' UnitsDir := GetUnitsOutputDir(APackage);'#010+ ' BinDir := GetBinOutputDir(APackage);'#010+ ' APackage.GetInstallFiles(List,[tt],Src, UnitsDir, BinDir, Defaults'+ '.CPU, Defaults.OS);'#010+ ' if (List.Count>0) then'#010+ - ' CmdCopyFile','s(List,Dest);'#010+ - ' Finally'#010+ + ' CmdCopyFiles(List,Dest);'#010+ + ' ','Finally'#010+ ' List.Free;'#010+ ' end;'#010+ 'end;'#010+ @@ -4099,8 +4108,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' If APackage.HasCommands then'#010+ ' ExecuteCommands(APackage.Commands,caBeforeInstall);'#010+ - ' If Assigned(APackage.BeforeInsta','ll) then'#010+ - ' APackage.BeforeInstall(APackage);'#010+ + ' If Assigned(APackage.BeforeInstall) then'#010+ + ' APa','ckage.BeforeInstall(APackage);'#010+ 'end;'#010+ #010+ #010+ @@ -4109,7 +4118,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' If Assigned(APackage.AfterInstall) then'#010+ ' APackage.AfterInstall(APackage);'#010+ ' If APackage.HasCommands then'#010+ - ' Execute','Commands(APackage.Commands,caAfterInstall);'#010+ + ' ExecuteCommands(APackag','e.Commands,caAfterInstall);'#010+ 'end;'#010+ #010+ #010+ @@ -4119,43 +4128,43 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' If (Apackage.State<>tsCompiled) then'#010+ ' Compile(APackage);'#010+ - ' Log(vlInfo,SLogInstallingPackage,[APackage.N','ame]);'#010+ - ' DoBeforeInstall(APackage);'#010+ + ' Log(vlInfo,SLogInstallingPackage,[APackage.Name]);'#010+ + ' DoBefor','eInstall(APackage);'#010+ ' O:=GetUnitsOutputDir(APAckage);'#010+ ' PD:=GetPackageDir(APackage);'#010+ ' // units'#010+ ' D:=IncludeTrailingPathDelimiter(Defaults.UnitInstallDir)+APackage.Na'+ 'me;'#010+ ' InstallPackageFiles(APAckage,ttUnit,O,D);'#010+ - ' InstallP','ackageFiles(APAckage,ttImplicitUnit,O,D);'#010+ + ' InstallPackageFiles(APAc','kage,ttImplicitUnit,O,D);'#010+ ' // Programs'#010+ ' D:=IncludeTrailingPathDelimiter(Defaults.BinInstallDir);'#010+ ' InstallPackageFiles(APAckage,ttProgram,PD,D);'#010+ ' // Done.'#010+ ' APackage.FTargetState:=tsInstalled;'#010+ - ' DoAfterInstall(APackage);'#010, + ' DoAfterInstall(APackage);'#010+ 'end;'#010+ #010+ #010+ - 'procedure TBuildEngine.DoBeforeArchive(APackage: TPackage);'#010+ + 'procedure',' TBuildEngine.DoBeforeArchive(APackage: TPackage);'#010+ 'begin'#010+ ' If APackage.HasCommands then'#010+ ' ExecuteCommands(APackage.Commands,caBeforeArchive);'#010+ ' If Assigned(APackage.BeforeArchive) then'#010+ - ' APackage.BeforeArchive(APackage);',#010+ + ' APackage.BeforeArchive(APackage);'#010+ 'end;'#010+ #010+ #010+ - 'procedure TBuildEngine.DoAfterArchive(APackage: TPackage);'#010+ + 'procedur','e TBuildEngine.DoAfterArchive(APackage: TPackage);'#010+ 'begin'#010+ ' If Assigned(APackage.AfterArchive) then'#010+ ' APackage.AfterArchive(APackage);'#010+ ' If APackage.HasCommands then'#010+ ' ExecuteCommands(APackage.Commands,caAfterArchive);'#010+ - 'en','d;'#010+ + 'end;'#010+ #010+ #010+ - 'procedure TBuildEngine.Archive(APackage: TPackage);'#010+ + 'procedure T','BuildEngine.Archive(APackage: TPackage);'#010+ 'Var'#010+ ' L : TStringList;'#010+ ' PD,A : String;'#010+ @@ -4165,8 +4174,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' Log(vlInfo,SLogArchivingPackage,[APackage.Name]);'#010+ ' DoBeforeArchive(Apackage);'#010+ - ' L:=TStringL','ist.Create;'#010+ - ' L.Sorted:=true;'#010+ + ' L:=TStringList.Create;'#010+ + ' L.','Sorted:=true;'#010+ ' L.Duplicates:=dupIgnore;'#010+ ' Try'#010+ ' // Add fpmake.pp & manifest.xml always'#010+ @@ -4174,14 +4183,14 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' L.Add(PD+FPMakePPFile);'#010+ ' L.Add(PD+ManifestFile);'#010+ ' //get all files from all targets'#010+ - ' ',' for ICPU:=Low(TCPU) to high(TCPU) do'#010+ + ' for ICPU:=Low(','TCPU) to high(TCPU) do'#010+ ' for IOS:=Low(TOS) to high(TOS) do'#010+ ' if OSCpuPOSesible[IOS,ICPU] then'#010+ ' begin'#010+ ' ResolveFileNames(APackage,ICPU,IOS);'#010+ ' APackage.GetArchiveFiles(L, ICPU, IOS);'#010+ - ' ',' end;'#010+ - ' //from sources'#010+ + ' end;'#010+ + ' ','//from sources'#010+ ' for i := 0 to APackage.Sources.Count-1 do'#010+ ' L.Add(APackage.Sources[i].Name);'#010+ #010+ @@ -4189,7 +4198,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' for i := 0 to L.Count-1 do'#010+ ' Log(vlInfo, Format(SInfoArchiving, [L[i]]));'#010+ #010+ - ' A:=APackage.Fil','eName + ZipExt;'#010+ + ' A:=APackage.FileName + ZipExt;'#010, #010+ '{$ifdef HAS_UNIT_ZIPPER}'#010+ ' if not Assigned(ArchiveFilesProc) then'#010+ @@ -4200,8 +4209,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' else'#010+ '{$endif HAS_UNIT_ZIPPER}'#010+ ' CmdArchiveFiles(L,A);'#010+ - ' ','Finally'#010+ - ' L.Free;'#010+ + ' Finally'#010+ + ' L.Fr','ee;'#010+ #010+ '{$ifdef HAS_UNIT_ZIPPER}'#010+ ' if not Assigned(ArchiveFilesProc) then'#010+ @@ -4212,8 +4221,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ 'procedure TBuildEngine.DoBeforeClean(APackage: TPackage);'#010+ - 'begin'#010, - ' If APackage.HasCommands then'#010+ + 'begin'#010+ + ' If APackage.Ha','sCommands then'#010+ ' ExecuteCommands(APackage.Commands,caBeforeClean);'#010+ ' If Assigned(APackage.BeforeClean) then'#010+ ' APackage.BeforeClean(APackage);'#010+ @@ -4221,7 +4230,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'procedure TBuildEngine.DoAfterClean(APackage: TPackage);'#010+ 'begin'#010+ - ' If Assi','gned(APackage.AfterClean) then'#010+ + ' If Assigned(APackage.Af','terClean) then'#010+ ' APackage.AfterClean(APackage);'#010+ ' If APackage.HasCommands then'#010+ ' ExecuteCommands(APackage.Commands,caAfterClean);'#010+ @@ -4231,15 +4240,15 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'Var'#010+ ' OU : String;'#010+ - ' OB : String;',#010+ - ' List : TStringList;'#010+ + ' OB : String;'#010+ + ' List : TStrin','gList;'#010+ #010+ 'begin'#010+ ' Log(vlInfo,SLogCleaningPackage,[APackage.Name]);'#010+ ' DoBeforeClean(Apackage);'#010+ ' OU:=IncludeTrailingPathDelimiter(GetUnitsOutputDir(APAckage));'#010+ ' OB:=IncludeTrailingPathDelimiter(GetBinOutputDir(APAckage));'#010+ - ' Li','st:=TStringList.Create;'#010+ + ' List:=TStringList.','Create;'#010+ ' try'#010+ ' APackage.GetCleanFiles(List,OU, OB, Defaults.CPU,Defaults.OS);'#010+ ' if (List.Count>0) then'#010+ @@ -4251,7 +4260,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'function TBuildEngine.N','eedsCompile(APackage: TPackage): Boolean;'#010+ + 'function TBuildEngine.NeedsCompile(APac','kage: TPackage): Boolean;'#010+ 'Var'#010+ ' I : Integer;'#010+ ' P : TPackage;'#010+ @@ -4264,9 +4273,9 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' result:=true;'#010+ ' exit;'#010+ ' end;'#010+ - ' tsCompiled :'#010, + ' tsCompiled :'#010+ ' exit;'#010+ - ' end;'#010+ + ' en','d;'#010+ #010+ ' I:=0;'#010+ ' For I:=0 to APackage.Dependencies.Count-1 do'#010+ @@ -4274,8 +4283,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' D:=APackage.Dependencies[i];'#010+ ' if (D.DependencyType=depPackage) and'#010+ ' (Defaults.CPU in D.CPUs) and (Defaults.OS in D.OSes) then'#010+ - ' be','gin'#010+ - ' P:=TPackage(D.Target);'#010+ + ' begin'#010+ + ' P:','=TPackage(D.Target);'#010+ ' // I'#039'm not sure whether the target dir is OK here ??'#010+ ' Result:=Assigned(P) and NeedsCompile(P);'#010+ ' if Result then'#010+ @@ -4283,8 +4292,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' end;'#010+ ' end;'#010+ ' If Not Result then'#010+ - ' ',' begin'#010+ - ' I:=0;'#010+ + ' begin'#010+ + ' I:=','0;'#010+ ' While (Not Result) and (I'#039');'#010+ ' For I:=0 to Packages.Count-1 do'#010+ ' GetManifest(Packages.PackageItems[i],Manifest);'#010+ ' Manifest.Add('#039''#039');'#010+ ' If Assigned(AfterManifest) then'#010+ ' AfterManifest(Self);'#010+ - 'end',';'#010+ + 'end;'#010+ #010+ #010+ - '{*********************************************************************'+ - '*******'#010+ + '{***********','********************************************************'+ + '*********'#010+ ' TTarget'#010+ '**********************************************************************'+ '******}'#010+ #010+ - 'function TTarget.GetHasConditionalStri','ngs(AIndex: integer): Boolean;'+ + 'function TTarget.GetHasConditionalStrings(AIndex: inte','ger): Boolean;'+ #010+ 'begin'#010+ ' Result:=False;'#010+ @@ -4423,7 +4432,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' end;'#010+ 'end;'#010+ #010+ - 'function TTarget.Ge','tCommands: TCommands;'#010+ + 'function TTarget.GetCommands: TComm','ands;'#010+ 'begin'#010+ ' If FCommands=Nil then'#010+ ' FCommands:=TCommands.Create(TCommand);'#010+ @@ -4433,7 +4442,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'function TTarget.GetDependencies: TDependencies;'#010+ 'begin'#010+ ' If FDependencies=Nil then'#010+ - ' FDependencies:=TDependencies.Cr','eate(TDependency);'#010+ + ' FDependencies:=TDependencies.Create(TDependency',');'#010+ ' Result:=FDependencies;'#010+ 'end;'#010+ #010+ @@ -4447,14 +4456,14 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Result:=(FDependencies<>Nil);'#010+ 'end;'#010+ #010+ - 'function TTarget.G','etConditionalStrings(AIndex: integer): TConditiona'+ + 'function TTarget.GetConditionalStr','ings(AIndex: integer): TConditiona'+ 'lStrings;'#010+ 'begin'#010+ ' Result:=Nil;'#010+ ' Case AIndex Of'#010+ ' 0 : Result:=EnsureConditionalStrings(FUnitPath);'#010+ ' 1 : Result:=EnsureConditionalStrings(FObjectPath);'#010+ - ' 2 : Result:=EnsureConditionalS','trings(FIncludePath);'#010+ + ' 2 : Result:=EnsureConditionalStrings(FIncludeP','ath);'#010+ ' end;'#010+ 'end;'#010+ #010+ @@ -4466,10 +4475,10 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'procedure TTarget.SetDependencies(const AValue: TDependencies);'#010+ 'begin'#010+ ' GetDependencies.Assign(AValue);'#010+ - 'end',';'#010+ + 'end;'#010+ #010+ - 'procedure TTarget.SetConditionalStrings(AIndex: integer; const AValue:'+ - ' TConditionalStrings);'#010+ + 'procedure TTa','rget.SetConditionalStrings(AIndex: integer; const AValu'+ + 'e: TConditionalStrings);'#010+ 'begin'#010+ ' GetConditionalStrings(AIndex).Assign(AValue);'#010+ 'end;'#010+ @@ -4479,8 +4488,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' Result:=Name+FExtension;'#010+ 'end;'#010+ - #010, - 'function TTarget.GetUnitFileName: String;'#010+ + #010+ + 'function TTarget','.GetUnitFileName: String;'#010+ 'begin'#010+ ' Result:=Name+UnitExt;'#010+ 'end;'#010+ @@ -4495,7 +4504,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Result:=Name+RSText;'#010+ 'end;'#010+ #010+ - 'functio','n TTarget.GetProgramFileName(AOS : TOS): String;'#010+ + 'function TTarget.GetPro','gramFileName(AOS : TOS): String;'#010+ 'begin'#010+ ' if AOS in [Go32v2,Win32,Win64,OS2] then'#010+ ' Result:=Name+ExeExt'#010+ @@ -4505,8 +4514,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'constructor TTarget.Create(ACollection: TCollection);'#010+ 'begin'#010+ - ' inherited Create(ACollecti','on);'#010+ - ' FInstall:=True;'#010+ + ' inherited Create(ACollection);'#010+ + ' FInstall:','=True;'#010+ ' FCPUs:=AllCPUs;'#010+ ' FOSes:=AllOSes;'#010+ #010+ @@ -4522,7 +4531,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'fun','ction TTarget.GetOutputFileName(AOs: TOS): String;'#010+ + 'function TTarget.Ge','tOutputFileName(AOs: TOS): String;'#010+ 'begin'#010+ ' if TargetType in UnitTargets then'#010+ ' Result:=GetUnitFileName'#010+ @@ -4534,10 +4543,10 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'procedure TTarget.SetName(const AValue: String);'#010+ #010+ 'Var'#010+ - ' D,N,E : Stri','ng;'#010+ + ' D,N,E : String;'#010+ #010+ 'begin'#010+ - ' N:=FixPath(AValue);'#010+ + ' N:=','FixPath(AValue);'#010+ ' D:=ExtractFilePath(N);'#010+ ' E:=ExtractFileExt(N);'#010+ ' N:=ExtractFileName(N);'#010+ @@ -4547,8 +4556,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' E:=Defaults.SourceExt;'#010+ ' inherited SetName(N);'#010+ ' FExtension:=E;'#010+ - ' F','Directory:=D;'#010+ - 'end;'#010+ + ' FDirectory:=D;'#010+ + 'en','d;'#010+ #010+ #010+ 'procedure TTarget.GetCleanFiles(List: TStrings; const APrefixU, APrefi'+ @@ -4557,12 +4566,12 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' If not(ACPU in CPUs) or not(AOS in OSes) then'#010+ ' exit;'#010+ ' List.Add(APrefixU + ObjectFileName);'#010+ - ' If (Tar','getType in [ttUnit,ttImplicitUnit,ttExampleUnit]) then'#010+ + ' If (TargetType in [ttUn','it,ttImplicitUnit,ttExampleUnit]) then'#010+ ' List.Add(APrefixU + UnitFileName)'#010+ ' else If (TargetType in [ttProgram,ttExampleProgram]) then'#010+ ' List.Add(APrefixB + GetProgramFileName(AOS));'#010+ ' If ResourceStrings then'#010+ - ' List.Ad','d(APrefixU + RSTFileName);'#010+ + ' List.Add(APrefixU + RST','FileName);'#010+ ' // Maybe add later ? AddConditionalStrings(List,CleanFiles);'#010+ 'end;'#010+ #010+ @@ -4570,13 +4579,13 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'procedure TTarget.GetInstallFiles(List: TStrings; const APrefixU, APre'+ 'fixB: String; ACPU: TCPU; AOS : TOS);'#010+ 'begin'#010+ - ' If not(ACPU in CPUs) or no','t(AOS in OSes) then'#010+ + ' If not(ACPU in CPUs) or not(AOS in OSes) t','hen'#010+ ' exit;'#010+ ' If Not (TargetType in [ttProgram,ttExampleProgram]) then'#010+ ' List.Add(APrefixU + ObjectFileName);'#010+ ' If (TargetType in [ttUnit,ttImplicitUnit,ttExampleUnit]) then'#010+ ' List.Add(APrefixU + UnitFileName)'#010+ - ' else I','f (TargetType in [ttProgram,ttExampleProgram]) then'#010+ + ' else If (TargetType in',' [ttProgram,ttExampleProgram]) then'#010+ ' List.Add(APrefixB + GetProgramFileName(AOS));'#010+ ' If ResourceStrings then'#010+ ' List.Add(APrefixU + RSTFileName);'#010+ @@ -4584,7 +4593,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'p','rocedure TTarget.GetArchiveFiles(List: TStrings; ACPU: TCPU; AOS : '+ + 'procedure TTarget','.GetArchiveFiles(List: TStrings; ACPU: TCPU; AOS : '+ 'TOS);'#010+ 'var'#010+ ' i : integer;'#010+ @@ -4595,7 +4604,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' // Main source'#010+ ' List.Add(FullSourceFileName);'#010+ ' // Includes'#010+ - ' ','for i:=0 to Dependencies.Count-1 do'#010+ + ' for i:=0 to Depe','ndencies.Count-1 do'#010+ ' begin'#010+ ' D:=Dependencies[i];'#010+ ' if (D.DependencyType=depInclude) and'#010+ @@ -4607,7 +4616,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ '{ TSource }'#010+ #010+ - 'constructor',' TSource.Create(ACollection: TCollection);'#010+ + 'constructor TSource.Create(','ACollection: TCollection);'#010+ 'begin'#010+ ' inherited Create(ACollection);'#010+ 'end;'#010+ @@ -4623,7 +4632,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'function TCommands.GetCommand(const Dest : String): TCommand;'#010+ #010+ 'begin'#010+ - ' Resu','lt:=TCommand(ItemByName(Dest));'#010+ + ' Result:=TCommand(Ite','mByName(Dest));'#010+ 'end;'#010+ #010+ 'function TCommands.GetCommandItem(Index : Integer): TCommand;'#010+ @@ -4634,8 +4643,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'procedure TCommands.SetCommandItem(Index : Integer; const AValue: TCom'+ 'mand);'#010+ 'begin'#010+ - ' Items[Ind','ex]:=AValue;'#010+ - 'end;'#010+ + ' Items[Index]:=AValue;'#010+ + 'end',';'#010+ #010+ 'Function TCommands.AddCommand(const Cmd: String) : TCommand;'#010+ 'begin'#010+ @@ -4644,7 +4653,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'function TCommands.AddCommand(const Cmd, Options: String): TCommand;'#010+ 'begin'#010+ - ' Result:=AddCommand(fdefa','ultAt,Cmd,Options,'#039#039','#039#039');'#010+ + ' Result:=AddCommand(fdefaultAt,Cmd,Option','s,'#039#039','#039#039');'#010+ 'end;'#010+ #010+ 'function TCommands.AddCommand(const Cmd, Options, Dest, Source: String'+ @@ -4654,8 +4663,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Result:=AddCommand(fdefaultAt,Cmd,options,Dest,Source);'#010+ 'end;'#010+ #010+ - 'Function TCommands.AddCommand(At: TCommandAt; const ','Cmd: String) : T'+ - 'Command;'#010+ + 'Function TCommands.AddCommand(At: TCommandAt; const Cmd: String) : T','C'+ + 'ommand;'#010+ 'begin'#010+ ' Result:=AddCommand(At,Cmd,'#039#039','#039#039','#039#039');'#010+ 'end;'#010+ @@ -4667,7 +4676,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Result:=AddCommand(At,Cmd,Options,'#039#039','#039#039');'#010+ 'end;'#010+ #010+ - 'function TCommands.A','ddCommand(At: TCommandAt; const Cmd, Options, De'+ + 'function TCommands.AddCommand(At: TC','ommandAt; const Cmd, Options, De'+ 'st,'#010+ ' Source: String): TCommand;'#010+ 'begin'#010+ @@ -4677,9 +4686,9 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Result.At:=At;'#010+ ' Result.SourceFile:=Source;'#010+ ' Result.DestFile:=Dest;'#010+ - 'end;'#010, + 'end;'#010+ #010+ - '{ TConditionalStrings }'#010+ + '{ TConditionalS','trings }'#010+ #010+ 'Constructor TConditionalStrings.Create(AClass:TClass);'#010+ 'begin'#010+ @@ -4689,8 +4698,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'function TConditionalStrings.GetConditionalString(Index : Integer): TC'+ 'onditionalString;'#010+ 'begin'#010+ - ' Result:=TConditionalString(Item','s[Index]);'#010+ - 'end;'#010+ + ' Result:=TConditionalString(Items[Index]);'#010+ + 'end;'#010, #010+ 'procedure TConditionalStrings.SetConditionalString(Index : Integer; co'+ 'nst AValue: TConditionalString);'#010+ @@ -4701,7 +4710,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'Function TConditionalStrings.Add(Const Value : String) : TConditionalS'+ 'tring;'#010+ 'begin'#010+ - ' ',' result:=Add(Value,AllCPUs,AllOSes);'#010+ + ' result:=Add(Val','ue,AllCPUs,AllOSes);'#010+ 'end;'#010+ #010+ 'Function TConditionalStrings.Add(Const Value : String;const CPUs:TCPUs'+ @@ -4710,8 +4719,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' result:=Add(Value,CPUs,AllOSes);'#010+ 'end;'#010+ #010+ - 'Function TConditionalStrings.Add(Const Value : String;co','nst OSes:TOS'+ - 'es) : TConditionalString;'#010+ + 'Function TConditionalStrings.Add(Const Value : String;const OSes:TOSes'+ + ') ',': TConditionalString;'#010+ 'begin'#010+ ' result:=Add(Value,AllCPUs,OSes);'#010+ 'end;'#010+ @@ -4719,8 +4728,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'Function TConditionalStrings.Add(Const Value : String;const CPUs:TCPUs'+ ';const OSes:TOSes) : TConditionalString;'#010+ 'begin'#010+ - ' Result:=FCSClass.Create as TConditio','nalString;'#010+ - ' Result.Value:=Value;'#010+ + ' Result:=FCSClass.Create as TConditionalString;'#010+ + ' Res','ult.Value:=Value;'#010+ ' Result.OSes:=OSes;'#010+ ' Result.CPUs:=CPUs;'#010+ ' inherited Add(Result);'#010+ @@ -4732,7 +4741,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Result:=TDependency(Items[Index]);'#010+ 'end;'#010+ #010+ - 'procedure TDepe','ndencies.SetDependency(Index : Integer; const AValue:'+ + 'procedure TDependencies.SetDepe','ndency(Index : Integer; const AValue:'+ ' TDependency);'#010+ 'begin'#010+ ' Items[Index]:=AValue;'#010+ @@ -4743,7 +4752,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' result:=Add(Value,AllCPUs,AllOSes);'#010+ 'end;'#010+ #010+ - 'Function TDependencies','.Add(Const Value : String;const CPUs:TCPUs) : '+ + 'Function TDependencies.Add(Const Value',' : String;const CPUs:TCPUs) : '+ 'TDependency;'#010+ 'begin'#010+ ' result:=Add(Value,CPUs,AllOSes);'#010+ @@ -4755,7 +4764,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' result:=Add(Value,AllCPUs,OSes);'#010+ 'end;'#010+ #010+ - 'Functi','on TDependencies.Add(Const Value : String;const CPUs:TCPUs;con'+ + 'Function TDependencies','.Add(Const Value : String;const CPUs:TCPUs;con'+ 'st OSes:TOSes) : TDependency;'#010+ 'begin'#010+ ' Result:=inherited Add(Value,CPUs,OSes) as TDependency;'#010+ @@ -4764,7 +4773,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ #010+ - 'Function TDependen','cies.AddUnit(Const Value : String) : TDependency;'#010+ + 'Function TDependencies.AddUnit(Con','st Value : String) : TDependency;'#010+ 'begin'#010+ ' result:=AddUnit(Value,AllCPUs,AllOSes);'#010+ 'end;'#010+ @@ -4774,17 +4783,17 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' result:=AddUnit(Value,CPUs,AllOSes);'#010+ 'end;'#010+ - #010, - 'Function TDependencies.AddUnit(Const Value : String;const OSes:TOSes) '+ - ': TDependency;'#010+ + #010+ + 'Function TDepend','encies.AddUnit(Const Value : String;const OSes:TOSes'+ + ') : TDependency;'#010+ 'begin'#010+ ' result:=AddUnit(Value,AllCPUs,OSes);'#010+ 'end;'#010+ #010+ 'Function TDependencies.AddUnit(Const Value : String;const CPUs:TCPUs;c'+ 'onst OSes:TOSes) : TDependency;'#010+ - 'be','gin'#010+ - ' Result:=inherited Add(Value,CPUs,OSes) as TDependency;'#010+ + 'begin'#010+ + ' Result:=in','herited Add(Value,CPUs,OSes) as TDependency;'#010+ ' Result.Target:=nil;'#010+ ' Result.FDependencyType:=depUnit;'#010+ 'end;'#010+ @@ -4793,19 +4802,19 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'Function TDependencies.AddInclude(Const Value : String) : TDependency;'+ #010+ 'begin'#010+ - ' result:=AddInclude(Value,AllCPUs,All','OSes);'#010+ + ' result:=AddInclude(Value,AllCPUs,AllOSes);'#010+ 'end;'#010+ #010+ - 'Function TDependencies.AddInclude(Const Value : String;const CPUs:TCPU'+ - 's) : TDependency;'#010+ + 'Fun','ction TDependencies.AddInclude(Const Value : String;const CPUs:TC'+ + 'PUs) : TDependency;'#010+ 'begin'#010+ ' result:=AddInclude(Value,CPUs,AllOSes);'#010+ 'end;'#010+ #010+ 'Function TDependencies.AddInclude(Const Value : String;const OSes:TOSe'+ - 's) : TDependenc','y;'#010+ + 's) : TDependency;'#010+ 'begin'#010+ - ' result:=AddInclude(Value,AllCPUs,OSes);'#010+ + ' resul','t:=AddInclude(Value,AllCPUs,OSes);'#010+ 'end;'#010+ #010+ 'Function TDependencies.AddInclude(Const Value : String;const CPUs:TCPU'+ @@ -4815,7 +4824,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' N:=FixPath(Value);'#010+ ' D:=ExtractFilePath(N);'#010+ - ' N:=E','xtractFileName(N);'#010+ + ' N:=ExtractFileName(N',');'#010+ ' if ExtractFileExt(N)='#039#039' then'#010+ ' ChangeFileExt(N,IncExt);'#010+ ' Result:=inherited Add(N,CPUs,OSes) as TDependency;'#010+ @@ -4826,7 +4835,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( '{ Default Instances }'#010+ #010+ 'Var'#010+ - ' DefInstalle','r : TCustomInstaller = Nil;'#010+ + ' DefInstaller : TCustomInsta','ller = Nil;'#010+ ' DefDictionary : TDictionary = Nil;'#010+ #010+ 'Function Installer(InstallerClass: TInstallerClass): TCustomInstaller;'+ @@ -4834,9 +4843,9 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' If Not Assigned(DefInstaller) then'#010+ ' DefInstaller:=InstallerClass.Create(Nil);'#010+ - ' Result:=DefI','nstaller;'#010+ + ' Result:=DefInstaller;'#010+ 'end;'#010+ - #010+ + #010, 'Function Installer: TCustomInstaller;'#010+ 'begin'#010+ ' Result := Installer(TFPCInstaller);'#010+ @@ -4851,7 +4860,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'function Dictionary : TDictionary;'#010+ 'begin'#010+ - ' If Not Assig','ned(DefDictionary) then'#010+ + ' If Not Assigned(DefDictionar','y) then'#010+ ' DefDictionary:=DictionaryClass.Create(Nil);'#010+ ' Result:=DefDictionary;'#010+ 'end;'#010+ @@ -4865,7 +4874,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ '{ TFunctionItem }'#010+ #010+ - 'constructor TFunctionItem','.Create(AFunc: TReplaceFunction);'#010+ + 'constructor TFunctionItem.Create(AFunc: T','ReplaceFunction);'#010+ 'begin'#010+ ' FFunc:=AFunc;'#010+ 'end;'#010+ @@ -4877,10 +4886,10 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' inherited Create(AOwner);'#010+ ' FList:=TStringList.Create;'#010+ ' FList.Sorted:=True;'#010+ - ' FList.Duplicates:=dupE','rror;'#010+ + ' FList.Duplicates:=dupError;'#010+ 'end;'#010+ #010+ - 'destructor TDictionary.Destroy;'#010+ + 'dest','ructor TDictionary.Destroy;'#010+ #010+ 'Var'#010+ ' I : Integer;'#010+ @@ -4892,10 +4901,10 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' inherited Destroy;'#010+ 'end;'#010+ #010+ - 'procedure TDictionary.AddVariable(const AName, Value: String);'#010, + 'procedure TDictionary.AddVariable(const AName, Value: String);'#010+ #010+ 'Var'#010+ - ' I : Integer;'#010+ + ' I : Integ','er;'#010+ #010+ 'begin'#010+ ' I:=Flist.IndexOf(AName);'#010+ @@ -4907,7 +4916,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'end;'#010+ #010+ 'procedure TDictionary.AddFunction(const AName: String;'#010+ - ' FRep','lacement: TReplaceFunction);'#010+ + ' FReplacement: TRepla','ceFunction);'#010+ #010+ 'Var'#010+ ' I : Integer;'#010+ @@ -4921,7 +4930,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Flist.Objects[i]:=TFunctionItem.Create(FReplacement);'#010+ 'end;'#010+ #010+ - 'procedure TDictionary.','RemoveItem(const AName: String);'#010+ + 'procedure TDictionary.RemoveItem(const',' AName: String);'#010+ #010+ 'Var'#010+ ' I : Integer;'#010+ @@ -4937,8 +4946,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ 'function TDictionary.GetValue(const AName: String): String;'#010+ #010+ - 'b','egin'#010+ - ' Result:=GetValue(AName,'#039#039');'#010+ + 'begin'#010+ + ' Result:=G','etValue(AName,'#039#039');'#010+ 'end;'#010+ #010+ #010+ @@ -4951,7 +4960,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( 'begin'#010+ ' I:=Flist.IndexOf(AName);'#010+ ' If (I=-1) then'#010+ - ' Raise EDictionaryError.CreateFmt(SErrNoDict','ionaryItem,[AName]);'#010+ + ' Raise EDictionaryError.CreateFmt(SErrNoDictionaryItem,[ANam','e]);'#010+ ' O:=Flist.Objects[I];'#010+ ' If O is TValueItem then'#010+ ' Result:=TValueItem(O).FValue'#010+ @@ -4963,7 +4972,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( #010+ #010+ 'Var'#010+ - ' ','S,FN,FV : String;'#010+ + ' S,FN,FV : String',';'#010+ ' P: Integer;'#010+ #010+ 'begin'#010+ @@ -4977,8 +4986,8 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' P:=Pos('#039')'#039',S);'#010+ ' FN:=Copy(S,1,P-1);'#010+ ' Delete(S,1,P);'#010+ - ' P:=Pos(',#039' '#039',FN);'#010+ - ' If (P<>0) then // function arguments ?'#010+ + ' P:=Pos('#039' '#039',FN);'#010+ + ' If ','(P<>0) then // function arguments ?'#010+ ' begin'#010+ ' FV:=FN;'#010+ ' FN:=Copy(FN,1,P);'#010+ @@ -4989,11 +4998,11 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Result:=Result+GetValue(FN,FV);'#010+ ' P:=Pos('#039'$('#039',S);'#010+ ' end;'#010+ - ' Result:=R','esult+S;'#010+ + ' Result:=Result+S;'#010+ 'end;'#010+ #010+ - 'Function Substitute(Const Source : String; Macros : Array of string) :'+ - ' String;'#010+ + 'F','unction Substitute(Const Source : String; Macros : Array of string)'+ + ' : String;'#010+ 'Var'#010+ ' I : Integer;'#010+ 'begin'#010+ @@ -5003,7 +5012,7 @@ const fpmkunitsrc : array[0..547,1..240] of char=( ' Dictionary.AddVariable(Macros[i],Macros[I+1]);'#010+ ' Inc(I,2);'#010+ ' end;'#010+ - ' R','esult:=Dictionary.ReplaceStrings(Source);'#010+ + ' Result:=Dictionar','y.ReplaceStrings(Source);'#010+ ' While I