diff --git a/README.md b/README.md index 8db7c470a0e95d47e2f01e033e8636ba77959a91..8f35823492e905704daefa042e2ea92dcc1bb08a 100644 --- a/README.md +++ b/README.md @@ -2,25 +2,48 @@ Clone the repository in your chosen directory. In a new terminal: -``` +```bash cd <your/path> git clone <repo-link> ``` Clone the RTKLIB lib as a sub-module: -``` +```bash git submodule update --init ``` Create a directory to build all the source files: -``` -$ mkdir build -$ cd build +```bash +mkdir build +cd build ``` Compile the source files: +```bash +cmake .. +make +``` + +Install the library: + +```bash +make install +``` + +## Installation in local folder + +With the previous steps, the library will be stored in `CMAKE_PREFIX_PATH` that usually is `/usr/local`. If you want to install the library in a local folder (avoiding sudo permissions), you can add these lines in your `.bashrc` file: + +```bash +export WOLF_PREFIX=/your/local/installation/path # To be substituted by your desired installation path +export LD_LIBRARY_PATH=$WOLF_PREFIX/lib:$LD_LIBRARY_PATH +export CMAKE_PREFIX_PATH=$WOLF_PREFIX:$CMAKE_PREFIX_PATH +``` + +And compile with: +```bash +cmake .. -DCMAKE_INSTALL_PREFIX=$WOLF_PREFIX +make +make install ``` -$ cmake .. -$ make -``` \ No newline at end of file