ソースを参照

* Instantiate PCU compiler

git-svn-id: trunk@40451 -
michael 6 年 前
コミット
2c7f401bf7
1 ファイル変更6 行追加4 行削除
  1. 6 4
      utils/pas2js/pas2js.pp

+ 6 - 4
utils/pas2js/pas2js.pp

@@ -12,7 +12,7 @@ uses
   cthreads, cwstring,
   {$ENDIF}
   Classes, SysUtils, CustApp,
-  Pas2jsFileUtils, Pas2jsLogger, Pas2jsCompiler;
+  Pas2jsFileUtils, Pas2jsLogger, Pas2jsCompiler, pas2jspcucompiler, pas2jscompilerpp, pas2JScompilercfg;
 
 Type
 
@@ -20,14 +20,14 @@ Type
 
   TPas2jsCLI = class(TCustomApplication)
   private
-    FCompiler: TPas2jsCompiler;
+    FCompiler: TPas2jsPCUCompiler;
     FWriteOutputToStdErr: Boolean;
   protected
     procedure DoRun; override;
   public
     constructor Create(TheOwner: TComponent); override;
     destructor Destroy; override;
-    property Compiler: TPas2jsCompiler read FCompiler;
+    property Compiler: TPas2jsPCUCompiler read FCompiler;
     property WriteOutputToStdErr: Boolean read FWriteOutputToStdErr write FWriteOutputToStdErr;
   end;
 
@@ -66,7 +66,9 @@ constructor TPas2jsCLI.Create(TheOwner: TComponent);
 begin
   inherited Create(TheOwner);
   StopOnException:=True;
-  FCompiler:=TPas2jsCompiler.Create;
+  FCompiler:=TPas2jsPCUCompiler.Create;
+  FCompiler.ConfigSupport:=TPas2JSFileConfigSupport.Create(FCompiler);
+  FCompiler.PostProcessorSupport:=TPas2JSFSPostProcessorSupport.Create(FCompiler);
 end;
 
 destructor TPas2jsCLI.Destroy;