Browse Source

* SUBTARGET defines

Michaël Van Canneyt 1 year ago
parent
commit
124834fe29
1 changed files with 2 additions and 1 deletions
  1. 2 1
      packages/pastojs/src/pas2jscompiler.pp

+ 2 - 1
packages/pastojs/src/pas2jscompiler.pp

@@ -4279,7 +4279,8 @@ procedure TPas2jsCompiler.SetSubTarget(AValue: String);
 begin
 begin
   if FSubTarget=AValue then Exit;
   if FSubTarget=AValue then Exit;
   FSubTarget:=AValue;
   FSubTarget:=AValue;
-  //
+  AddDefine('FPC_SUBTARGET',UPPERCASE(aValue));
+  AddDefine('FPC_SUBTARGET_'+UPPERCASE(aValue));
 end;
 end;
 
 
 function TPas2jsCompiler.CreateImportList: TJSSourceElements;
 function TPas2jsCompiler.CreateImportList: TJSSourceElements;