JuliaGraphics / QML.jl

Build Qt6 QML interfaces for Julia programs.
Other
386 stars 35 forks source link

QML.jl fails to precompile on Julia 1.8-rc4 #146

Closed cmey closed 2 years ago

cmey commented 2 years ago

Hello, thanks for this package, it works very well on Julia 1.7 :muscle:

but on Julia 1.8-rc1 (edit: also still on rc3, and rc4) it fails to precompile with: ERROR: LoadError: ccall method definition: argument 2 type doesn't correspond to a C type.

julia> versioninfo()
Julia Version 1.8.0-rc1
Commit 6368fdc656 (2022-05-27 18:33 UTC)
Platform Info:
  OS: Linux (x86_64-pc-linux-gnu)
  CPU: 16 × Intel(R) Core(TM) i9-9900K CPU @ 3.60GHz
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-13.0.1 (ORCJIT, skylake)
  Threads: 1 on 16 virtual cores

Complete log to reproduce:

(qml-work) pkg> add QML
    Updating registry at `~/.julia/registries/General.toml`
   Resolving package versions...
    Updating `~/Code/julia/qml-work/Project.toml`
  [2db162a6] + QML v0.7.1
    Updating `~/Code/julia/qml-work/Manifest.toml`
  [3da002f7] + ColorTypes v0.11.4
  [1f15a43c] + CxxWrap v0.12.0
  [53c48c17] + FixedPointNumbers v0.8.4
  [692b3bcd] + JLLWrappers v1.4.1
  [1914dd2f] + MacroTools v0.5.9
⌅ [510215fc] + Observables v0.4.0
  [21216c6a] + Preferences v1.3.0
  [2db162a6] + QML v0.7.1
  [ae029012] + Requires v1.3.0
  [6e34b625] + Bzip2_jll v1.0.8+0
  [2e619515] + Expat_jll v2.4.8+0
  [a3f928ae] + Fontconfig_jll v2.13.93+0
  [d7e528f0] + FreeType2_jll v2.10.4+0
  [78b55507] + Gettext_jll v0.21.0+0
  [7746bdde] + Glib_jll v2.68.3+2
  [e9f186c6] + Libffi_jll v3.2.2+1
  [d4300ac3] + Libgcrypt_jll v1.8.7+0
  [7e76a0d4] + Libglvnd_jll v1.3.0+3
  [7add5ba3] + Libgpg_error_jll v1.42.0+0
  [94ce4f54] + Libiconv_jll v1.16.1+1
  [4b2f31a3] + Libmount_jll v2.35.0+0
  [38a345b3] + Libuuid_jll v2.36.0+0
  [78dcde23] + Mesa_jll v20.1.5+2
  [458c3c95] + OpenSSL_jll v1.1.17+0
  [2f80f16e] + PCRE_jll v8.44.0+0
  [ea2cea3b] + Qt5Base_jll v5.15.3+1
  [c6373c32] + Qt5Declarative_jll v5.15.3+0
  [3af4ccab] + Qt5Svg_jll v5.15.3+0
  [a2964d1f] + Wayland_jll v1.19.0+0
  [2381bf8a] + Wayland_protocols_jll v1.25.0+0
  [02c8fc9c] + XML2_jll v2.9.14+0
  [aed1982a] + XSLT_jll v1.1.34+0
  [4f6342f7] + Xorg_libX11_jll v1.6.9+4
  [0c0b7dd1] + Xorg_libXau_jll v1.0.9+4
  [a3789734] + Xorg_libXdmcp_jll v1.1.3+4
  [1082639a] + Xorg_libXext_jll v1.3.4+4
  [14d82f49] + Xorg_libpthread_stubs_jll v0.1.0+3
  [c7cfdc94] + Xorg_libxcb_jll v1.13.0+3
  [cc61e674] + Xorg_libxkbfile_jll v1.1.0+4
  [12413925] + Xorg_xcb_util_image_jll v0.4.0+1
  [2def613f] + Xorg_xcb_util_jll v0.4.0+1
  [975044d2] + Xorg_xcb_util_keysyms_jll v0.4.0+1
  [0d47668e] + Xorg_xcb_util_renderutil_jll v0.3.9+1
  [c22f9ab0] + Xorg_xcb_util_wm_jll v0.4.1+1
  [35661453] + Xorg_xkbcomp_jll v1.4.2+4
  [33bec58e] + Xorg_xkeyboard_config_jll v2.27.0+4
  [c5fb5394] + Xorg_xtrans_jll v1.4.0+3
