[net11.0] bundle DynamicLibrary publish items added after _ComputePublishLocation#25581
Closed
kotlarmilos wants to merge 1 commit into
Closed
Conversation
…lishLocation _ComputePublishLocation resolves the final RelativePath for DynamicLibrary and PluginLibrary items in ResolvedFileToPublish, but on iOS, tvOS, and Mac Catalyst it runs early as a dependency of _CreateRuntimeConfiguration. Any item added later by an extension hooking the documented BeforeTargets="ComputeFilesToPublish" extension point keeps its raw RelativePath and lands in bin/.../publish/ instead of the signed .app bundle, because the second _ComputePublishLocation invocation is cached and skipped. This breaks the VS Code MAUI extension's CoreCLR remote-debugger flow: libvsdbgremotecoreclrtarget.dylib never reaches the bundle, CORECLR_PROFILER_PATH cannot load the profiler on launch, and every user breakpoint reports "failed to bind". Add _BundleLateDynamicLibrariesToPublish to CreateAppBundleDependsOn, between _ComputePublishLocation and _ComputeCodesignItems. It re-routes any DynamicLibrary or PluginLibrary item whose RelativePath does not already point inside _RelativeAppBundlePath so the rest of the iOS SDK pipeline (codesign, layout, mlaunch deploy) treats it like any other native dependency. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Member
Author
|
Reopening from origin branch (dev/...) per convention. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
_ComputePublishLocationresolves the finalRelativePathforDynamicLibrary/PluginLibraryitems inResolvedFileToPublish, but on iOS, tvOS, and Mac Catalyst it runs early as a dependency of_CreateRuntimeConfiguration. Any item added later by an extension hooking the documentedBeforeTargets="ComputeFilesToPublish"extension point keeps its rawRelativePathand lands inbin/.../publish/instead of the signed.appbundle, because the second_ComputePublishLocationinvocation is cached and skipped. This breaks the VS Code MAUI extension's CoreCLR remote-debugger flow:libvsdbgremotecoreclrtarget.dylibnever reaches the bundle,CORECLR_PROFILER_PATHcannot load the profiler on launch, and every user breakpoint reports "failed to bind". Fix: add_BundleLateDynamicLibrariesToPublishtoCreateAppBundleDependsOn, between_ComputePublishLocationand_ComputeCodesignItems. It re-routes anyDynamicLibrary/PluginLibraryitem whoseRelativePathdoes not already point inside_RelativeAppBundlePathso the rest of the iOS SDK pipeline (codesign, layout, mlaunch deploy) treats it like any other native dependency. Validated on a .NET 11 MAUI iOS Simulator app under VS Code: the dylib is now signed intoSampleMAUI.app/, the CoreCLR remote debugger attaches, and breakpoints fire.