# Initialization of R fails on julia 1.1

**URL:** <https://discourse.julialang.org/t/initialization-of-r-fails-on-julia-1-1/19735>\
**Category:** General Usage\
**Created:** [January 17, 2019, 6:03am UTC](https://discourse.julialang.org/t/initialization-of-r-fails-on-julia-1-1/19735 "2019-01-17T06:03:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![randy3k](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/randy3k/32/878_2.png) [@randy3k](https://discourse.julialang.org/u/randy3k)\
**Post date:** [January 17, 2019, 6:03am UTC](https://discourse.julialang.org/t/initialization-of-r-fails-on-julia-1-1/19735/1 "2019-01-17T06:03:50Z")

</div>

The following discussion is initiated by the bug report of RCall.jl [Error C stack usage too close to the limit (when precompiling w Julia 1.2) · Issue #289 · JuliaInterop/RCall.jl · GitHub](https://github.com/JuliaInterop/RCall.jl/issues/289)  
saying that RCall.jl is not working on julia 1.1.

The simpliest reproducible result is the following code. Just copy this piece of code to julia REPL.

```julia
Rhome = readchomp(`R RHOME`)
ENV["R_HOME"] = Rhome
ENV["R_DOC_DIR"] = joinpath(Rhome,"doc")
ENV["R_INCLUDE_DIR"] = joinpath(Rhome,"include")
ENV["R_SHARE_DIR"] = joinpath(Rhome,"share")
const libR = Rhome * "/lib/libR.dylib" # mac
# const libR = Rhome * "/lib/libR.so" # linux
argv = ["REmbeddedJulia","--silent","--no-save"]
ccall((:Rf_initEmbeddedR,libR),Cint,(Cint,Ptr{Ptr{Cchar}}),length(argv),argv)

```

The above piece of code is working fine on julia 1.0 but not on julia 1.1, so it means that there is a change in julia which breaks this.

Interestingly enough, if one save the above code to a script file and run `julia script.jl` non-interactively, it will run without an error. It means the change of julia 1.1 which breaks RCall.jl is related to the REPL.

I would like to do a git bisect but I don’t want to do the buildings manually, is there any place for me to download the commit builds?

---

<div class="post-metadata">

**Author:** ![Keno](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/keno/32/285_2.png) [@Keno](https://discourse.julialang.org/u/Keno)\
**Post date:** [January 17, 2019, 7:38pm UTC](https://discourse.julialang.org/t/initialization-of-r-fails-on-julia-1-1/19735/2 "2019-01-17T19:38:15Z")

</div>

> [@randy3k](#):
>
> I would like to do a git bisect but I don’t want to do the buildings manually, is there any place for me to download the commit builds?

No, but if you build with ccache, it tends to be fairly quick.
