Closed emmt closed 3 months ago
does Clang.jl work properly after fixing the issue?
I'm a bit worried about the compatibility margin between Julia-1.6 and Ygg-JLL-BB2.
I did not tried the proposed fix because I was not sure of the purpose of get_system_shard_key
. In particular, if it is supposed to fail when platform_keys
is not an array with exactly one element, then my fix breaks this assumption. The other concern is: I choose the first element of platform_keys
because I assumed that it is as good as any other. But is this true?
It's the system shard key in the toml file: https://github.com/JuliaInterop/Clang.jl/blob/master/Artifacts.toml
I think this fix is ok: first(platform_keys)
but I'm not sure whether there are other compatibility issues. (your system Linux Ubuntu 23.04 is new but the gcc shipped with the system is probably missing in Ygg)
I have just tried the proposed fix. This works for Julia 1.6 with Clang 0.14.1
I can make a PR but I do not know how to propagate to other versions.
PR https://github.com/JuliaInterop/Clang.jl/pull/451 attempts to fix this.
I just noticed the root cause of the problem is that the Artifacts.toml
file is somehow broken, but the logic used in get_system_shard_key
assumes there should be only one matched entry...
With Julia-1.6.7 and Clang-0.14.1 on Linux Ubuntu 23.04, calling
get_default_args()
gives the following error :This is due to variable
platform_keys
inget_system_shard_key()
having more than one element and thusplatform_keys[]
fails with the above error.The code of
get_system_shard_key()
has not changed since Clang-0.14.0 (if I am correctly using git blame). I would suggest to fix this by using expression:instead of:
in function
get_system_shard_key
in filesrc/shards/JLLEnvs.jl
. But I am not sure that this would be correct...It would be nice to retroproagate the fix to older versions of Clang, at least to the 0.14 branch, to be able to use Clang with Julia-1.6.