Skip to content
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

Use the righ ghc-9.4.8 tarball for Debian Linux without version #150

Closed

Conversation

marinelli
Copy link

I think we have the wrong tarball specified for ghc-9.4.8 for Debian GNU/Linux (x64) when the version of the distro is unknown. We use deb11 since version 9.4.1:

$ cat ghcup-0.0.8.yaml | yq '.ghcupDownloads .GHC | map_values (.viArch.A_64.Linux_Debian.unknown_versioning)' | tail 
9.4.3: *ghc-943-64-deb11
9.4.4: *ghc-944-64-deb11
9.4.5: *ghc-945-64-deb11
9.4.6: *ghc-946-64-deb11
9.4.7: *ghc-947-64-deb11
9.4.8: *ghc-948-64-deb9
9.6.1: *ghc-961-64-deb11
9.6.2: *ghc-962-64-deb11
9.6.3: *ghc-963-64-deb11
9.8.1: *ghc981-x86_64-deb11

@hasufell
Copy link
Member

This is not a mistake. We want to use the oldest tarball (highest glibc compatibility) if we can't find out the distro version.

This was discussed here: #127 (comment)

@hasufell hasufell closed this Nov 12, 2023
@marinelli
Copy link
Author

This is not a mistake. We want to use the oldest tarball (highest glibc compatibility) if we can't find out the distro version.

This was discussed here: #127 (comment)

The sentences there seems to be a bit contradictory, but maybe I do not understand the reasoning made there.

As you wrote at point 1, I have problems installing ghc on Debian GNU/Linux testing/unstable due to libtinfo version, it defaults to deb9.

I do not really think it's a good idea to set it to an old version, that is also discontinued as a Debian release [1]. There're distros, like gLinux (used in Google), that are based on Debian Testing.

But I also think that the approach used is wrong.
If we have some predicate P(C1, C2, ..., Cn) to identify the platform version, where every condition Ci is the result of reading some information in the running OS, why would I default to the oldest version if we do not have enough information to choose the right one?
For an old platform version, given that is old and more stable, the conditions Ci, encoded in ghcup, will be sufficient to identify the right platform.
On the other hand, for an unreleased version, the Ci conditions will not be enough anymore to identify the proper platform (maybe due to a new soname for a library). In this case I would use, by default, the latest available platform, it might have a chance to be compatible with the running OS.

[1] https://wiki.debian.org/LTS

@hasufell
Copy link
Member

I have problems installing ghc on Debian GNU/Linux testing/unstable due to libtinfo version, it defaults to deb9.

Can you paste the contents of /etc/os-release?

@hasufell
Copy link
Member

Debian testing/unstable has the following os-release:

PRETTY_NAME="Debian GNU/Linux trixie/sid"
NAME="Debian GNU/Linux"
VERSION_CODENAME=trixie
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"

It's missing a VERSION field.

@hasufell
Copy link
Member

But I also think that the approach used is wrong.

As explained in the linked comment, you're simply trading glibc issues with ncurses/tinfo issues. Which ones are more prominent may depend on the distro.

hasufell added a commit that referenced this pull request Nov 12, 2023
@hasufell
Copy link
Member

#151

@hasufell
Copy link
Member

Fixed

@marinelli
Copy link
Author

Fixed

Nice! But I think you run too fast :)

I'll add a couple of comments there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants