Skip to content

Conversation

arrowd
Copy link
Contributor

@arrowd arrowd commented Apr 6, 2024

The full problem context: https://reviews.freebsd.org/D44560

This change tries to address it for the native FreeBSD case. The Linuxulator case can hopefully be fixed by installing /compat/linux/etc/dotnet/install_location.

@sec @Thefrank can you look into this?

@ghost ghost added the area-Host label Apr 6, 2024
@arrowd
Copy link
Contributor Author

arrowd commented Apr 6, 2024

@dotnet-policy-service agree

@dotnet-policy-service dotnet-policy-service bot added the community-contribution Indicates that the PR has been added by a community member label Apr 6, 2024
@Thefrank
Copy link
Contributor

Thefrank commented Apr 6, 2024

LGTM

As an aside: /etc/dotnet/install_location file did also work for FreeBSD. I can only find documentation of it in design docs: https://github.com/dotnet/designs/blob/main/accepted/2020/install-locations.md so this may have changed.

@arrowd
Copy link
Contributor Author

arrowd commented Apr 6, 2024

On FreeBSD the /etc is reserved for the base system usage. Third-party software should use a prefix path called LOCALBASE which defaults to /usr/local.

@Thefrank
Copy link
Contributor

Thefrank commented Apr 6, 2024

Fair point. That file would not make sense for a FreeBSD port.

oooh! That differential also has a working powershell port from "zirias" which means I can close out 3 upstream PRs for getting FreeBSD added to the 3 powershell repos. Happy to see someone get that over the finish line

@sec
Copy link
Contributor

sec commented Apr 8, 2024

@arrowd LGTM. IIRC setting DOTNET_ROOT also works, as I use it on my machines, but your fix is more elegant.

@Thefrank
Copy link
Contributor

Thefrank commented Apr 8, 2024

Looking at this and according to hier(7), share is for architecture-independent files. I am not sure this location is a good fit for dotnet, however this specific file is actually arch agnostic as any arch of dotnet will look for it. As you are the port maintainer, I will defer to you where you want the files. hier(7) is more guidance than law as per the notes.

@arrowd arrowd force-pushed the freebsd-default-install-dir branch from 6301bed to d0bd7c7 Compare May 5, 2024 14:48
@arrowd
Copy link
Contributor Author

arrowd commented May 5, 2024

Bump. Can we get this in?

@agocke
Copy link
Member

agocke commented May 5, 2024

@elinor-fung for review

@elinor-fung elinor-fung merged commit 4585e00 into dotnet:main May 6, 2024
@elinor-fung
Copy link
Member

Apologies for the delay. Thanks, @arrowd!

michaelgsharp pushed a commit to michaelgsharp/runtime that referenced this pull request May 9, 2024
Ruihan-Yin pushed a commit to Ruihan-Yin/runtime that referenced this pull request May 30, 2024
@github-actions github-actions bot locked and limited conversation to collaborators Jun 6, 2024
@arrowd arrowd deleted the freebsd-default-install-dir branch June 23, 2024 19:28
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-Host community-contribution Indicates that the PR has been added by a community member os-freebsd FreeBSD OS
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants