# Building 0.19 from source?

**URL:** <https://discourse.elm-lang.org/t/building-0-19-from-source/3769>\
**Category:** Learn\
**Created:** [June 7, 2019, 6:48pm UTC](https://discourse.elm-lang.org/t/building-0-19-from-source/3769 "2019-06-07T18:48:53Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Joey\_Eremondi](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.elm-lang.org/joey_eremondi/32/2192_2.png) [@Joey\_Eremondi](https://discourse.elm-lang.org/u/Joey_Eremondi)\
**Post date:** [June 7, 2019, 6:48pm UTC](https://discourse.elm-lang.org/t/building-0-19-from-source/3769/1 "2019-06-07T18:48:53Z")

</div>

Has anyone had success building 0.19 from source? 0.18 had guides for this and the buildFromSource.hs script, but this is gone in 0.19, as is any mention of building in the README or the Install page of the docs.

I’ve tried using Stack with lts-11.22, but I get weird errors about “Map.!: given key is not an element in the map”, that seem to be related to how ui/terminal/Develop/SourceFiles.hs is using TemplateHaskell to embed the elm-compiler statically.

Running `cabal install` with GHC 8.4.4 (i.e. Haskell Platform in Ubuntu 19.04) gives a dependency error.

Does anyone know what’s going on with the TemplateHaskell? Is it looking for files in ~/.elm that don’t exist? Is there an “off the books” guide to compiling Elm from scratch?

---

<div class="post-metadata">

**Author:** ![JDemler](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.elm-lang.org/jdemler/32/2130_2.png) [@JDemler](https://discourse.elm-lang.org/u/JDemler)\
**Post date:** [June 7, 2019, 8:05pm UTC](https://discourse.elm-lang.org/t/building-0-19-from-source/3769/2 "2019-06-07T20:05:33Z")

</div>

You can use the instructions provided [here](https://github.com/CurrySoftware/compiler#build). Note, that you can either

- use our fork, which adds a few convenience features to the reactor and merges a pr that fixes the `Map.!: given key..` bug
- or use the elm compiler at tag [0.19.0](https://github.com/elm/compiler/commits/0.19.0)

You will very likely fail to build from the current master.

---

<div class="post-metadata">

**Author:** ![frozar](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.elm-lang.org/frozar/32/2253_2.png) [@frozar](https://discourse.elm-lang.org/u/frozar)\
**Post date:** [June 8, 2019, 12:13am UTC](https://discourse.elm-lang.org/t/building-0-19-from-source/3769/3 "2019-06-08T00:13:09Z")

</div>

This link for [building instruction](https://github.com/CurrySoftware/compiler#build) seems like a troll

 ![browser](https://canada1.discourse-cdn.com/flex035/uploads/elm_lang/original/2X/3/3227438367ae30aaa0b38589d0e4706ff80fc7d4.jpeg)

---

<div class="post-metadata">

**Author:** ![Joey\_Eremondi](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.elm-lang.org/joey_eremondi/32/2192_2.png) [@Joey\_Eremondi](https://discourse.elm-lang.org/u/Joey_Eremondi)\
**Post date:** [June 8, 2019, 3:37am UTC](https://discourse.elm-lang.org/t/building-0-19-from-source/3769/4 "2019-06-08T03:37:01Z")

</div>

I still get the error on the 0.19 tag, but the fork works perfectly! Thanks, this is a lifesaver!

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex035/uploads/elm_lang/original/1X/50a05e53677a2c3b47776d7abd0f113eb50193a1.png) [@system](https://discourse.elm-lang.org/u/system)\
**Post date:** [June 18, 2019, 3:37am UTC](https://discourse.elm-lang.org/t/building-0-19-from-source/3769/5 "2019-06-18T03:37:03Z")

</div>

Closed on June 18, 2019, 3:37am UTC

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.
