diff --git a/wolf_scripts/ReadMe.md b/wolf_scripts/ReadMe.md index 9477f7b69c0dbc9272bcabf89286cbcc55e75761..d7d2c37c53cc0a9883d58a283f3a5c6e8c22ffbe 100644 --- a/wolf_scripts/ReadMe.md +++ b/wolf_scripts/ReadMe.md @@ -10,12 +10,17 @@ Helpful scripts to create WOLF tree elements (e.g. processors) ..*`sudo apt-get install realpath` - * __RealPath__ (Required, MacOSX): The realpath package above is not available for MacOSX. Here is an out-of-the-box alternative (credits to WaffleSouffle: https://stackoverflow.com/questions/3572030/bash-script-absolute-path-with-osx): + * __RealPath__ (Required, MacOSX): The realpath package above is not available for MacOSX. + Here is an out-of-the-box alternative + (credits to WaffleSouffle: https://stackoverflow.com/questions/3572030/bash-script-absolute-path-with-osx): - Create a small project `realpath` (here in `$HOME/dev/` as an example) + ``` $ cd $HOME/dev $ mkdir realpath + $ cd realpath + ``` - Create a file `realpath.c` with the contents: @@ -27,7 +32,7 @@ Helpful scripts to create WOLF tree elements (e.g. processors) int main (int argc, char* argv[]) { if (argc > 1) { - for (int argIter = 1; argIter < argc; ++argIter) { + for (int argIter = 1; argIter < argc; ++argIter) { char *resolved_path_buffer = NULL; char *result = realpath(argv[argIter], resolved_path_buffer); @@ -36,7 +41,7 @@ Helpful scripts to create WOLF tree elements (e.g. processors) if (result != NULL) { free(result); } - } + } } return 0; @@ -56,9 +61,17 @@ Helpful scripts to create WOLF tree elements (e.g. processors) gcc -o $@ $^ $(CFLAGS) ``` - - Then compile with make and put in a soft link with: + - Then compile with `make`: + ``` + $ make + ``` + + - and put in a soft link with: + + ``` $ ln -s $(pwd)/realpath /usr/local/bin/realpath + ``` #### SCRIPTS installation