<div dir="ltr"><div dir="ltr"><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">Thanks for the quick response Mikolaj. Sorry for the confusion, with cabal install I did use --lib but accidentally omitted that in my original email. In 9.0.1 this results in a successful compilation but in 9.2.1 it does not thus I believe this is a regression. </div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large"><br></div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">Here's the output I got in 9.2.1:</div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large"><br></div><blockquote style="margin:0 0 0 40px;border:none;padding:0px"><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">bash-3.2$ cabal install vector --lib</div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">Warning: Unknown/unsupported 'ghc' version detected (Cabal 3.4.0.0 supports</div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">'ghc' version < 9.1): /usr/local/bin/ghc is version 9.2.1</div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">Warning: Unknown/unsupported 'ghc' version detected (Cabal 3.4.0.0 supports</div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">'ghc' version < 9.1): /usr/local/bin/ghc is version 9.2.1</div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">Resolving dependencies...</div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">Up to date</div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">bash-3.2$ ghc buggc.hs</div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">[1 of 1] Compiling Main             ( buggc.hs, buggc.o )</div></blockquote><div class="gmail_default" style="font-family:times new roman,serif;font-size:large"><br></div><blockquote style="margin:0 0 0 40px;border:none;padding:0px"><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">buggc.hs:2:1: error:</div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">    Could not find module ‘Data.Vector’</div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">    Perhaps you meant Data.Functor (from base-4.16.0.0)</div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">    Use -v (or `:set -v` in ghci) to see a list of the files searched for.</div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">  |</div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">2 | import Data.Vector</div></blockquote><div class="gmail_default" style="font-family:times new roman,serif;font-size:large"><br></div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large">However I did figure out a workaround: cabal v1-install. </div><div class="gmail_default" style="font-family:times new roman,serif;font-size:large"><br></div><div class="gmail_default" style="font-family:"times new roman",serif"><font size="4">As far as I can tell cabal (v2-) install breaks ghc-pkg and compilation. With cabal (v2-) install the workaround for ghc-pkg is to add the option "</font><span style="font-family:Arial,Helvetica,sans-serif"><font size="4">-f $HOME/.cabal/store/ghc-9.2.1/package.db" to the end of the command "ghc-pkg list". For compilation the workaround is to add "</font></span><span style="font-family:Arial,Helvetica,sans-serif"><font size="4">-package-db $HOME/.cabal/store/ghc-9.2.1/package.db" to the ghc-pkg. I don't understand why it was necessary for  </font></span><span style="font-family:Arial,Helvetica,sans-serif"><font size="4">cabal v2-install</font></span><span style="font-family:Arial,Helvetica,sans-serif"><font size="4"> </font></span><span style="font-size:large;font-family:Arial,Helvetica,sans-serif">to be incompatible with cabal v1-install. Is there a link to any documentation and justification for these incompatible changes?</span></div><div class="gmail_default" style="font-family:"times new roman",serif"><span style="font-family:Arial,Helvetica,sans-serif"><font size="4"><br></font></span></div><div class="gmail_default" style="font-family:"times new roman",serif"><span style="font-family:Arial,Helvetica,sans-serif"><font size="4">Thanks again,</font></span></div><div class="gmail_default" style="font-family:"times new roman",serif"><span style="font-family:Arial,Helvetica,sans-serif"><font size="4">George</font></span></div><div class="gmail_default" style="font-family:"times new roman",serif"><span style="font-family:Arial,Helvetica,sans-serif"><font size="4"><br></font></span></div><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, Oct 30, 2021 at 3:38 PM Mikolaj Konarski <<a href="mailto:mikolaj@well-typed.com">mikolaj@well-typed.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi George,<br>
<br>
Since many versions of cabal, `install` only installs executables, not<br>
libraries, so if that worked for you, you must have had an old version<br>
of cabal.<br>
<br>
Please see <a href="https://github.com/haskell/cabal/issues/6481" rel="noreferrer" target="_blank">https://github.com/haskell/cabal/issues/6481</a> for some<br>
context and to help you find a new workflow that works for you<br>
(ideally, a standard one).<br>
<br>
Kind regards,<br>
Mikolaj<br>
<br>
On Sat, Oct 30, 2021 at 5:40 PM George Colpitts<br>
<<a href="mailto:george.colpitts@gmail.com" target="_blank">george.colpitts@gmail.com</a>> wrote:<br>
><br>
> Thanks Ben!<br>
><br>
> There seems to be a regression in ghc / cabal integration in 9.2.1.<br>
><br>
> In 9.2.1 if I do<br>
><br>
> cabal install vector<br>
><br>
> Compilation of a file containing<br>
><br>
><br>
> import Data.Vector<br>
><br>
><br>
> main = undefined<br>
><br>
><br>
> fails with<br>
><br>
>  Could not find module ‘Data.Vector’<br>
>     Perhaps you meant Data.Functor (from base-4.16.0.0)<br>
>     Use -v (or `:set -v` in ghci) to see a list of the files searched for.<br>
>   |<br>
> 2 | import Data.Vector<br>
>   | ^^^^^^^^^^^^^^^^^^<br>
><br>
> The preceding works on ghc 9.0.1<br>
><br>
> Should I file a bug against Cabal?<br>
><br>
> Thanks<br>
> George<br>
><br>
> On Fri, Oct 29, 2021 at 12:54 PM Ben Gamari <<a href="mailto:ben@well-typed.com" target="_blank">ben@well-typed.com</a>> wrote:<br>
>><br>
>> Hi all,<br>
>><br>
>> The GHC developers are very happy to at long last announce the<br>
>> availability of GHC 9.2.1. Binary distributions, source distributions,<br>
>> and documentation are available at<br>
>><br>
>>     <a href="https://downloads.haskell.org/ghc/9.2.1" rel="noreferrer" target="_blank">https://downloads.haskell.org/ghc/9.2.1</a><br>
>><br>
>> GHC 9.2 brings a number of exciting features including:<br>
>><br>
>>  * A native code generation backend for AArch64, significantly speeding<br>
>>    compilation time on ARM platforms like the Apple M1.<br>
>><br>
>>  * Many changes in the area of records, including the new<br>
>>    `RecordDotSyntax` and `NoFieldSelectors` language extensions, as well<br>
>>    as Support for `DuplicateRecordFields` with `PatternSynonyms`.<br>
>><br>
>>  * Introduction of the new `GHC2021` language extension set, giving<br>
>>    users convenient access to a larger set of language extensions which<br>
>>    have been long considered stable.<br>
>><br>
>>  * Merging of `ghc-exactprint` into the GHC tree, providing<br>
>>    infrastructure for source-to-source program rewriting out-of-the-box.<br>
>><br>
>>  * Introduction of a `BoxedRep` `RuntimeRep`, allowing for polymorphism<br>
>>    over levity of boxed objects (#17526)<br>
>><br>
>>  * Implementation of the `UnliftedDataTypes` extension, allowing users<br>
>>    to define types which do not admit lazy evaluation ([proposal])<br>
>><br>
>>  * The new [`-hi` profiling] mechanism which provides significantly<br>
>>    improved insight into thunk leaks.<br>
>><br>
>>  * Support for the `ghc-debug` out-of-process heap inspection library<br>
>>    [ghc-debug]<br>
>><br>
>>  * Significant improvements in the bytecode interpreter, allowing more<br>
>>    programs to be efficently run in GHCi and Template Haskell splices.<br>
>><br>
>>  * Support for profiling of pinned objects with the cost-centre profiler<br>
>>    (#7275)<br>
>><br>
>>  * Faster compilation and a smaller memory footprint<br>
>><br>
>>  * Introduction of Haddock documentation support in TemplateHaskell (#5467)<br>
>><br>
>> Finally, thank you to Microsoft Research, GitHub, IOHK, the Zw3rk stake<br>
>> pool, Tweag I/O, Serokell, Equinix, SimSpace, and other anonymous<br>
>> contributors whose on-going financial and in-kind support has<br>
>> facilitated GHC maintenance and release management over the years.<br>
>> Moreover, this release would not have been possible without the hundreds<br>
>> of open-source contributors whose work comprise this release.<br>
>><br>
>> As always, do open a [ticket] if you see anything amiss.<br>
>><br>
>> Happy testing,<br>
>><br>
>> - Ben<br>
>><br>
>><br>
>> [apple-m1]: <a href="https://www.haskell.org/ghc/blog/20210309-apple-m1-story.html" rel="noreferrer" target="_blank">https://www.haskell.org/ghc/blog/20210309-apple-m1-story.html</a><br>
>> [proposal]: <a href="https://github.com/ghc-proposals/ghc-proposals/blob/master/proposals/0265-unlifted-datatypes.rst" rel="noreferrer" target="_blank">https://github.com/ghc-proposals/ghc-proposals/blob/master/proposals/0265-unlifted-datatypes.rst</a><br>
>> [-hi profiling]: <a href="https://well-typed.com/blog/2021/01/first-look-at-hi-profiling-mode/" rel="noreferrer" target="_blank">https://well-typed.com/blog/2021/01/first-look-at-hi-profiling-mode/</a><br>
>> [ghc-debug]: <a href="http://ghc.gitlab.haskell.org/ghc-debug/" rel="noreferrer" target="_blank">http://ghc.gitlab.haskell.org/ghc-debug/</a><br>
>> [ticket]: <a href="https://gitlab.haskell.org/ghc/ghc/-/issues/new" rel="noreferrer" target="_blank">https://gitlab.haskell.org/ghc/ghc/-/issues/new</a><br>
>> _______________________________________________<br>
>> ghc-devs mailing list<br>
>> <a href="mailto:ghc-devs@haskell.org" target="_blank">ghc-devs@haskell.org</a><br>
>> <a href="http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs" rel="noreferrer" target="_blank">http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs</a><br>
><br>
> _______________________________________________<br>
> ghc-devs mailing list<br>
> <a href="mailto:ghc-devs@haskell.org" target="_blank">ghc-devs@haskell.org</a><br>
> <a href="http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs" rel="noreferrer" target="_blank">http://mail.haskell.org/cgi-bin/mailman/listinfo/ghc-devs</a><br>
</blockquote></div></div>