@@ -185,18 +185,6 @@ impl CSProjectMonoBuilder {
185
185
186
186
let aot = self . aot ;
187
187
188
- fs:: write (
189
- self . dir . join ( "rd.xml" ) ,
190
- format ! (
191
- r#"<Directives xmlns="http://schemas.microsoft.com/netfx/2013/01/metadata">
192
- <Application>
193
- <Assembly Name="{name}">
194
- </Assembly>
195
- </Application>
196
- </Directives>"#
197
- ) ,
198
- ) ?;
199
-
200
188
let maybe_aot = match aot {
201
189
true => format ! ( "<WasmBuildNative>{aot}</WasmBuildNative>" ) ,
202
190
false => String :: new ( ) ,
@@ -208,13 +196,11 @@ impl CSProjectMonoBuilder {
208
196
<PropertyGroup>
209
197
<TargetFramework>net9.0</TargetFramework>
210
198
<RuntimeIdentifier>wasi-wasm</RuntimeIdentifier>
211
-
212
- <TargetOs>wasi</TargetOs>
199
+ <OutputType>Library</OutputType>
213
200
{maybe_aot}
201
+ <RunAOTCompilation>{aot}</RunAOTCompilation>
214
202
<WasmNativeStrip>false</WasmNativeStrip>
215
- <IsBrowserWasmProject>false</IsBrowserWasmProject>
216
203
<WasmSingleFileBundle>true</WasmSingleFileBundle>
217
-
218
204
<RootNamespace>{name}</RootNamespace>
219
205
<ImplicitUsings>enable</ImplicitUsings>
220
206
<Nullable>enable</Nullable>
@@ -227,32 +213,27 @@ impl CSProjectMonoBuilder {
227
213
</PropertyGroup>
228
214
229
215
<ItemGroup>
230
- <NativeLibrary Include=\" {camel}_component_type.o\" />
216
+ <NativeFileReference Include=\" {camel}_component_type.o\" Condition= \" Exists('{camel}_component_type.o') \" />
231
217
</ItemGroup>
232
218
233
- <ItemGroup>
234
- <RdXmlFile Include=\" rd.xml\" />
235
- </ItemGroup>
236
219
"
237
220
) ;
238
221
239
- if self . aot {
240
- fs:: write (
241
- self . dir . join ( "nuget.config" ) ,
242
- r#"<?xml version="1.0" encoding="utf-8"?>
243
- <configuration>
244
- <config>
245
- <add key="globalPackagesFolder" value=".packages" />
246
- </config>
247
- <packageSources>
248
- <!--To inherit the global NuGet package sources remove the <clear/> line below -->
249
- <clear />
250
- <add key="nuget" value="https://api.nuget.org/v3/index.json" />
251
- <add key="dotnet9" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet9/nuget/v3/index.json" />
252
- </packageSources>
253
- </configuration>"# ,
254
- ) ?;
255
- }
222
+ fs:: write (
223
+ self . dir . join ( "nuget.config" ) ,
224
+ r#"<?xml version="1.0" encoding="utf-8"?>
225
+ <configuration>
226
+ <config>
227
+ <add key="globalPackagesFolder" value=".packages" />
228
+ </config>
229
+ <packageSources>
230
+ <!--To inherit the global NuGet package sources remove the <clear/> line below -->
231
+ <clear />
232
+ <add key="nuget" value="https://api.nuget.org/v3/index.json" />
233
+ <add key="dotnet9" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet9/nuget/v3/index.json" />
234
+ </packageSources>
235
+ </configuration>"# ,
236
+ ) ?;
256
237
257
238
if self . clean_targets {
258
239
let mut wasm_filename = self . dir . join ( name) ;
0 commit comments