pyjulia icon indicating copy to clipboard operation
pyjulia copied to clipboard

Make system image relocatable

Open tkf opened this issue 5 years ago • 0 comments

The custom system image created by current PyJulia is not relocatable at the moment. One of the reasons is that it embeds the path to julia-py executable:

https://github.com/JuliaPy/pyjulia/blob/cdd97d73e84cf73c9d17c85bf66988a0de5b255d/src/julia/patch.jl#L36-L38

An easy fix may be to dynamically load julia-py path from an environment variable. However, since different Python versions may not be ABI compatible (e.g., 3.6 and 3.7 have different PyDateTime layout), we need to check the ABI compatibility at run-time. PyCall.__init__ may be the best location to do this check.

tkf avatar Sep 17 '19 21:09 tkf