Install mess

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Install mess

Lawrence Bottorff-2
I'm on Ubuntu 18.10 and I've made a real mess of my Haskell install. In the past I believe I installed from source. Then I must have tried to install through Ubuntu's repo, then I installed through the Haskell tool stack (curl -sSL https://get.haskellstack.org/ | sh). Now I can type ghci at the command line and I get 8.4.2, through stack ghci I get version 8.0.1, while starting a ghci REPL in Emacs goes with the 8.4.2. The Ubuntu repo version seems to be 8.2.2, BTW. What can I do/what should I do to straighten this out? What is the definitive install of Haskell, stack or Haskell platform, and what role should cabal play?

LB

_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Re: Install mess

Graham Gill
I faced a similar problem recently and wasn't able to finish building Liquid Haskell and HIE until I started afresh. I wiped/uninstalled old Haskell platforms, stack and cabal. Then for a system GHC and cabal I used the HVR ppa. You could also use ghcup. See the ghcup page on github which links to the HVR ppa also.  See the downloads page at haskell.org, under Linux generic installer, which currently recommends using ghcup. (I liked the flavour of the HVR ppa more so went with that. )

For anything else I'm using the latest stack.

I think my setup is much cleaner as a result, and tools better organised. 

Regards, 
Graham



On Mon, Jan 28, 2019, 11:12 Lawrence Bottorff <[hidden email] wrote:
I'm on Ubuntu 18.10 and I've made a real mess of my Haskell install. In the past I believe I installed from source. Then I must have tried to install through Ubuntu's repo, then I installed through the Haskell tool stack (curl -sSL https://get.haskellstack.org/ | sh). Now I can type ghci at the command line and I get 8.4.2, through stack ghci I get version 8.0.1, while starting a ghci REPL in Emacs goes with the 8.4.2. The Ubuntu repo version seems to be 8.2.2, BTW. What can I do/what should I do to straighten this out? What is the definitive install of Haskell, stack or Haskell platform, and what role should cabal play?

LB
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners

_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Re: Install mess

Lawrence Bottorff-2
So I've got the HVR ppa going, now, what specifically do I want to install, type on the command? I guess I'm hearing stack?

On Sun, Jan 27, 2019 at 11:39 PM Graham Gill <[hidden email]> wrote:
I faced a similar problem recently and wasn't able to finish building Liquid Haskell and HIE until I started afresh. I wiped/uninstalled old Haskell platforms, stack and cabal. Then for a system GHC and cabal I used the HVR ppa. You could also use ghcup. See the ghcup page on github which links to the HVR ppa also.  See the downloads page at haskell.org, under Linux generic installer, which currently recommends using ghcup. (I liked the flavour of the HVR ppa more so went with that. )

For anything else I'm using the latest stack.

I think my setup is much cleaner as a result, and tools better organised. 

Regards, 
Graham



On Mon, Jan 28, 2019, 11:12 Lawrence Bottorff <[hidden email] wrote:
I'm on Ubuntu 18.10 and I've made a real mess of my Haskell install. In the past I believe I installed from source. Then I must have tried to install through Ubuntu's repo, then I installed through the Haskell tool stack (curl -sSL https://get.haskellstack.org/ | sh). Now I can type ghci at the command line and I get 8.4.2, through stack ghci I get version 8.0.1, while starting a ghci REPL in Emacs goes with the 8.4.2. The Ubuntu repo version seems to be 8.2.2, BTW. What can I do/what should I do to straighten this out? What is the definitive install of Haskell, stack or Haskell platform, and what role should cabal play?

LB
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners

_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Re: Install mess

Baojun Wang
You can install `ghc` and `cabal-install` (provide the `cabal` command line application) using hvr ppa, if you have a project created by `cabal` or `stack`, then that's pretty much all you need (ghc+cabal-install), you can run 

cabal new-update # update the local package package indexes
cabal new-build # to build the package

  or use

cabal init # to create a project

There're other commands such as `cabal new-install, cabal new-test, cabal new-run` could be quite useful, the official document can be found at: https://cabal.readthedocs.io/en/latest/nix-local-build-overview.html

 If you choose `stack` then stack can manage ghc installation by itself, the stack website should have enough information to get started:

Personally I would prefer hvr ghc/cabal-install, or stack, instead of ghc/cabal provided by the system, as they don't usually seems to up-to-date, and cabal-install manages packages dependencies a lot better with the new command line interfaces (cabal new-*).



On Mon, Jan 28, 2019 at 11:29 AM Lawrence Bottorff <[hidden email]> wrote:
So I've got the HVR ppa going, now, what specifically do I want to install, type on the command? I guess I'm hearing stack?

