summaryrefslogtreecommitdiff
path: root/haskell/cabal-lib.html
diff options
context:
space:
mode:
Diffstat (limited to 'haskell/cabal-lib.html')
-rw-r--r--haskell/cabal-lib.html20
1 files changed, 3 insertions, 17 deletions
diff --git a/haskell/cabal-lib.html b/haskell/cabal-lib.html
index 90bab1c..9f93c19 100644
--- a/haskell/cabal-lib.html
+++ b/haskell/cabal-lib.html
@@ -46,7 +46,7 @@ ghci> print "hi"
Variable not in scope: print :: base-4.17.2.0:GHC.Base.String -> t
ghci>
</code></pre>
-<p>I mean, that doesn't look good, doesn't it?</p>
+<p>I mean, that doesn't look good, does it?</p>
<p>And if that did not scare you enough, suppose that in the future, you want to use a newer version of <code>brick</code> and try to install that using <code>cabal install --lib brick</code> again.
What you'll see is this:</p>
<pre><code>$ cabal install --lib brick-1.9
@@ -56,22 +56,8 @@ may break other packages. Use --force-reinstalls to proceed anyway. Packages:
brick
</code></pre>
<p>(I simulated the situation by installing an older version instead. I can't time-travel, unfortunately.)</p>
-<p>Or suppose that you now also want to use another library, say <code>eigen</code>:</p>
-<pre><code>$ cabal install --lib eigen
-Resolving dependencies...
-Error: cabal: Could not resolve dependencies:
-[__0] next goal: brick (user goal)
-[__0] rejecting:
-brick-1.10/installed-1f76dfaf75736c0f6e2a4a2cf992bb12da05f6bbc7985f9787547739947e4696
-(package is broken, missing dependency
-bimap-0.5.0-2ee7565ca29f0edc78a3c8fe09c9eef36c96d08473660eec8a944cef16ac4d86)
-[__0] trying: brick-1.10
-[__1] trying: vty-5.39 (dependency of brick)
-...
-...
-</code></pre>
-<p>The error message is much longer than this, but I cut it off to save some space.
-Apparently it claims our installation of <code>brick</code> is actually broken, despite it working okay in <code>ghci</code>, but in any case this didn't work.</p>
+<p>Another thing that would fail is trying to install a package that is incompatible with the versino of <code>brick</code> you have now &quot;installed&quot;.
+I don't have a good example for this post because I couldn't find a neat pair of incompatible packages that didn't have many other dependencies, but I hope you'll trust me that this will result in the well-known (to seasoned haskellers) cabal dependency resolution errors.</p>
<h2>What happened?</h2>
<p>Note the line printed by <code>ghci</code>:</p>
<pre><code>Loaded package environment from /home/tom/.ghc/x86_64-linux-9.4.7/environments/default