Added getting started instructions to readme, Update BUILDING_FROM_SOURCE

This commit is contained in:
Anton-4 2020-09-03 19:26:20 +02:00
parent 42d90e61b1
commit 1f515ebd46
2 changed files with 17 additions and 2 deletions

View file

@ -9,12 +9,17 @@ To see which version of LLVM you need, take a look at `Cargo.toml`, in particula
For Ubuntu, I used the `Automatic installation script` at [apt.llvm.org](https://apt.llvm.org) - but there are plenty of alternative options at http://releases.llvm.org/download.html For Ubuntu, I used the `Automatic installation script` at [apt.llvm.org](https://apt.llvm.org) - but there are plenty of alternative options at http://releases.llvm.org/download.html
### Troubleshooting LLVM installation on Linux ## Troubleshooting
Create an issue if you run into problems not listed here.
We intend to make contributing to Roc as smooth as possible.
### LLVM installation on Linux
On some Linux systems we've seen the error "failed to run custom build command for x11". On some Linux systems we've seen the error "failed to run custom build command for x11".
On Ubuntu, running `sudo apt-get install cmake libx11-dev` fixed this. On Ubuntu, running `sudo apt-get install cmake libx11-dev` fixed this.
### Troubleshooting LLVM installation on Windows ### LLVM installation on Windows
Installing LLVM's prebuilt binaries doesn't seem to be enough for the `llvm-sys` crate that Roc depends on, so I had to build LLVM from source Installing LLVM's prebuilt binaries doesn't seem to be enough for the `llvm-sys` crate that Roc depends on, so I had to build LLVM from source
on Windows. After lots of help from [**@IanMacKenzie**](https://github.com/IanMacKenzie) (thank you, Ian!), here's what worked for me: on Windows. After lots of help from [**@IanMacKenzie**](https://github.com/IanMacKenzie) (thank you, Ian!), here's what worked for me:

View file

@ -2,6 +2,16 @@
Roc is a language for building reliable applications on top of fast platforms. Roc is a language for building reliable applications on top of fast platforms.
## Getting started
1. [Install rust](https://rustup.rs/)
2. [Build from source](BUILDING_FROM_SOURCE.md)
3. In the terminal execute from the root folder:
```
cargo run repl
```
4. Check [these tests](https://github.com/rtfeldman/roc/blob/trunk/cli/tests/repl_eval.rs) for examples
## Applications and Platforms ## Applications and Platforms
Applications are often built on a *framework.* Typically, both application and framework are written in the same language. Applications are often built on a *framework.* Typically, both application and framework are written in the same language.