diff --git a/.travis.yml b/.travis.yml index 3cadc4ed..bd106ecd 100644 --- a/.travis.yml +++ b/.travis.yml @@ -11,7 +11,9 @@ matrix: os: linux - language: python python: 3.5 - env: JULIA_VERSION=juliareleases + env: + - JULIA_VERSION=juliareleases + - CROSS_VERSION=1 os: linux - language: python python: 3.5 @@ -65,7 +67,6 @@ before_script: - which ${PYTHON:-python} script: - julia -e 'Pkg.add("PyCall")' - - julia -e 'Pkg.checkout("PyCall"); Pkg.build("PyCall")' - /usr/bin/python --version - PYTHON=${PYTHON:-python} - echo $PYTHON diff --git a/appveyor.yml b/appveyor.yml index 0f94101c..9a45dbf1 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -70,7 +70,7 @@ build_script: # - C:\projects\julia\bin\julia -e "versioninfo(); Pkg.add(\"PyCall\"); Pkg.init(); Pkg.resolve()" # - C:\projects\julia\bin\julia -e "using PyCall; @assert isdefined(:PyCall); @assert typeof(PyCall) === Module" - "SET PYTHON=%PYTHONDIR%\\python.exe" - - C:\projects\julia\bin\julia -e "versioninfo(); Pkg.add(\"PyCall\"); Pkg.checkout(\"PyCall\"); Pkg.build(\"PyCall\")" + - C:\projects\julia\bin\julia -e "versioninfo(); Pkg.add(\"PyCall\")" test_script: - "SET PATH=%PYTHONDIR%;%PYTHONDIR%\\Scripts;C:\\projects\\julia\\bin;%PATH%" diff --git a/julia/core.py b/julia/core.py index b2982d04..87383afd 100644 --- a/julia/core.py +++ b/julia/core.py @@ -30,6 +30,8 @@ # this is python 3.3 specific from types import ModuleType, FunctionType +from setuptools.pep425tags import get_abi_tag + #----------------------------------------------------------------------------- # Classes and funtions #----------------------------------------------------------------------------- @@ -356,8 +358,9 @@ def __init__(self, init_julia=True, jl_runtime_path=None, jl_init_path=None, os.environ["PYCALL_LIBJULIA_PATH"] = os.path.dirname(libjulia_path) # Add a private cache directory. PyCall needs a different # configuration and so do any packages that depend on it. - self._call(u"unshift!(Base.LOAD_CACHE_PATH, abspath(Pkg.Dir._pkgroot()," + - "\"lib\", \"pyjulia%s-v$(VERSION.major).$(VERSION.minor)\"))" % sys.version_info[0]) + self._call(u"unshift!(Base.LOAD_CACHE_PATH, abspath(Pkg.Dir._pkgroot()," + "\"lib\", \"pyjulia.{}-v$(VERSION.major).$(VERSION.minor)\"))" + .format(get_abi_tag())) # If PyCall.ji does not exist, create an empty file to force # recompilation self._call(u"""