# Problem installing Rstan on Mac 10.13.3

**URL:** <https://discourse.mc-stan.org/t/problem-installing-rstan-on-mac-10-13-3/3454>\
**Category:** RStan\
**Created:** [March 4, 2018, 6:22pm UTC](https://discourse.mc-stan.org/t/problem-installing-rstan-on-mac-10-13-3/3454 "2018-03-04T18:22:33Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Eric\_Innocents\_Eboulet](https://avatars.discourse-cdn.com/v4/letter/e/e480ec/32.png) [@Eric\_Innocents\_Eboulet](https://discourse.mc-stan.org/u/Eric_Innocents_Eboulet)\
**Post date:** [March 4, 2018, 6:22pm UTC](https://discourse.mc-stan.org/t/problem-installing-rstan-on-mac-10-13-3/3454/1 "2018-03-04T18:22:33Z")

</div>

Hi stan’s users,

I followed the description about installing rstan on Mac. However I didn’t install anything.  
I got this error below :

> fx ← inline::cxxfunction( signature(x = “integer”, y = “numeric” ),‘return ScalarReal( INTEGER(x)[0] \* REAL(y)[0] ) ;’ )  
> /Library/Frameworks/R.framework/Resources/bin/Rcmd: line 38: sed: command not found  
> sh: make: command not found

ERROR(s) during compilation: source code errors or compiler configuration errors!

Program source:  
1:  
2: // includes from the plugin  
3: #include \<R.h\>  
4: #include \<Rdefines.h\>  
5: #include \<R\_ext/Error.h\>  
6:  
7:  
8: // user includes  
9:  
10:  
11: // declarations  
12: extern “C” {  
13: SEXP file31462e06c08( SEXP x, SEXP y) ;  
14: }  
15:  
16: // definition  
17:  
18: SEXP file31462e06c08( SEXP x, SEXP y ){  
19: return ScalarReal( INTEGER(x)[0] \* REAL(y)[0] ) ;  
20: Rf\_warning(“your C++ program does not return anything”);  
21: return R\_NilValue ;  
22: }  
23:  
24:  
Error in compileCode(f, code, language = language, verbose = verbose) :  
Compilation ERROR, function(s)/method(s) not created! /Library/Frameworks/R.framework/Resources/bin/Rcmd: line 38: sed: command not found  
sh: make: command not found  
De plus : Warning message:  
l’exécution de la commande ‘/Library/Frameworks/R.framework/Resources/bin/R CMD SHLIB file31462e06c08.cpp 2\> file31462e06c08.cpp.err.txt’ renvoie un statut 1

Could you help me how to do for that, please ?

Kind regards.

---

<div class="post-metadata">

**Author:** ![mike-lawrence](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/mike-lawrence/32/59_2.png) [@mike-lawrence](https://discourse.mc-stan.org/u/mike-lawrence)\
**Post date:** [March 4, 2018, 6:43pm UTC](https://discourse.mc-stan.org/t/problem-installing-rstan-on-mac-10-13-3/3454/2 "2018-03-04T18:43:49Z")

</div>

What is the output of `system("gcc --version")` ?

---

<div class="post-metadata">

**Author:** ![Bob\_Carpenter](https://yyz2.discourse-cdn.com/flex030/user_avatar/discourse.mc-stan.org/bob_carpenter/32/9230_2.png) [@Bob\_Carpenter](https://discourse.mc-stan.org/u/Bob_Carpenter)\
**Post date:** [March 4, 2018, 11:44pm UTC](https://discourse.mc-stan.org/t/problem-installing-rstan-on-mac-10-13-3/3454/3 "2018-03-04T23:44:44Z")

</div>

> [@Eric\_Innocents\_Eboulet](#):
>
> I followed the description about installing rstan on Mac.

It helps if you’re more explicit about what you did. Did you install Xcode and the command line tools?

---

<div class="post-metadata">

**Author:** ![Eric\_Innocents\_Eboulet](https://avatars.discourse-cdn.com/v4/letter/e/e480ec/32.png) [@Eric\_Innocents\_Eboulet](https://discourse.mc-stan.org/u/Eric_Innocents_Eboulet)\
**Post date:** [March 5, 2018, 1:04am UTC](https://discourse.mc-stan.org/t/problem-installing-rstan-on-mac-10-13-3/3454/4 "2018-03-05T01:04:37Z")

</div>

Hi,  
Yes, in fact I noticed I had download xcode beta. But after download xcode from itunes, everything works now.

Thank for you help.
