GLIBCXX_3.4.26 not found in RCall

(Also posted on slack#statistics)

If anyone has time to look at what must be a basic issue on my side, I’ve posted an issue on RCall.jl that is a show stopper for me:

Much :heart: if you can help out!

1 Like

I just had the same problem when trying to import matplotlib with PyCall this morning. It worked fine in python, so I was a bit confused, but I came to the conclusion that the libstdc++ that ships with Julia is too old, while the one I have installed on my system is up to date. Compiling Julia from source fixed the problem.

1 Like

oooo, I’ll give it a shot!

Check that

$ strings /usr/lib64/ | grep GLIBCXX

(or equivalent) returns GLIBCXX_3.4.26 before compiling, if not you need a newer version.

Found it! Here:

$ /sbin/ldconfig -p | grep stdc++ (libc6,x86-64) => /lib/x86_64-linux-gnu/
$ strings /lib/x86_64-linux-gnu/ | grep GLIBCXX
GLIBCXX_3.4.26 # <--- HERE IT IS!!!

So what does that mean…?

I’ll just add that this is still aproblem in the 1.3 rc2, incase that got updated between the two rcs…

Just to sum it up, not sure what is going on, but I compiled Julia from source (v1.2.0) and it all works now.


Thanks for all the help!!!


1 Like

Tapped into this one today, but using a Julia source build isn’t a viable workaround. Setting LD_LIBRARY_PATH or R_LD_LIBRARY_PATH, as suggested in and some bug reports didn’t help either.

Has anyone gotten rid of this without compiling Julia?

R> library(devtools)
Loading required package: usethis
Error: package or namespace load failed for ‘usethis’ in dyn.load(file, DLLpath = DLLpath, ...):
 unable to load shared object '/home/gerhard/R/x86_64-pc-linux-gnu-library/3.6/Rcpp/libs/':
  /home/gerhard/julia-1.3.1/bin/../lib/julia/ version `GLIBCXX_3.4.26' not found (required by /home/gerhard/R/x86_64-pc-linux-gnu-library/3.6/Rcpp/libs/
Error: package ‘usethis’ could not be loaded
1 Like

I’ve seen your bug report:

Could you please reopen the issue?

Through help on Slack by @staticfloat it became clear that the underlying problem is, that the Julia provided is older than the one provided by the operating system, in my case Ubuntu 19.10, which in turn is used by R.

An intermediate solution is to replace Julias with the one from the OS:

# works for Ubuntu 19.10 64bit - match your locations accordingly!
 cp /usr/lib/x86_64-linux-gnu/ $JULIA_HOME/lib/julia/

For completeness a list of references of this issue:


Not sure where to discuss so doing so here. It seems like you, @laborg, have a good grasp on the issues here. Could you please add a note of sorts to both these repos, JuliaCall and RCall, informing users that run into the same problem on how to resolve these…? That would be a great first step until this gets permanently resolved (by having Julia use the system’s libstdc or updating Julia’s own libstdc in case the system’s version is higher or something).

Yes, good idea:

1 Like

Backlink to the corresponding issue:

1 Like

This issue is not confined to RCall. PyCall also reports the same error. So, the problem is with the Julia distribution and the developers need to be alerted to this problem so that they have the most recent version of in the compiled version of Julia.

The Julia developers are aware of the bug, see

I think its best is to attach your problem report there and hope that the proposed solution will soon come to fruition.

This is a stupid question.
If I build Julia from scratch on (say) a Fedora system or the latest Ubuntu where does the libstdc++ originate from?
IE. Does building from source build an up to date libstdc++ for that system.

Note to self - why dont you take the time to test that hypothesis…

If you build from scratch, I think the system libstdc++ is used and so it should work. The issues comes only from using the pre-built binary