Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Parallel Cabal Builds [duplicate]

Is there a way to compile packages in parallel when using cabal install similar to GNU make's -jN flag?

like image 707
Nordlöw Avatar asked Oct 21 '11 19:10

Nordlöw


2 Answers

Yes, from version 1.16, cabal does support this using the -j option to install, like so:

cabal install -j mypackage

like image 165
user239558 Avatar answered Nov 19 '22 08:11

user239558


No. This has been an open issue for some time. There was an effort to make ghc --make build the needed modules in parallel, but evidently that ran into issues. Since then doing this at the cabal level has been all the discussion I've heard but has not became reality yet.

See this duplicate question for some links and what is still the state of the art.

like image 34
Thomas M. DuBuisson Avatar answered Nov 19 '22 09:11

Thomas M. DuBuisson