codetools: set MAC_OS_X_VERSION_MIN_REQUIRED from -WM parameter

git-svn-id: trunk@57777 -
This commit is contained in:
mattias 2018-05-03 12:16:46 +00:00
parent 9f9965c410
commit efdc34d3e6

View File

@ -102,6 +102,7 @@ const
TargetCPUMacro = '$('+TargetCPUMacroName+')';
NamespacesMacro = '$('+NamespacesMacroName+')';
MacOSMinSDKVersionMacro = 'MAC_OS_X_VERSION_MIN_REQUIRED';
// virtual directories
VirtualDirectory='VIRTUALDIRECTORY';
@ -7984,6 +7985,7 @@ var
i: Integer;
Param, Namespaces: String;
p: PChar;
MacMinVer: single;
begin
Result:=nil;
if AlwaysCreate then
@ -8061,6 +8063,13 @@ begin
ctsDefine+MacroControllerUnit,MacroControllerUnit,
s);
end;
'M':
begin
val(copy(Param,4,255),MacMinVer,m);
if m=0 then
AddDefine(MacOSMinSDKVersionMacro,MacOSMinSDKVersionMacro,
MacOSMinSDKVersionMacro,IntToStr(Round(MacMinVer*100)));
end;
end;
end;