-
Notifications
You must be signed in to change notification settings - Fork 0
Description
CUDA_Driver_jll currently abuses the JLL init hook to not only execute code at load time, but also define auxiliary functionality: https://github.com/JuliaPackaging/Yggdrasil/blob/a3649ece56eb711f060ade7aa07eaa65a315ed23/C/CUDA/CUDA_Driver/init.jl#L34-L58
However, the CUDA_Driver_jll is also used to provide a library that isn't available for all platforms. Because of the JLL init hook currently only being executed when an artifact is available, JuliaPackaging/JLLWrappers.jl#50, this currently necessitates duplicating the aforementioned auxiliary functionality for when the JLL is not available: JuliaPackaging/Yggdrasil#5751
Given the new design of the on_load_callback
, which is hard to generalize to the case when an artifact is not available, it may be better to provide a toplevel_code
setting or so that allows users to inject code into the JLL package that will be available at all time, i.e., also when no artifact is available. This would allow us to reliably add functionality to JLLs.