Skip to content

Commit

Permalink
[src] Improve the generated project files a little bit. (xamarin#17812)
Browse files Browse the repository at this point in the history
* Use the right TFM.
* Compute the right assembly name.
  • Loading branch information
rolfbjarne authored Mar 17, 2023

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
1 parent f37c86b commit 97d1eac
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/Makefile
Original file line number Diff line number Diff line change
@@ -1352,6 +1352,7 @@ define DotNetProjectFiles
$(DOTNET_BUILD_DIR)/projects/$(1)/$(1).csproj: dotnet.tmpl.csproj Makefile $$(wildcard $(CURDIR)/*.sources)
@mkdir -p $$(dir $$@)
@sed \
-e 's*%DOTNET_TFM%*$(DOTNET_TFM)*' \
-e 's*%PLATFORM%*$(1)*' \
-e 's*<!--%FILES%-->*$$(foreach file,$$($(2)_DOTNET_SOURCES),<Compile Include="../../../../$$(file)" Link="sources/$$(file)" />)*' \
-e 's*<!--%APIS%-->*$$(foreach file,$$($(2)_DOTNET_APIS),<None Include="../../../../$$(file)" Link="apis/$$(file)" />)*' \
4 changes: 2 additions & 2 deletions src/dotnet.tmpl.csproj
Original file line number Diff line number Diff line change
@@ -3,10 +3,10 @@
<!-- This is a project file to load in the IDE to get code completion, etc. It's not used for building the product assemblies, that happens in the makefile -->
<PropertyGroup>
<_TargetPlatform>%PLATFORM%</_TargetPlatform>
<TargetFramework>net6.0</TargetFramework>
<TargetFramework>%DOTNET_TFM%</TargetFramework>
<TargetFrameworkIdentifier>.NETCoreApp</TargetFrameworkIdentifier> <!-- this line shouldn't be necessary, but VSMac on one of my machines won't load the project otherwise -->
<OutputType>Library</OutputType>
<AssemblyName>Xamarin.iOS</AssemblyName>
<AssemblyName>Microsoft.%PLATFORM%</AssemblyName>
<SignAssembly>true</SignAssembly>
<AssemblyOriginatorKeyFile>..\..\..\..\..\product.snk</AssemblyOriginatorKeyFile>
<LangVersion>latest</LangVersion>

0 comments on commit 97d1eac

Please sign in to comment.