Skip to content

The new nix-style Cabal is a fat monster #146

@krangelov

Description

@krangelov

I upgraded my GHC version and with that I also got the new Cabal which uses v2 commands by default. It promises to solve the Cabal hell but in my opinion it makes everything even more complicated. Every time when you compile a package it gets an unique hash code which is then baked in in every exported symbol from every executable or library.

Furthermore after every recompilation the produced binary is put in another folder. For instance you can find the gf binary in a folder like this:

~/.cabal/store/ghc-8.8.4/gf-3.11.0-46d45029734611904857f06749335e382c378b1bc656ff7fd6eab8198d9c3297/bin/gf

where the long sequence of numbers is the hash code. The code changes every time when you change something in the GF code!

The consequence is that this also affects how GF finds the RGL library and the root folder for the web server. The two are now:

~/.cabal/store/ghc-8.8.4/gf-3.11.0-46d45029734611904857f06749335e382c378b1bc656ff7fd6eab8198d9c3297/share/lib
~/.cabal/store/ghc-8.8.4/gf-3.11.0-46d45029734611904857f06749335e382c378b1bc656ff7fd6eab8198d9c3297/share/www

Of course this means that, if you change something in the GF compiler, then you also must recompile the RGL.

The GF setup script used to compile and install some example grammars in the web folder. This doesn't work anymore either.

My suggestion is to change the location for the RGL and the web root to:

~/.gf/lib
~/.gf/www

Also the code for the GF Cloud will be moved to a new repository gf-cloud, which will install to ~/.gf/www. The GF setup cannot do the installation anymore.

Let me know your opinion before I start moving things!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions