Skip to content

Conversation

@radical
Copy link
Member

@radical radical commented Sep 17, 2021

Use $(IntermediateAssembly) when gathering files for wasm build.

Fixes dotnet/runtime#59255 .

@ghost ghost added the Area-AspNetCore RazorSDK, BlazorWebAssemblySDK, dotnet-watch label Sep 17, 2021
radical added a commit to radical/runtime that referenced this pull request Sep 17, 2021
.. and update BlazorOverwrite.targets to include the fix from
dotnet/sdk#21104 .
Copy link
Member

@SteveSandersonMS SteveSandersonMS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense based on what I saw before. Will this make it able to pick up DllImport from ProjectReferences too (if it didn’t already)?

@radical
Copy link
Member Author

radical commented Sep 17, 2021

Will this make it able to pick up DllImport from ProjectReferences too (if it didn’t already)?

Can you elaborate on this?

@lewing lewing changed the title BlazorWasm: Fix including the target assembly [release/6.0.1xx-rc]BlazorWasm: Fix including the target assembly Sep 17, 2021
@lewing lewing changed the title [release/6.0.1xx-rc]BlazorWasm: Fix including the target assembly [release/6.0.1xx-rc2]BlazorWasm: Fix including the target assembly Sep 17, 2021
@SteveSandersonMS
Copy link
Member

I just wanted to check that the issue that prevented it seeing your main assembly didn’t also prevent it from seeing the assemblies of other projects in your solution.

We know the feature works for PackageReference dependencies, but does it work for ProjectReference dependencies? Has that been tried out?

Hope that makes sense!

@lewing lewing changed the title [release/6.0.1xx-rc2]BlazorWasm: Fix including the target assembly [release/6.0.1xx-rc2] BlazorWasm: Fix including the target assembly Sep 17, 2021
@radical
Copy link
Member Author

radical commented Sep 17, 2021

I just wanted to check that the issue that prevented it seeing your main assembly didn’t also prevent it from seeing the assemblies of other projects in your solution.

Yes, dllimports in referenced projects would get scanned for pinvokes during the native build. Currently, the native library won't get automatically included in the app project though. IOW, you would need an explicit <NativeFileReference Include="/path/to/native/lib" /> in the app project.
But we are trying to figure out how the experience could be different.

@SteveSandersonMS
Copy link
Member

SteveSandersonMS commented Sep 20, 2021

IOW, you would need an explicit <NativeFileReference Include="/path/to/native/lib" /> in the app project.

Package authors could already fix that themselves by including some MSBuild in their package that adds a <NativeFileReference> itemgroup entry to any project that consumes the package. Maybe we could make that easier for them one day, but for 6.0, I think we already have the necessary capabilities.

@lewing
Copy link
Member

lewing commented Sep 20, 2021

@marcpopMSFT what is the process to get this in rc2 now?

@lewing lewing merged commit dd19efb into dotnet:release/6.0.1xx-rc2 Sep 20, 2021
@radical radical deleted the wasm-fix-native-ref branch September 20, 2021 18:14
radical added a commit to radical/sdk that referenced this pull request Sep 21, 2021
radical added a commit that referenced this pull request Sep 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area-AspNetCore RazorSDK, BlazorWebAssemblySDK, dotnet-watch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants