CxxWrap.jl
CxxWrap.jl copied to clipboard
symbol lookup error on travis ci
I don't know if the issue I have is due to CxxWrap but I am stuck on getting travis ci to work for the package ViZDoom and it is basically the only dependency. On my Arch Linux and Ubuntu 18.04 everything works fine. On travis the build works fine, but trying to precompile the package I get
/home/travis/julia/bin/julia: symbol lookup error: /home/travis/build/JuliaReinforcementLearning/ViZDoom.jl/src/../deps/usr/ViZDoom-1.1.6/bin/libvizdoomjl.so: undefined symbol: _ZN5jlcxx10julia_typeERKSsS1_
ERROR: LoadError: Failed to precompile ViZDoom [befec858-9df8-11e8-00a8-a968a6be5c52] to /home/travis/.julia/compiled/v0.7/ViZDoom/fWkR1.ji.
Stacktrace:
[1] error(::String) at ./error.jl:33
[2] macro expansion at ./logging.jl:313 [inlined]
[3] compilecache(::Base.PkgId, ::String) at ./loading.jl:1185
[4] _require(::Base.PkgId) at ./logging.jl:311
[5] require(::Base.PkgId) at ./loading.jl:852
[6] macro expansion at ./logging.jl:311 [inlined]
[7] require(::Module, ::Symbol) at ./loading.jl:834
[8] include at ./boot.jl:317 [inlined]
[9] include_relative(::Module, ::String) at ./loading.jl:1038
[10] include(::Module, ::String) at ./sysimg.jl:29
[11] include(::String) at ./client.jl:398
[12] top-level scope at none:0
in expression starting at /home/travis/build/JuliaReinforcementLearning/ViZDoom.jl/test/runtests.jl:1
The full log is here. The cmake command is
`cmake -DJlCxx_DIR=/home/travis/.julia/packages/CxxWrap/Ho7vF/deps/usr/lib/cmake/JlCxx -DBUILD_JULIA=ON -DJulia_EXECUTABLE=/home/travis/julia/bin/julia .`
julia v0.7/v1.0, CxxWrap v0.7.4
Any ideas what could go wrong?
I think this is an rpath issue, in my CMakeLists.txt I typically have, after the find_package(JlCxx)
:
set(CMAKE_MACOSX_RPATH 1)
set(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/lib;${JlCxx_DIR}/../")
Setting the environment variable LD_LIBRARY_PATH
to contain the path to the libcxxwrap-julia library should also work, but is less portable.
@barche close?