On Sun, Jan 27, 2019 at 11:39 PM Graham Gill <[hidden email]> wrote:
I faced a similar problem recently and wasn't able to finish building Liquid Haskell and HIE until I started afresh. I wiped/uninstalled old Haskell platforms, stack and cabal. Then for a system GHC and cabal I used the HVR ppa. You could also use ghcup. See the ghcup page on github which links to the HVR ppa also.  See the downloads page at haskell.org, under Linux generic installer, which currently recommends using ghcup. (I liked the flavour of the HVR ppa more so went with that. )

For anything else I'm using the latest stack.

I think my setup is much cleaner as a result, and tools better organised. 

Regards, 
Graham



On Mon, Jan 28, 2019, 11:12 Lawrence Bottorff <[hidden email] wrote:
I'm on Ubuntu 18.10 and I've made a real mess of my Haskell install. In the past I believe I installed from source. Then I must have tried to install through Ubuntu's repo, then I installed through the Haskell tool stack (curl -sSL https://get.haskellstack.org/ | sh). Now I can type ghci at the command line and I get 8.4.2, through stack ghci I get version 8.0.1, while starting a ghci REPL in Emacs goes with the 8.4.2. The Ubuntu repo version seems to be 8.2.2, BTW. What can I do/what should I do to straighten this out? What is the definitive install of Haskell, stack or Haskell platform, and what role should cabal play?

LB
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners

_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Re: Install mess

Lawrence Bottorff-2
So I've set up the Herbert V. Riedel PPA

sudo add-apt-repository ppa:hvr/ghc
sudo apt-get update

then I installed ghc-8.6.3 and cabal-install-2.4

sudo apt-get install ghc-8.6.3
sudo apt-get install cabal-install-2.4

. . . and stuff seems to be installing. However a check finds no cabal and ghc version 8.2.2

What am I missing?

LB





On Mon, Jan 28, 2019 at 11:39 AM Baojun Wang <[hidden email]> wrote:
You can install `ghc` and `cabal-install` (provide the `cabal` command line application) using hvr ppa, if you have a project created by `cabal` or `stack`, then that's pretty much all you need (ghc+cabal-install), you can run 

cabal new-update # update the local package package indexes
cabal new-build # to build the package

  or use

cabal init # to create a project

There're other commands such as `cabal new-install, cabal new-test, cabal new-run` could be quite useful, the official document can be found at: https://cabal.readthedocs.io/en/latest/nix-local-build-overview.html

 If you choose `stack` then stack can manage ghc installation by itself, the stack website should have enough information to get started:

Personally I would prefer hvr ghc/cabal-install, or stack, instead of ghc/cabal provided by the system, as they don't usually seems to up-to-date, and cabal-install manages packages dependencies a lot better with the new command line interfaces (cabal new-*).



On Mon, Jan 28, 2019 at 11:29 AM Lawrence Bottorff <[hidden email]> wrote:
So I've got the HVR ppa going, now, what specifically do I want to install, type on the command? I guess I'm hearing stack?

On Sun, Jan 27, 2019 at 11:39 PM Graham Gill <[hidden email]> wrote:
I faced a similar problem recently and wasn't able to finish building Liquid Haskell and HIE until I started afresh. I wiped/uninstalled old Haskell platforms, stack and cabal. Then for a system GHC and cabal I used the HVR ppa. You could also use ghcup. See the ghcup page on github which links to the HVR ppa also.  See the downloads page at haskell.org, under Linux generic installer, which currently recommends using ghcup. (I liked the flavour of the HVR ppa more so went with that. )

For anything else I'm using the latest stack.

I think my setup is much cleaner as a result, and tools better organised. 

Regards, 
Graham



On Mon, Jan 28, 2019, 11:12 Lawrence Bottorff <[hidden email] wrote:
I'm on Ubuntu 18.10 and I've made a real mess of my Haskell install. In the past I believe I installed from source. Then I must have tried to install through Ubuntu's repo, then I installed through the Haskell tool stack (curl -sSL https://get.haskellstack.org/ | sh). Now I can type ghci at the command line and I get 8.4.2, through stack ghci I get version 8.0.1, while starting a ghci REPL in Emacs goes with the 8.4.2. The Ubuntu repo version seems to be 8.2.2, BTW. What can I do/what should I do to straighten this out? What is the definitive install of Haskell, stack or Haskell platform, and what role should cabal play?

LB
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners

_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Re: Install mess

