-
Notifications
You must be signed in to change notification settings - Fork 94
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
How to get path to obj folder from type provider? #376
Comments
cc @nosami TBH I don't have any specific recommendation for this - in general type providers don't get this kind of project-build information though they can "work it out". However you're correct in this case the "obj" folder would be It may be better for the type provider to take a static parameter. Or simply search recursively for the output under the project directory (though sometimes it is out of the project directory of course.) |
A couple of easier solutions that I can think of....
|
I think this can be tricky to configure. For example: we have different output path on CI and dev workstations.
Same problem here as I said above.
No it doesn't work anymore. We could also add build task that copies I would like to get the most simple solution, without any additional changes in build or project configuration. Otherwise, we will be forced to add this for every project (we have about 20 android library projects in our solution). |
@dellis1972 Do you have any suggestions? |
We are hopefully going to change direction with regards to the Resource.designer.cs in Xamarin.Android. We are hopeful that by generating a designer assembly (which is just IL ) this will remove the need for the Type Provider. In the mean time for .net 6 you might be able to set
|
I think this is might be used as temporary solution. |
Hello. I tried to build app with I see strange warning in build output: Referenced assembly '/Users/nikolay/.nuget/packages/xamarin.android.fsharp.resourceprovider/1.0.1/lib/monoandroid81/Xamarin.Android.FSharp.ResourceProvider.Runtime.dll' has assembly level attribute 'Microsoft.FSharp.Core.CompilerServices.TypeProviderAssemblyAttribute' but no public type provider classes were found
]]] It seems that |
Closing as the TPSDK doesn't have any specific functionality related to finding the 'obj' directory |
I am interested in fix
Xamarin.Android.FSharp.ResourceProvider
for .Net 6.Xamarin.Android uses code generation to access any resources (e.g. images, styles and other). It generates
Resource.designer.cs
file.Xamarin.Android.FSharp.ResourceProvider
compilesResources.designer.cs
file into assembly to give access to resources from F# code.Since .Net 6 this file moved from
./Resources/Resource.designer.cs
to./obj/Debug/net6.0-android/Resource.designer.cs
. I have no idea how to correctly newResource.designer.cs
path from type provider considering that path may be specified inIntermediateOutputPath
variable.The text was updated successfully, but these errors were encountered: