program dcomp; {$APPTYPE CONSOLE} uses System.SysUtils, UCompiler in 'Compiler\UCompiler.pas', UTargetPHP in 'TargetPHP\UTargetPHP.pas', UAnalyzerPascal in 'Compiler\UAnalyzerPascal.pas', UAnalyzer in 'Compiler\UAnalyzer.pas', UTarget in 'Compiler\UTarget.pas', USourceCode in 'Compiler\USourceCode.pas', USourceCodePascal in 'Compiler\USourceCodePascal.pas'; type TApplication = class procedure Run; end; { TApplication } procedure TApplication.Run; var Compiler: TCompiler; begin Compiler := TCompiler.Create; if ParamCount > 0 then Compiler.MainSourceFile := ParamStr(1); Compiler.RegisterTarget(TTargetPHP); Compiler.RegisterAnalyzer(TAnalyzerPascal); Compiler.Compile; end; var Application: TApplication; begin try Application := TApplication.Create; Application.Run; Application.Free; ReadLn; { TODO -oUser -cConsole Main : Insert code here } except on E: Exception do Writeln(E.ClassName, ': ', E.Message); end; end.