JuliaHEP / Minuit2.jl

GNU Lesser General Public License v2.1
4 stars 1 forks source link

hm, `InitError: could not load library ` #3

Open mmikhasenko opened 3 years ago

mmikhasenko commented 3 years ago

installation works fine

] add Minuit2_Julia_Wrapper_jll
] add https://github.com/jstrube/Minuit2.jl

breaks at using

julia> using Minuit2
[ Info: Precompiling Minuit2 [37821647-3276-4ed8-9a4e-bc9886b3c106]
ERROR: LoadError: InitError: could not load library ".julia\artifacts\ec52bbf618cd9a6088d0dd72bccd400666585eff\bin\libMinuit2.dll"

any ideas?

jstrube commented 3 years ago

hmmm. Not sure. What julia version are you on? Looks like 1.5 or earlier. Can you try 1.6-rc1?

mmikhasenko commented 3 years ago

yes, it is v1.5.3. will try on v1.6, hope will be released soon

jstrube commented 3 years ago

Still weird, though. The error is related to the Minuit2 dll, which is built here: https://github.com/JuliaPackaging/Yggdrasil/blob/master/M/Minuit2/build_tarballs.jl

Does any of this look weird to you? Are there any tests that should be run at the end of the build process to help catch this issue? If you have a Minuit2 dll that you know works, you could try dropping that in instead...

mmikhasenko commented 3 years ago

Now, I remember asking something related to dll, BinaryBuilder and Windows at BinaryBuilder at slack sometime ago. I do not remember my question, but my conclusion from all replies was that it is an unsolved BinaryBuilder+Windows issue :(

jstrube commented 3 years ago

I see. I'm afraid I can't really help to debug this. Somehow, your system can't Libdl.dlopen the Minuit2 dll, it seems. Can you try running that command to see if it comes up with a better error message that you can google? Note that ] add Minuit2_Julia_Wrapper_jll should not be necessary. It's a dependency of Minuit2.jl, so it should automatically download the package. (It doesn't hurt to do it manually, though).

mmikhasenko commented 3 years ago

just tested: still the same problem

julia> using Minuit2                                                                                                    
[ Info: Precompiling Minuit2 [37821647-3276-4ed8-9a4e-bc9886b3c106]                                                     
ERROR: LoadError: InitError: could not load library
"C:\...\.julia\artifacts\ec52bbf618cd9a6088d0dd72bccd400666585eff\bin\libMinuit2.dll"                                                                                               
The specified procedure could not be found.                                                                             
mmikhasenko commented 3 years ago

the file libMinuit2.dll is there, but dlopen(s::String, flags::UInt32; throw_error::Bool) fails