Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Julia 1.4.3] when building, find a error occured by libllvm #477

Open
nesteiner opened this issue Jul 17, 2020 · 3 comments
Open

[Julia 1.4.3] when building, find a error occured by libllvm #477

nesteiner opened this issue Jul 17, 2020 · 3 comments

Comments

@nesteiner
Copy link

(v1.4) pkg> build Cxx
   Building Cxx  `~/.julia/packages/Cxx/1RaOv/deps/build.log`
┌ Error: Error building `Cxx`: 
│ ERROR: LoadError: could not load library "libLLVM-8.0.1"
│ libLLVM-8.0.1.so:  Unable to open shared object file: No file or directory
│ Stacktrace:
│  [1] dlopen(::String, ::UInt32; throw_error::Bool) at /home/steiner/disk/disk1/Download/images/julia-1.4.2/usr/share/julia/stdlib/v1.4/Libdl/src/Libdl.jl:109
│  [2] dlopen at /home/steiner/disk/disk1/Download/images/julia-1.4.2/usr/share/julia/stdlib/v1.4/Libdl/src/Libdl.jl:109 [inlined] (repeats 2 times)
│  [3] dlpath(::String) at /home/steiner/disk/disk1/Download/images/julia-1.4.2/usr/share/julia/stdlib/v1.4/Libdl/src/Libdl.jl:232
│  [4] top-level scope at /home/steiner/.julia/packages/Cxx/1RaOv/deps/build.jl:23
│  [5] include(::String) at ./client.jl:439
│  [6] top-level scope at none:5in expression starting at /home/steiner/.julia/packages/Cxx/1RaOv/deps/build.jl:23
│ writing path.jl file
│ Tuning for julia installation at /home/steiner/julia-1.4.2/bin with sources possibly at /home/steiner/
└ @ Pkg.Operations ~/disk/disk1/Download/images/julia-1.4.2/usr/share/julia/stdlib/v1.4/Pkg/src/Operations.jl:899
@nesteiner
Copy link
Author

by the way, it's useless after install some package about libllvm

@a-r-n-o-l-d
Copy link

I have the same problem. I think maybe the problem come from that linux is not take into account in builds.jl at line 20 : it looks for a shared library "libLLVM-8.0.1", but the file name is actually "libLLVM.so" in /opt/julia-1.4.2/lib/julia/.

Source of builds.jl :

# try to autodetect C++ ABI in use
llvm_path = Sys.iswindows() ? "LLVM" :
            Sys.isapple() ? "libLLVM" : "libLLVM-$(Base.libllvm_version)"
llvm_lib_path = Libdl.dlpath(llvm_path)
old_cxx_abi = findfirst("_ZN4llvm3sys16getProcessTripleEv", String(open(read, llvm_lib_path))) !== nothing
old_cxx_abi && (ENV["OLD_CXX_ABI"] = "1")

@Gnimuc
Copy link
Member

Gnimuc commented Jul 24, 2020

#464 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants