-
Notifications
You must be signed in to change notification settings - Fork 507
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
Binding projects don't work properly when used as project references #10148
Comments
I believe the problem is that our MSBuild logic doesn't have support for design-time builds: https://github.com/dotnet/project-system/blob/main/docs/design-time-builds.md#what-is-a-design-time-build |
Ref: xamarin#10148
Some very early and incomplete work: rolfbjarne@216aeca |
I'm seeing exactly the same with net7.0 and a macOS binding library. |
I worked around this by referencing the binding project assembly directly, which I build in a separate solution. This allows Intellisense to work but does require a bit of gynmastics in my automated build process. |
This is best done as part of making binding projects compile directly on Windows (#16611), because we don't want to do design-time builds remotely. |
My workaround is:
|
@microspaze it's not always enough for the IntelliSense to work properly at all times. On top of that the referenced framework/lib is often not updated without a hard clean (delete obj/bin) leading to unrecognized selectors. My solution for now is to copy the intermediate generated files under |
@cho-trackman But I had nerver faced with the unrecognized selectors for referenced framework/lib issue. It works fine for me on my currently working-on project: IJKPlayer.Binding |
So this is still an issue in .NET MAUI (as I presume it's perhaps part of VS studio's IntelliSense?) and I was wondering if there is any movement on this. Otherwise, could it be moved to the .NET MAUI repository as an issue? Using the .dll as a reference is working for now, but I know some developers would like to keep their solutions together, for easier maintenance and transparency. |
Yes, it's still an issue.
I've started working on this, but it will take a while, because it's not very high priority and I ran into some complications. I'm hoping to get it done for .NET 9, but no promises.
No, because it's not an issue in MAUI specifically, but in this repository. |
Glad to hear its in the pipeline, thanks for the quick reply @rolfbjarne |
Repro:
Any API used from the bindings-framework-test project are squiggly red, and intellisense doesn't work:
This is something we have to fix in our msbuild logic somewhere.
Note that building the solution actually works, this just affects editing experience in the IDE (intellisense doesn't work).
A potential workaround is to build the binding project separately, and then just reference the binding assembly (.dll) in the main project instead.
The text was updated successfully, but these errors were encountered: