Current Stride.Native.targets file prevents from using modern NET MSBuild
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 7.8k
- Forks
- 1.2k
- Avg merge
- 2d 17h
- Merged PRs (30d)
- 49
Description
Is your feature request related to a problem? Please describe.
Problem: Currently you can't build an engine using modern MSBuild, because C++/CLI is not supported here. Also Visual C++ is only available on Windows.
# not possible
dotnet build / dotnet msbuild Stride.sln
# instead we use .NET Framework msbuild
msbuild Stride.sln
Cause: When you take a look at Stride.Native.targets file is using WindowsDesktop.vcxproj project contains ONLY EMPTY dllmain file which is included to dedicated native library (e.g. for libstrideaudio.dll, libstridenavigation.dll etc)
Solution
Lines from 131 to 134 in Stride.Native.targets file can be modified to use clang or cmake tool. If implemented correctly that could allow to crosscompile on Linux (in the far future ofc, when Linux platform will be good enough supported) which is usefull for cheaper to execute CI/CD pipelines.
Solution benefits
- No need to install legacy .NET Framework msbuild - you could build an engine using dotnet CLI simply using
dotnet build - Reduction of complexity
- Possibility to use more lightweight editors like VSCode for Stride source debugging
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with sources/native/Stride.Native.targets, especially lines 131–134, and inspect how the WindowsDesktop.vcxproj with its empty dllmain is used when building Stride.sln. Compare the current .NET Framework msbuild path with dotnet build and evaluate the proposed clang or CMake direction; done means the engine builds with modern MSBuild without the legacy .NET Framework msbuild dependency.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cmake, cpp, csharp
- Domain
- build-system
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100