Compiling Qcad with QT6 under Linux

How do I compile Qcad with QT6 under Linux?

I read QCAD - QCAD but this only contains instructions for QT6 under Windows or QT5 under Linux.

Specifically, I have the following questions:

  1. Do I also have to clone qtjsapi and qcadjsapi for Qt6 under Linux or is this Windows only?
  2. Which packages do I need as dependencies? (I am running Gentoo. I do not expect someone to know the Gentoo Packages, Debian packages would be fine, too. I will look up the corresponding Gentoo packages myself.)
  3. How do I set BUILD_QT6=ON? Are the CMake scripts actually necessary under Linux? The Linux instructions for Qt5 seem to use qmake and traditional make only.
  4. The instructions for Qt5 under Linux first list package dependencies for various distribution, but then step 2 asks to download Qt5 from the QT upstream website. This seems odd. Is the indentation wrong? I guess this is actually an alternative for step 1, right?

Hello

I updated QCAD for Qt6 for NetBSD recently (not Linux, but..), see Making sure you're not a bot!

  1. Yes, I did that
  2. If you run cmake it will tell you what it is missing - I used qtbase, qtdeclarative, qttools, qtsvg, qt5compat there are also some optional requirements
  3. cmake -DBUILD_QT6=ON
  4. perhaps the instructions are not yet updated

Compilation and linking works, but qcad-bin crashes with

CAD version  3.32.2
20:13:22: Debug:    loading plugins...
20:13:22: Debug:    loading static plugins...
Warning:  No script handler found...
Warning:  QThreadStorage: Thread 0x55efee092310 exited after QThreadStorage 8 destroyed
Warning:  QThreadStorage: Thread 0x55efee092310 exited after QThreadStorage 6 destroyed
Warning:  QThreadStorage: Thread 0x55efee092310 exited after QThreadStorage 1 destroyed

I found the solution. I posted it in Building on Gentoo with recent Qt - QCAD Community Edition - QCAD Forum