Michel Haber
Hello,
perhaps check the install repository. I had the same problem:
With an old version of ghc and cabal installed, the symlink isn't changed to point towards the new one.
You can do so manually:
- get the dir of your ghc: $ which ghc
- the directory ends with /bin/
- in fact this would be a symlink towards a version of ghc (not the version you want)
- simply change the symbolic link (usually the actual ghc dir is right next to the bin symlink)

On Tue, Jan 29, 2019 at 4:37 AM Lawrence Bottorff <[hidden email]> wrote:
So I've set up the Herbert V. Riedel PPA

sudo add-apt-repository ppa:hvr/ghc
sudo apt-get update

then I installed ghc-8.6.3 and cabal-install-2.4

sudo apt-get install ghc-8.6.3
sudo apt-get install cabal-install-2.4

. . . and stuff seems to be installing. However a check finds no cabal and ghc version 8.2.2

What am I missing?

LB





On Mon, Jan 28, 2019 at 11:39 AM Baojun Wang <[hidden email]> wrote:
You can install `ghc` and `cabal-install` (provide the `cabal` command line application) using hvr ppa, if you have a project created by `cabal` or `stack`, then that's pretty much all you need (ghc+cabal-install), you can run 

cabal new-update # update the local package package indexes
cabal new-build # to build the package

  or use

cabal init # to create a project

There're other commands such as `cabal new-install, cabal new-test, cabal new-run` could be quite useful, the official document can be found at: https://cabal.readthedocs.io/en/latest/nix-local-build-overview.html

 If you choose `stack` then stack can manage ghc installation by itself, the stack website should have enough information to get started:

Personally I would prefer hvr ghc/cabal-install, or stack, instead of ghc/cabal provided by the system, as they don't usually seems to up-to-date, and cabal-install manages packages dependencies a lot better with the new command line interfaces (cabal new-*).



On Mon, Jan 28, 2019 at 11:29 AM Lawrence Bottorff <[hidden email]> wrote:
So I've got the HVR ppa going, now, what specifically do I want to install, type on the command? I guess I'm hearing stack?

On Sun, Jan 27, 2019 at 11:39 PM Graham Gill <[hidden email]> wrote:
I faced a similar problem recently and wasn't able to finish building Liquid Haskell and HIE until I started afresh. I wiped/uninstalled old Haskell platforms, stack and cabal. Then for a system GHC and cabal I used the HVR ppa. You could also use ghcup. See the ghcup page on github which links to the HVR ppa also.  See the downloads page at haskell.org, under Linux generic installer, which currently recommends using ghcup. (I liked the flavour of the HVR ppa more so went with that. )

For anything else I'm using the latest stack.

I think my setup is much cleaner as a result, and tools better organised. 

Regards, 
Graham



On Mon, Jan 28, 2019, 11:12 Lawrence Bottorff <[hidden email] wrote:
I'm on Ubuntu 18.10 and I've made a real mess of my Haskell install. In the past I believe I installed from source. Then I must have tried to install through Ubuntu's repo, then I installed through the Haskell tool stack (curl -sSL https://get.haskellstack.org/ | sh). Now I can type ghci at the command line and I get 8.4.2, through stack ghci I get version 8.0.1, while starting a ghci REPL in Emacs goes with the 8.4.2. The Ubuntu repo version seems to be 8.2.2, BTW. What can I do/what should I do to straighten this out? What is the definitive install of Haskell, stack or Haskell platform, and what role should cabal play?

LB
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners

_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Re: Install mess

Daniel Trstenjak-2
In reply to this post by Lawrence Bottorff-2
Hi Lawrence,

On Mon, Jan 28, 2019 at 09:37:23PM -0600, Lawrence Bottorff wrote:

> So I've set up the Herbert V. Riedel PPA
>
> sudo add-apt-repository ppa:hvr/ghc
> sudo apt-get update
>
> then I installed ghc-8.6.3 and cabal-install-2.4
>
> sudo apt-get install ghc-8.6.3
> sudo apt-get install cabal-install-2.4
>
> . . . and stuff seems to be installing. However a check finds no cabal and ghc version 8.2.2
>
> What am I missing?

Herbert's ppa installs 'ghc' to '/opt/ghc/8.6.3', certainly the same is the case for 'cabal-install'.
Below '/opt/ghc' you can have multiple installed ghcs at once.

The easiest way to configure which ghc should be used is by defining a
GHC_VERSION environment variable:

   export GHC_VERSION=8.6.3
   export PATH=/opt/ghc/$GHC_VERSION/bin:$PATH


Grettings,
Daniel
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners