mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-14 20:09:27 +02:00
* Set subtarget define as soon as -t option is parsed
This commit is contained in:
parent
e076c6fc59
commit
f232009010
@ -4277,7 +4277,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',SubTarget);
|
||||||
|
AddDefine('FPC_SUBTARGET_'+Uppercase(SubTarget));
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TPas2jsCompiler.CreateImportList: TJSSourceElements;
|
function TPas2jsCompiler.CreateImportList: TJSSourceElements;
|
||||||
@ -4611,8 +4612,10 @@ begin
|
|||||||
AddDefine('STR_CONCAT_PROCS');
|
AddDefine('STR_CONCAT_PROCS');
|
||||||
AddDefine('UNICODE');
|
AddDefine('UNICODE');
|
||||||
if SubTarget<>'' then
|
if SubTarget<>'' then
|
||||||
|
begin
|
||||||
AddDefine('FPC_SUBTARGET',SubTarget);
|
AddDefine('FPC_SUBTARGET',SubTarget);
|
||||||
|
AddDefine('FPC_SUBTARGET_'+Uppercase(SubTarget));
|
||||||
|
end;
|
||||||
FHasShownLogo:=false;
|
FHasShownLogo:=false;
|
||||||
FHasShownEncoding:=false;
|
FHasShownEncoding:=false;
|
||||||
FFS.Reset;
|
FFS.Reset;
|
||||||
|
Loading…
Reference in New Issue
Block a user