⌅ [6b5019fb] + jlqml_jll v0.3.0+1
  [3eaa8342] + libcxxwrap_julia_jll v0.9.1+0
  [d8fb68d0] + xkbcommon_jll v0.9.1+5
  [0dad84c5] + ArgTools v1.1.1
  [56f22d72] + Artifacts
  [2a0f44e3] + Base64
  [ade2ca70] + Dates
  [f43a241f] + Downloads v1.6.0
  [7b1f6079] + FileWatching
  [b77e0a4c] + InteractiveUtils
  [b27032c2] + LibCURL v0.6.3
  [76f85450] + LibGit2
  [8f399da3] + Libdl
  [37e2e46d] + LinearAlgebra
  [56ddb016] + Logging
  [d6f4376e] + Markdown
  [ca575930] + NetworkOptions v1.2.0
  [44cfe95a] + Pkg v1.8.0
  [de0858da] + Printf
  [3fa0cd96] + REPL
  [9a3f8284] + Random
  [ea8e919c] + SHA v0.7.0
  [9e88b42a] + Serialization
  [6462fe0b] + Sockets
  [2f01184e] + SparseArrays
  [10745b16] + Statistics
  [fa267f1f] + TOML v1.0.0
  [a4e569a6] + Tar v1.10.0
  [cf7118a7] + UUIDs
  [4ec0a83e] + Unicode
  [e66e0078] + CompilerSupportLibraries_jll v0.5.2+0
  [deac9b47] + LibCURL_jll v7.81.0+0
  [29816b5a] + LibSSH2_jll v1.10.2+0
  [c8ffd9c3] + MbedTLS_jll v2.28.0+0
  [14a3606d] + MozillaCACerts_jll v2022.2.1
  [4536629a] + OpenBLAS_jll v0.3.20+0
  [83775a58] + Zlib_jll v1.2.12+3
  [8e850b90] + libblastrampoline_jll v5.1.0+0
  [8e850ede] + nghttp2_jll v1.41.0+1
  [3f19e933] + p7zip_jll v17.4.0+0
        Info Packages marked with ⌅ have new versions available but cannot be upgraded. To see why use `status --outdated`
Precompiling project...
  ✗ QML
  0 dependencies successfully precompiled in 3 seconds. 55 already precompiled.
  1 dependency errored. To see a full report either run `import Pkg; Pkg.precompile()` or load the package

julia> import QML
[ Info: Precompiling QML [2db162a6-7e43-52c3-8d84-290c1c42d82a]
ERROR: LoadError: ccall method definition: argument 2 type doesn't correspond to a C type
Stacktrace:
 [1] top-level scope
   @ none:1
 [2] eval
   @ ./boot.jl:368 [inlined]
 [3] wrap_functions(functions::Vector{CxxWrap.CxxWrapCore.CppFunctionInfo}, julia_mod::Module)
   @ CxxWrap.CxxWrapCore ~/.julia/packages/CxxWrap/ptbgM/src/CxxWrap.jl:696
 [4] wrapfunctions(jlmod::Module)
   @ CxxWrap.CxxWrapCore ~/.julia/packages/CxxWrap/ptbgM/src/CxxWrap.jl:713
 [5] top-level scope
   @ ~/.julia/packages/QML/QJmAc/src/QML.jl:36
 [6] include
   @ ./Base.jl:422 [inlined]
 [7] include_package_for_output(pkg::Base.PkgId, input::String, depot_path::Vector{String}, dl_load_path::Vector{String}, load_path::Vector{String}, concrete_deps::Vector{Pair{Base.PkgId, UInt64}}, source::Nothing)
   @ Base ./loading.jl:1407
 [8] top-level scope
   @ stdin:1
in expression starting at /home/cmey/.julia/packages/QML/QJmAc/src/QML.jl:1
in expression starting at stdin:1
ERROR: Failed to precompile QML [2db162a6-7e43-52c3-8d84-290c1c42d82a] to /home/cmey/.julia/compiled/v1.8/QML/jl_lmOfNw.
cmey commented 2 years ago

Also on rc3

ufechner7 commented 2 years ago

Same problem on Ubuntu 20.04.

cmey commented 2 years ago

Still erroring on julia-1.8.0-rc4

jheinen commented 2 years ago

Can be fixed by installing the CxxWrap main branch: [ add CxxWrap#main.

@barche : CxxWrap should probably be tagged for compatibility with Julia 1.8.

barche commented 2 years ago

Yes, sorry I missed this. I'll tag a release if nothing unexpected happens in the tests here: https://github.com/JuliaInterop/CxxWrap.jl/pull/324

jheinen commented 2 years ago

Works! Thanks @barche

barche commented 2 years ago

Done, should be OK now!

cmey commented 2 years ago

Yes fixed now :heavy_check_mark: thank you both!