Bug 286117 - lang/dotnet-host: allowing building on i386
Summary: lang/dotnet-host: allowing building on i386
Status: Closed Not Accepted
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Gleb Popov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-04-15 16:14 UTC by Mikhail Teterin
Modified: 2025-04-16 06:00 UTC (History)
0 users

See Also:
arrowd: maintainer-feedback+


Attachments
Allow building on i386 (2.14 KB, patch)
2025-04-15 16:14 UTC, Mikhail Teterin
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Mikhail Teterin freebsd_committer freebsd_triage 2025-04-15 16:14:40 UTC
Created attachment 259589 [details]
Allow building on i386

Upstream's code allows for 32-bit (x86) builds on other operating systems. This patch will allow building it on FreeBSD as well.

The actual lang/dotnet will be tougher, because there are no readily available bootstrap binaries (yet).
Comment 1 Gleb Popov freebsd_committer freebsd_triage 2025-04-15 16:18:15 UTC
Well, until we get bootstraps for i386 I don't think we should push this one.
Comment 2 Mikhail Teterin freebsd_committer freebsd_triage 2025-04-15 16:24:11 UTC
(In reply to Gleb Popov from comment #1)
> Well, until we get bootstraps for i386 I don't think we should push this one.

Doesn't this make it a chicken-and-egg problem? Until the dotnet-host supports i386, why would anyone bother creating boostraps for i386 -- and how would they do it, even if they wanted to?
Comment 3 Gleb Popov freebsd_committer freebsd_triage 2025-04-15 16:26:49 UTC
(In reply to Mikhail Teterin from comment #2)
dotnet-host has nothing to do about producing bootstraps. It is just a port that deduplicates the dotnet executable between lang/dotnet8 and lang/dotnet
Comment 4 Mikhail Teterin freebsd_committer freebsd_triage 2025-04-15 17:47:07 UTC
(In reply to Gleb Popov from comment #3)
> It is just a port that deduplicates the dotnet executable between lang/dotnet8 and lang/dotnet

Ok... But if it is a dependency for both of those, then making it build on i386 would be the first -- easy -- step to making the dependents build on i386, no?

Who would provide the necessary boostrapping, though? Would it be the upstream maintainers -- and should I try to make them accept my changes to cmake-files?
Comment 5 Gleb Popov freebsd_committer freebsd_triage 2025-04-15 18:06:43 UTC
I'd recommend creating a working bootstrap first. Then once you get a proof that it works you can approach upstream with all patches you generated.
Comment 6 Mikhail Teterin freebsd_committer freebsd_triage 2025-04-15 19:05:21 UTC
By the way, why is the compiled executable dotnet installed into ${PREFIX}/share? 

According to hier(7), share/ is for architecture-independent files -- an ELF-binary does not belong, does it?
Comment 7 Gleb Popov freebsd_committer freebsd_triage 2025-04-16 06:00:06 UTC
I guess the description is a bit dated and does not reflect the reality anymore. share/foo is now more "arbitrary files belonging to foo".

Let's close this PR for now until all necessary porting work is done upstream.