-
Notifications
You must be signed in to change notification settings - Fork 511
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
[MMP] Allow resolving assemblies to the ones passed in command line args #3575
Conversation
I think this should be cherry-picked to 15.7, so the --recursive-directories option is not surfaced to anyone. |
I agree on removing --recursive-directories in 15.7. I am hesitant to add the
bit since that changes behavior, and mmp behavior is non-trivial and not testing as much as I'd like. Though it is likely fine. |
build |
#if MMP | ||
resolver.RecursiveSearchDirectories.AddRange (Driver.RecursiveSearchDirectories); | ||
CommandLineAssemblies = RootAssemblies, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is what actually makes the MonoMacResolver actually resolve to assemblies given as arguments. I can add another list to be checked, but I think this is fine.
- This code path is
--runregistrar
specific - The other bit of code which sets this is inside
Pack
, which is the other hit when the action is not--runregistrar
xamarin-macios/tools/mmp/driver.cs
Line 513 in 3113c5d
if (action == Action.RunRegistrar) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree that this is the correct fix at face value. And I'm totally cool with it going into master.
I've just been burned enough times with last minute behavior changes in release branches that i'm hesitant.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Want me to split the PR into 2 commits? One which reverts recursive search dirs and one which implements this?
So we can backport the revert safely?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would be grand. ❤️
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
This is what actually makes the MonoMacResolver actually resolve to assemblies given as arguments. This mirrors the behaviour of Pack, which is called on the other code-path (that's not --runregistrar) https://github.com/xamarin/xamarin-macios/blob/3113c5d2b5cca730372177e9b1cee17062a959ff/tools/mmp/driver.cs#L513
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's a much better approach :) I did not like that new option - too many ways to misuse it
Note: this must be in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Build failure |
@chamons I think that before (unreleased) 15.7 it was not allowed to have more than one root assembly - so whatever behaviour is new (and can't break existing apps), right ? |
I think so @spouliot but I'm not 100% certain without some archaeology. |
This change is only when passing --runregistrar to mmp, which is an internal option: xamarin-macios/tools/mmp/driver.cs Lines 355 to 360 in 040461b
Thus we shouldn't have to care for backwards compatibility. |
Alright, then I can stop being paranoid (in this case). |
Strange...
Trying one more time before filing maccore issues. |
build |
Build failure |
build |
Build failure |
Test failures are random and knwon: |
…rgs (xamarin#3575) * [MMP] Revert recursive search dirs changes * [MMP] Allow resolving assemblies to the ones passed in command line args This is what actually makes the MonoMacResolver actually resolve to assemblies given as arguments. This mirrors the behaviour of Pack, which is called on the other code-path (that's not --runregistrar) https://github.com/xamarin/xamarin-macios/blob/3113c5d2b5cca730372177e9b1cee17062a959ff/tools/mmp/driver.cs#L513
#3651 for d15-7 |
…rgs (#3575) (#3651) * [MMP] Revert recursive search dirs changes * [MMP] Allow resolving assemblies to the ones passed in command line args This is what actually makes the MonoMacResolver actually resolve to assemblies given as arguments. This mirrors the behaviour of Pack, which is called on the other code-path (that's not --runregistrar) https://github.com/xamarin/xamarin-macios/blob/3113c5d2b5cca730372177e9b1cee17062a959ff/tools/mmp/driver.cs#L513
This reverts the recursive directory search commit and allows resolving assemblies from the ones passed.