-
Notifications
You must be signed in to change notification settings - Fork 132
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
.NET Source-build instructions #2602
Comments
Hey, @alucryd @loqs @cerebrate @directhex , what documentation would you find helpful? From my point of view, as a maintain for .NET in Fedora, a doc that covers the following would be useful to have:
|
@omajid That's pretty much what I would ask for, thanks for making this list. Speaking from past experience, compatibility with nspawn and capability needs (if any) would be nice to have as well, this was troublesome in the 2.x era. And the dependency version information as well, minimum and/or maximum version, like how the current dotnet releases don't work with lttng-ust >= 2.13.0. |
Also what about OS'es that are not supported atm? Like for example, FreeBSD, we're able to crosscompile working SDK, then native build SDK using that as bootstrap - would it be possible to use the same path using source-build? I've tried that, but at some stage it was missing runtime's nupkg specific for FreeBSD - any info how to also include those into tarball for offline build would be nice for ex. :) |
FYI, I tried building 6.0 using the instructions on the installer repository, and it fails during the runtime compilation, the errors seem to stem from @omajid I see you ran into this before, I'll try disabling package validation like you did. |
Disabling package validation allowed it to progress further, but it still crashed after an hour and a half of compilation... Segfault while building aspnetcore. @omajid can you get past aspnetcore on fedora? |
On Fedora 34, the build works end to end. On 35, my builds are hanging (not crashing, just hanging) while trying to build aspnetcore. The actual hang appears to be in the crossgen process. |
Got it. What versions of lttng-ust do you have on 34 vs 35? Wondering if that's the culprit, I'll try to create a lttng-ust2.12 compat package here. Edit: Nevermind, looked it up on repology. Looks like even using 2.12.2 might not cut it, I'll start with 2.12.0. |
Fedora 34 is lttng-ust-2.12.0-4.fc34.x86_64. Fedora 35 is lttng-ust-2.12.2-5.fc35.x86_64. If it's really lttng, perhaps a |
Ah that could be a solution indeed, I'll give it a try later. For now I built 2.12.0 and the dotnet build is almost 2 hours in, way past aspnetcore so fingers crossed. Hopefully COMPlus_LTTng does allow it to build with/against regular lttng-ust here, and when bootstrapping 6.0 with our own dotnet is a thing, I'll be able to get rid of the compat lttng-ust. |
I was expecting to find a |
This comment has been minimized.
This comment has been minimized.
asbjornu - Starting in 6.0, source-build is going to be produced from dotnet/installer. You can use the 6.0.101 tag to build .NET 6 from. You can refer to the building instructions. |
Does this mean I have to repeat the multi-week effort that went into Homebrew/homebrew-core#60929? What are the big differences between building the |
The major difference is that the two-stage build is no longer required. Instead of |
For .NET Core 3.1 and .NET 5, you need to use the appropriate branch of the source-build repo to build .NET from source. For .NET 6, you need to use installer repo to build from source. Perhaps it helps if you just treat it as if the build system moved from source-build to installer for .NET 6.0? @crummel 's reply goes into detail on why we made the changes and what the details of the change are, but if you are looking to consume .NET 6, the short version is that you need to use the installer repo; the source-build repo simply doesn't build .NET anymore. |
@alucryd |
Meh, that's too bad. Do you have a way to force lttng-ust to 2.12.0 on 35? The build succeeded with 2.12.0 here, I'll give 2.12.2 a try later then so we can confirm whether it's the culprit. |
@omajid Oh well, our clang was updated to 13 yesterday, which caused a lot of build errors in the runtime. Unlike what the readme seems to indicate, Edit: Going back to clang 12 gets past the aspnetcore hang indeed. |
Thanks for the pointers, @alucryd ! dotnet/runtime#61442 should fix the Thanks for the tip on clang 12 vs 13. Looking at Fedora 35, we have a compatiblity package for clang 12 - there are libraries, but not the actual compiler itself. I am going to build llvm/clang 12 from source and see if that works. |
Excuse me, looks like a typo - the link is to the tag/v6.0.100, but the text is 6.0.101. 101 is inaccessible without credentials:
|
@DmitryJustDmitry, thanks for providing that essential piece of information! With version |
AFAIK, the 6.0.101 release accidentally included some non-public URLs (it wasn't really accidental, it was just a bit-by-bit copy of how the internal builds are done, I think). It might be worth trying to apply dotnet/installer#12852 on the local checkout of 6.0.101 to see if that fixes it. |
@omajid, thanks, but if |
Alas, |
Coming back to this, I think we should update dotnet/installer's readme to point to the dotnet/source-build readme for instructions on how to build source build. The installer readme's instructions aren't the most up-to-date. Either that or we should move all the instructions to installer and point to them from source-build. The current set of instructions we have are different between the repos. This goes for |
There should be easily accessible instructions for building .NET 6.0 from source in the dotnet/installer readme.
The instructions should address everything you need to build .NET from source, including dependencies. Ideally, this would be something we can point Linux distros and package maintainers to for instructions on how to build .NET for their distro.
The text was updated successfully, but these errors were encountered: