Gentoo Archives: gentoo-dev

From: Georg Rudoy <0xd34df00d@×××××.com>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] Re: [PR] ivy, mvn, sbt, gradle builders improvement for ebuild development
Date: Mon, 20 Apr 2020 21:05:11
Message-Id: CAGbUWSKQQ9Fx3mi7BkYhCQY17K4E6WX6G3yXmat3rSJjw6hqNA@mail.gmail.com
In Reply to: Re: [gentoo-dev] Re: [PR] ivy, mvn, sbt, gradle builders improvement for ebuild development by Michael Orlitzky
1 пн, 20 апр. 2020 г. в 16:51, Michael Orlitzky <mjo@g.o>:
2 > Except that Haskell as a research language tends to inspire more "fire and forget" software.
3
4 I'd say this is not the case for the last few years, but that's maybe
5 just my own impression from interacting with
6
7 > (And Haskell works better in Gentoo than anywhere else, in my opinion.)
8
9 Totally agreed here. That's one of the main reasons I run Gentoo
10 (especially before dev-haskell/stack emerged upstream a few years
11 ago).
12
13 > You package each dependency as a separate package. If there's a conflict
14 > between two packages, then... you can't have those two packages
15 > installed together. When that happens, you alert upstream, and try to
16 > convince them to be more lenient with their dependencies (again, nothing
17 > Haskell-specific here). Sometimes that involves code changes, but often
18 > it's just an edit to the cabal file. Many people follow either semver or
19 > the PVP (https://pvp.haskell.org/) which keeps things from getting too
20 > far out of control.
21
22 I'd say the Haskell-specific thing is the presence of stackage LTS
23 releases that people tend to stick to. For instance, beam-postgres
24 disappeared in recent LTSes, so some projects of mine are stuck on
25 older LTSes (adding that to extra-deps was a pain for reasons I don't
26 remember at the moment), while the others can happily use the new
27 ones. Libraries incompatibilities are just a matter of time in this
28 case.
29
30 Sure, hacking on .cabal/package.yaml is one way to solve this, but I
31 wasn't sure it's reasonably robust in the long run.
32
33 Anyway, thanks for your feedback. This probably means I should stop
34 thinking about the general case and maybe start playing around with
35 packaging stuff, and then seeing where it breaks.
36
37 > If upstream absolutely insists on minor-version dependencies, then you
38 > either tolerate it conflicting with everything else, or leave it out of
39 > the tree. You probably shouldn't even be packaging a library whose API
40 > is distinguishable across minor releases.
41
42 That's not a matter of just the API per se. Even the library file name
43 encodes its deps in its name (if I understand correctly, that's the
44 hash in libHSregex-base-0.94.0.0-541xQVwwNRiBGjsNKmOPoy-ghc8.6.5.so
45 for example). Personally I just find it hard to reason about this sort
46 of dependencies management. But, again, I should probably avoid trying
47 that and just jump head first to packaging.
48
49 > I don't see anything fundamentally different here
50 > between Haskell (or Go, or...)
51
52 Dunno much about Go and I don't have a single Go package locally to
53 check. Do they do static or dynamic linking with the deps, for
54 instance? What's the language model wrt API and linking?
55
56 > and C.
57
58 More stable API (and ABI).
59
60
61 --
62 Georg Rudoy

Replies