Building Elm from source

32 views
Skip to first unread message

Ryan Rempel

unread,
Sep 2, 2015, 11:46:24 AM9/2/15
to Elm Discuss
I was trying to build the master branch from source -- I wanted to test what the effect of some of the recent changes on my own code was.

In the past, I have succeeded in such an attempt.

However, at the moment, that doesn't seem to be working. For instance, the 'official' 

runhaskell installers/BuildFromSource.hs master

method ends with errors of this nature:

src/TheMasterPlan.hs:11:18:
    Could not find module ‘Elm.Package.Name
    Perhaps you meant Elm.Package.Paths (from elm-package-0.5.1)
    Use -v to see a list of the files searched for.

src/TheMasterPlan.hs:12:18:
    Could not find module ‘Elm.Package.Version’
    Perhaps you meant Elm.Package.Solution (from elm-package-0.5.1)
    Use -v to see a list of the files searched for.

Are other people seeing this as well? Or is it a problem with my setup?

Laszlo Pandy

unread,
Sep 2, 2015, 11:56:38 AM9/2/15
to elm-d...@googlegroups.com
The master branches are not all compatible right now. I added this to BuildFromSource.hs to get it to work:
"next" =:
        [ "elm-compiler" =: "master"
        , "elm-package"  =: "master"
        , "elm-make"     =: "next"
        ]

Note that even if you get it to build, you cannot compile your code because elm-compiler/master is in the middle of a refactor and it is throwing errors. The last known good version of elm-compiler is:
https://github.com/elm-lang/elm-compiler/commit/fa6377ff1be72b1a8af0c0b6b0afe17ca02a09db

So maybe this config would work (but I have never tried to see if it is compatible with elm-make):
"next" =:
        [ "elm-compiler" =: "fa6377ff1be72b1a8af0c0b6b0afe17ca02a09db"
        , "elm-package"  =: "master"
        , "elm-make"     =: "next"
        ]

--
You received this message because you are subscribed to the Google Groups "Elm Discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elm-discuss...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Ryan Rempel

unread,
Sep 2, 2015, 12:28:39 PM9/2/15
to Elm Discuss
Thanks, that did get further ... now it errors in this way:

Configuring elm-package-0.5.1...
Building elm-package-0.5.1...
Preprocessing library elm-package-0.5.1...
[10 of 16] Compiling Elm.Package.Constraint ( src/Elm/Package/Constraint.hs, dist/dist-sandbox-c8eef042/build/Elm/Package/Constraint.o )

src/Elm/Package/Constraint.hs:57:6:
    Found hole ‘_major’ with type: Package.Version -> a0
    Where: ‘a0’ is an ambiguous type variable
    Relevant bindings include
      defaultElmVersion :: Constraint
        (bound at src/Elm/Package/Constraint.hs:56:1)
    In the expression: Package._major
    In the first argument of ‘(>)’, namely
      ‘Package._major Compiler.version’
    In the expression: Package._major Compiler.version > 0

I think I'll just wait for things to settle out -- I don't want to distract from all the awesome work going on.

Joey Eremondi

unread,
Sep 2, 2015, 2:33:47 PM9/2/15
to elm-d...@googlegroups.com

Yeah... Js generation is currently an unimplemented hole in Master... When I get a chance I'll see if I can find a stable set of commits for you to try.

Reply all
Reply to author
Forward
0 new messages