xtensor-stack / Xtensor.jl

Julia package for xtensor-julia
http://quantstack.net/xtensor
BSD 3-Clause "New" or "Revised" License
41 stars 6 forks source link

Test windows build #31

Closed SylvainCorlay closed 7 years ago

SylvainCorlay commented 7 years ago

It seems that the example dll is generated properly on windows, however,

@BinDeps.install Dict([
    (:tensors, :_l_tensors)
])

fails on windows.

cc @barche. By any chance, do you know what is going on here?

barche commented 7 years ago

Not sure if it's the case here, but I have had this happen because the dll can't get loaded. Can you manually load it using Libdl.dlopen?

SylvainCorlay commented 7 years ago

OK, from the comments on #30, the installation directory for dlls on windows is wrong.

Actually, this seems to also be an issue in cxxwrap but you download the binaries in the right place.

barche commented 7 years ago

I just realized that you need to add using CxxWrap to your build.jl, to preload the CxxWrap dll. Neither lib nor bin are added to the path, so what dir you put the dll in doesn't really matter, but the convention on Windows is indeed bin.

Dll loading works completely differently on Windows than on other platforms: dependencies need to be in the same dir, on the path or loaded manually.

SylvainCorlay commented 7 years ago

Yes! @barche @tkelman that was it. Thanks.