Very similar to #54, but technically a different problem since it's the 2-argument (fn, lib) tuple form that is problematic:
julia> using LibCURL_jll: libcurl
julia> JuliaLowering.include_string(Main, raw"""
function curl_version_info(arg1)
ccall((:curl_version_info, libcurl), Ptr{Cvoid}, (UInt32,), arg1)
end
""")
julia> curl_version_info(UInt32(5))
ERROR: TypeError: in ccall: first argument not a pointer or valid constant expression, expected Ptr, got a value of type Tuple{Symbol, Base.Libc.Libdl.LazyLibrary}
This probably became an issue with JuliaLang/julia#59165.
That PR cleaned up the usage of static_eval in codegen by making this a syntactic opt-in, but it seems like it needs a "forward-port" to JS / JL to use the 2-tuple syntax - @mlechu can you take care of that?