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

Fix 'runtimeconfig.template.json : warning XA0101: @(Content) build action is not supported' warnings. #135

Conversation

ChristophSchmidpeter
Copy link
Contributor

@ChristophSchmidpeter ChristophSchmidpeter commented May 9, 2023

Fix warnings of the form

runtimeconfig.template.json : warning XA0101: @(Content) build action is not supported

when (initially) building the repository.

@ChristophSchmidpeter ChristophSchmidpeter changed the title Fix 'runtimeconfig.template.json : warning XA0101: @(Content) build a… Fix 'runtimeconfig.template.json : warning XA0101: @(Content) build action is not supported' warnings. May 9, 2023
@ChristophSchmidpeter
Copy link
Contributor Author

ChristophSchmidpeter commented May 9, 2023

Is Content -> None correct here, or is Content needed here, and I need to exclude the runtimeconfig.template.json files conditionally for net7.0-android instead?

@edgarfgp
Copy link
Member

edgarfgp commented May 9, 2023

Is Content -> None correct here, or is Content needed here, and I need to exclude the runtimeconfig.template.json files conditionally for net7.0-android instead?

I think it is ok to set it to None for now. This was introduced to test Avalonia Web support in #124 (I need to tweak that PR to make it work)

@edgarfgp edgarfgp merged commit 8267de7 into fabulous-dev:main May 9, 2023
@ChristophSchmidpeter
Copy link
Contributor Author

ChristophSchmidpeter commented May 9, 2023

@edgarfgp I wonder why the build system complains when using Content. But only for Android ( "TargetFramework=net7.0-android" in warning). Having multi-target project nowadays, this seems to be a bug, or no? Or is this warning triggered for good reason? If not, I could open a ticket in e.g. dotnet/runtime

@edgarfgp
Copy link
Member

edgarfgp commented May 9, 2023

Is Content -> None correct here, or is Content needed here, and I need to exclude the runtimeconfig.template.json files conditionally for net7.0-android instead?

I think it is ok to set it to None for now. This was introduced to test Avalonia Web support in #124 (I need to tweak that PR to make it work)

@edgarfgp I wonder why the build system complains when using Content. But only for Android ( "TargetFramework=net7.0-android" in warning). Having multi-target project nowadays, this seems to be a bug, or no? Or is this warning triggered for a good reason? If not, I could open a ticket in e.g. dotnet/runtime

@ChristophSchmidpeter I think this is because we are using a SingleProject with some MSBuild magic, While AvaloniaUI has a separate project for each platform. So it won't complain on Android or iOS.

@ChristophSchmidpeter
Copy link
Contributor Author

ChristophSchmidpeter commented May 9, 2023

I see, that sounds most likely. There was some Avalonia single project effort, which might resolve that problem in that case by itself. But that effort seems to be stale at least for now.

I guess using conditions like <ItemGroup Condition="'$(AvaloniaPlatform)' != 'Android'"> or similar might work around the warning on the Web branch in the meantime (unless there is a better way to do so ofc.).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants