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

ArrayFire cannot load libaf.so.3 #276

Closed
thprfssr opened this issue Feb 15, 2021 · 4 comments
Closed

ArrayFire cannot load libaf.so.3 #276

thprfssr opened this issue Feb 15, 2021 · 4 comments

Comments

@thprfssr
Copy link

After installing ArrayFire in Julia's interactive package manager, I did test ArrayFire, and it gave me the following output:

(@v1.5) pkg> test ArrayFire
    Testing ArrayFire
Status `/tmp/jl_nKRndk/Project.toml`
  [b19378d9] ArrayFire v1.0.7
  [717857b8] DSP v0.6.10
  [7a1cc6ca] FFTW v1.3.2
  [276daf66] SpecialFunctions v0.10.3
  [8f399da3] Libdl
  [37e2e46d] LinearAlgebra
  [9a3f8284] Random
  [2f01184e] SparseArrays
  [10745b16] Statistics
  [8dfed614] Test
Status `/tmp/jl_nKRndk/Manifest.toml`
  [621f4979] AbstractFFTs v1.0.0
  [79e6a3ab] Adapt v3.2.0
  [b19378d9] ArrayFire v1.0.7
  [56f22d72] Artifacts v1.3.0
  [e66e0078] CompilerSupportLibraries_jll v0.3.4+0
  [717857b8] DSP v0.6.10
  [e2ba6199] ExprTools v0.1.3
  [8f5d6c58] EzXML v1.1.0
  [7a1cc6ca] FFTW v1.3.2
  [f5851436] FFTW_jll v3.3.9+7
  [1d5cc7b8] IntelOpenMP_jll v2018.0.3+2
  [d8418881] Intervals v1.5.0
  [c8e1da08] IterTools v1.3.0
  [692b3bcd] JLLWrappers v1.2.0
  [4af54fe1] LazyArtifacts v1.3.0
  [94ce4f54] Libiconv_jll v1.16.0+7
  [856f044c] MKL_jll v2021.1.1+1
  [78c3b35d] Mocking v0.7.1
  [6fe1bfb0] OffsetArrays v1.5.3
  [efe28fd5] OpenSpecFun_jll v0.5.3+4
  [f27b6e38] Polynomials v1.2.0
  [3cdcf5f2] RecipesBase v1.1.1
  [189a3867] Reexport v1.0.0
  [276daf66] SpecialFunctions v0.10.3
  [f269a46b] TimeZones v1.5.3
  [02c8fc9c] XML2_jll v2.9.10+3
  [83775a58] Zlib_jll v1.2.11+18
  [2a0f44e3] Base64
  [ade2ca70] Dates
  [8ba89e20] Distributed
  [b77e0a4c] InteractiveUtils
  [76f85450] LibGit2
  [8f399da3] Libdl
  [37e2e46d] LinearAlgebra
  [56ddb016] Logging
  [d6f4376e] Markdown
  [44cfe95a] Pkg
  [de0858da] Printf
  [3fa0cd96] REPL
  [9a3f8284] Random
  [ea8e919c] SHA
  [9e88b42a] Serialization
  [6462fe0b] Sockets
  [2f01184e] SparseArrays
  [10745b16] Statistics
  [8dfed614] Test
  [cf7118a7] UUIDs
  [4ec0a83e] Unicode
ERROR: LoadError: InitError: could not load library "libaf.so.3"
libaf.so.3: cannot open shared object file: No such file or directory
Stacktrace:
 [1] dlopen at /build/julia/src/julia-1.5.3/usr/share/julia/stdlib/v1.5/Libdl/src/Libdl.jl:109 [inlined] (repeats 2 times)
 [2] __init__() at /home/javier/.julia/packages/ArrayFire/U0hth/src/util.jl:59
 [3] include(::String) at ./client.jl:457
 [4] top-level scope at none:6
during initialization of module ArrayFire
in expression starting at /home/javier/.julia/packages/ArrayFire/U0hth/test/runtests.jl:1
ERROR: Package ArrayFire errored during testing

How can I fix that error?

@ghost
Copy link

ghost commented Feb 16, 2021

You need to install ArrayFire library, it is not included with the package.

@thprfssr
Copy link
Author

So, I have installed the package as you suggested. I have Arch Linux, so I ran sudo pacman -S arrayfire. But Julia still complained when I tried to use the package:

julia> using ArrayFire
ERROR: InitError: could not load library "libaf.so.3"
libOpenCL.so.1: cannot open shared object file: No such file or directory
Stacktrace:
 [1] dlopen at /build/julia/src/julia-1.5.3/usr/share/julia/stdlib/v1.5/Libdl/src/Libdl.jl:109 [inlined] (repeats 2 times)
 [2] __init__() at /home/javier/.julia/packages/ArrayFire/U0hth/src/util.jl:59
 [3] run_repl(::REPL.AbstractREPL, ::Any) at /build/julia/src/julia-1.5.3/usr/share/julia/stdlib/v1.5/REPL/src/REPL.jl:288
during initialization of module ArrayFire

@ghost
Copy link

ghost commented Feb 16, 2021

libOpenCL.so.1: cannot open shared object file: No such file or directory

Now it fails to load OpenCL libraries.

@thprfssr
Copy link
Author

Thank you! I fixed it by installing the OpenCL ICD loader implementation, with
sudo pacman -S ocl-icd

Cheers!

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

1 participant