@@ -269,6 +269,34 @@ versions of IPython. You can avoid this issue by updating IPython to
269
269
7.0 or above. Alternatively, you can use IPython via Jupyter (e.g.,
270
270
` jupyter console ` ) to workaround the problem.
271
271
272
+ ### Error due to ` libstdc++ ` version
273
+
274
+ When you use PyJulia with another Python extension, you may see an
275
+ error like `` version `GLIBCXX_3.4.22' not found `` (Linux) or `The
276
+ procedure entry point ... could not be located in the dynamic link
277
+ library libstdc++6.dll` (Windows). In this case, you might have
278
+ observed that initializing PyJulia first fixes the problem. This is
279
+ because Julia (or likely its dependencies like LLVM) requires a recent
280
+ version of ` libstdc++ ` .
281
+
282
+ Possible fixes:
283
+
284
+ * Initialize PyJulia (e.g., by ` from julia import Main ` ) as early as
285
+ possible. Note that just importing PyJulia (` import julia ` ) does
286
+ not work.
287
+ * Load ` libstdc++.so.6 ` first by setting environment variable
288
+ ` LD_PRELOAD ` (Linux) to
289
+ ` /PATH/TO/JULIA/DIR/lib/julia/libstdc++.so.6 ` where
290
+ ` /PATH/TO/JULIA/DIR/lib ` is the directory which has ` libjulia.so ` .
291
+ macOS and Windows likely to have similar mechanisms (untested).
292
+ * Similarly, set environment variable ` LD_LIBRARY_PATH ` (Linux) to
293
+ ` /PATH/TO/JULIA/DIR/lib/julia ` directory. Using ` DYLD_LIBRARY_PATH `
294
+ on macOS and ` PATH ` on Windows may work (untested).
295
+
296
+ See:
297
+ https://github.com/JuliaPy/pyjulia/issues/180 ,
298
+ https://github.com/JuliaPy/pyjulia/issues/223
299
+
272
300
273
301
How it works
274
302
------------
0 commit comments