Skip to content

"GLIBCXX_3.4.22 not found" when used from ipykernel #223

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
tkf opened this issue Nov 12, 2018 · 1 comment
Open

"GLIBCXX_3.4.22 not found" when used from ipykernel #223

tkf opened this issue Nov 12, 2018 · 1 comment

Comments

@tkf
Copy link
Member

tkf commented Nov 12, 2018

In case you get an error like this

OSError: /usr/lib/x86_64-linux-gnu/libstdc++.so.6: version `GLIBCXX_3.4.22' not found (required by /PATH/TO/julia-1.0.2/bin/../lib/julia/libLLVM-6.0.so)

when using PyJulia via Jupyter (ipykernel), you can workaround the issue by using the LD_PRELOAD trick. For example, edit your ~/.local/share/jupyter/kernels/*/kernel.json like this:

--- a/kernel.json
+++ b/kernel.json
@@ -1,7 +1,5 @@
 {
  "argv": [
+  "env",
+  "LD_PRELOAD=/PATH/TO/julia-1.0.2/lib/julia/libstdc++.so.6",
   "/usr/bin/python",
   "-m",
   "ipykernel_launcher",

Maybe it's better to have a helper command for executing a subprocess with appropriate LD_PRELOAD (or LD_LIBRARY_PATH)?

@tkf
Copy link
Member Author

tkf commented Nov 18, 2018

Once LibJulia low-level C API #199 is implemented, we can make sure to dlopen libjulia.so without initializing PyJulia (Julia runtime + PyCall). This would be relatively quick to execute. We can then have a CLI entry point (say) julia.python_with_libjulia so that ipykernel can be used via python -m julia.python_with_libjulia -m ipykernel_launcher ....

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant