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

dev_jll does not work on Julia v1.11 #73

Open
mattsignorelli opened this issue Dec 10, 2024 · 2 comments
Open

dev_jll does not work on Julia v1.11 #73

mattsignorelli opened this issue Dec 10, 2024 · 2 comments

Comments

@mattsignorelli
Copy link

The following works fine on Julia v1.10:

julia> versioninfo()
Julia Version 1.10.0
Commit 3120989f39b (2023-12-25 18:01 UTC)
Build Info:
  Official https://julialang.org/ release
Platform Info:
  OS: macOS (arm64-apple-darwin22.4.0)
  CPU: 24 × Apple M2 Ultra
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-15.0.7 (ORCJIT, apple-m1)
  Threads: 1 on 16 virtual cores
Environment:
  DYLD_FALLBACK_LIBRARY_PATH = /Users/mgs255/Software/bmad/bmad-ecosystem/production/lib:/Users/mgs255/Software/bmad/bmad-ecosystem/debug/lib
  LD_LIBRARY_PATH = /Users/mgs255/Software/bmad/bmad-ecosystem/production/lib:/Users/mgs255/Software/bmad/bmad-ecosystem/debug/lib

julia> import GTPSA_jll

julia> GTPSA_jll.dev_jll();

It does not work on the latest Julia v1.11:

julia> versioninfo()
Julia Version 1.11.2
Commit 5e9a32e7af2 (2024-12-01 20:02 UTC)
Build Info:
  Official https://julialang.org/ release
Platform Info:
  OS: macOS (arm64-apple-darwin24.0.0)
  CPU: 24 × Apple M2 Ultra
  WORD_SIZE: 64
  LLVM: libLLVM-16.0.6 (ORCJIT, apple-m2)
Threads: 1 default, 0 interactive, 1 GC (on 16 virtual cores)
Environment:
  DYLD_FALLBACK_LIBRARY_PATH = /Users/mgs255/Software/bmad/bmad-ecosystem/production/lib:/Users/mgs255/Software/bmad/bmad-ecosystem/debug/lib
  LD_LIBRARY_PATH = /Users/mgs255/Software/bmad/bmad-ecosystem/production/lib:/Users/mgs255/Software/bmad/bmad-ecosystem/debug/lib

julia> import GTPSA_jll

julia> GTPSA_jll.dev_jll()
ERROR: ArgumentError: collection must be non-empty
Stacktrace:
 [1] first(itr::Dict{Base.PkgId, Module})
   @ Base ./abstractarray.jl:473
 [2] dev_jll(src_name::Any)
   @ JLLWrappers ~/.julia/packages/JLLWrappers/jXOYx/src/runtime.jl:55
 [3] invokelatest(::Any, ::Any, ::Vararg{Any}; kwargs::@Kwargs{})
   @ Base ./essentials.jl:1055
 [4] invokelatest(::Any, ::Any, ::Vararg{Any})
   @ Base ./essentials.jl:1052
 [5] dev_jll()
   @ GTPSA_jll ~/.julia/packages/JLLWrappers/jXOYx/src/toplevel_generators.jl:93
 [6] top-level scope
   @ REPL[3]:1

I also tested v1.11.0 and same error

@giordano giordano transferred this issue from JuliaPackaging/BinaryBuilder.jl Dec 10, 2024
@giordano
Copy link
Member

Pkg = first(filter(p-> p[1].name == "Pkg", Base.loaded_modules))[2]

julia> first(filter(p-> p[1].name == "Pkg", Base.loaded_modules))
ERROR: ArgumentError: collection must be non-empty
Stacktrace:
 [1] first(itr::Dict{Base.PkgId, Module})
   @ Base ./abstractarray.jl:473
 [2] top-level scope
   @ REPL[12]:1

@giordano
Copy link
Member

As a temporary work-around you can manually do using Pkg before running the dev_jll function, but probably we need a better way to deal with this than relying on Pkg magically be loaded in the environment. I'm not really into this code loading shenanigans though.

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

2 participants