Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[iOS] Add gss framework back into sample linker args #83182

Merged
merged 2 commits into from
Mar 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/mono/msbuild/apple/build/AppleApp.targets
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@

<!-- common linker arguments for app and library builds -->
<ItemGroup>
<_CommonLinkerArgs Condition="'$(TargetOS)' != 'tvos'" Include="-framework GSS" />
steveisok marked this conversation as resolved.
Show resolved Hide resolved
<_CommonLinkerArgs Condition="'$(_IsLibraryMode)' == 'true' and '$(TargetOS)' != 'tvos' and '$(TargetOS)' != 'tvossimulator'" Include="-framework GSS" />
</ItemGroup>

<PropertyGroup>
Expand Down
8 changes: 8 additions & 0 deletions src/tasks/AppleAppBuilder/Xcode.cs
Original file line number Diff line number Diff line change
Expand Up @@ -400,12 +400,20 @@ public string GenerateCMake(
toLink += $" {asmLinkFile}{Environment.NewLine}";
}

string frameworks = "";
if ((Target == TargetNames.iOS) || (Target == TargetNames.iOSsim) || (Target == TargetNames.MacCatalyst))
{
frameworks = "\"-framework GSS\"";
}

string appLinkerArgs = "";
foreach(string linkerArg in extraLinkerArgs)
{
appLinkerArgs += $" \"{linkerArg}\"{Environment.NewLine}";
}

appLinkerArgs += $" {frameworks}{Environment.NewLine}";

cmakeLists = cmakeLists.Replace("%NativeLibrariesToLink%", toLink);
cmakeLists = cmakeLists.Replace("%APP_LINKER_ARGS%", appLinkerArgs);
cmakeLists = cmakeLists.Replace("%AotSources%", aotSources);
Expand Down