Bug 500345 - plasma-desktop fails build on calibrationtool with some compilers
Summary: plasma-desktop fails build on calibrationtool with some compilers
Status: RESOLVED FIXED
Alias: None
Product: plasma-integration
Classification: Plasma
Component: general (other bugs)
Version First Reported In: 6.3.1
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-02-18 19:55 UTC by Taurnil
Modified: 2025-02-19 11:20 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Taurnil 2025-02-18 19:55:05 UTC
Was unsure which product to choose since you don't have one specifically for plasma-desktop, so feel free to move this appropriately.

[ 87%] Building CXX object kcms/touchpad/kded/CMakeFiles/kded_touchpad.dir/__/backends/kwin_wayland/kwinwaylandbackend.cpp.o
In file included from /usr/src/plasma-desktop-6.3.1/kcms/touchpad/backends/kwin_wayland/kwinwaylandbackend.h:9,
                 from /usr/src/plasma-desktop-6.3.1/kcms/touchpad/backends/kwin_wayland/kwinwaylandbackend.cpp:7:
/usr/src/plasma-desktop-6.3.1/kcms/touchpad/touchpadbackend.h:56:18: warning: 'virtual bool TouchpadBackend::getConfig(QVariantHash&)' was hidden [-Woverloaded-virtual=]
   56 |     virtual bool getConfig(QVariantHash &)
      |                  ^~~~~~~~~
/usr/src/plasma-desktop-6.3.1/kcms/touchpad/backends/kwin_wayland/kwinwaylandbackend.h:24:10: note:   by 'virtual bool KWinWaylandBackend::getConfig()'
   24 |     bool getConfig() override;
      |          ^~~~~~~~~
/usr/src/plasma-desktop-6.3.1/kcms/touchpad/touchpadbackend.h:52:18: warning: 'virtual bool TouchpadBackend::applyConfig(const QVariantHash&)' was hidden [-Woverloaded-virtual=]
   52 |     virtual bool applyConfig(const QVariantHash &)
      |                  ^~~~~~~~~~~
/usr/src/plasma-desktop-6.3.1/kcms/touchpad/backends/kwin_wayland/kwinwaylandbackend.h:23:10: note:   by 'virtual bool KWinWaylandBackend::applyConfig()'
   23 |     bool applyConfig() override;
      |          ^~~~~~~~~~~
[ 88%] Building CXX object kcms/touchpad/kded/CMakeFiles/kded_touchpad.dir/__/backends/kwin_wayland/kwinwaylandtouchpad.cpp.o
[ 88%] Building CXX object kcms/touchpad/kded/CMakeFiles/kded_touchpad.dir/__/backends/x11/propertyinfo.cpp.o
[ 88%] Building CXX object kcms/touchpad/kded/CMakeFiles/kded_touchpad.dir/__/backends/x11/xlibbackend.cpp.o
[ 88%] Building CXX object kcms/touchpad/kded/CMakeFiles/kded_touchpad.dir/__/backends/x11/xlibtouchpad.cpp.o
[ 88%] Building CXX object kcms/touchpad/kded/CMakeFiles/kded_touchpad.dir/__/backends/x11/xcbatom.cpp.o
[ 88%] Building CXX object kcms/touchpad/kded/CMakeFiles/kded_touchpad.dir/__/backends/x11/xlibnotifications.cpp.o
[ 88%] Building CXX object kcms/touchpad/kded/CMakeFiles/kded_touchpad.dir/__/backends/x11/libinputtouchpad.cpp.o
[ 88%] Linking CXX shared module ../../../bin/kf6/kded/kded_touchpad.so
[ 88%] Built target kded_touchpad
[ 88%] Built target kcm_tablet-kcm-desktop-gen
[ 89%] Generating qwayland-tablet-unstable-v2.cpp
[ 89%] Generating qwayland-tablet-unstable-v2.h
[ 89%] Generating wayland-tablet-unstable-v2-client-protocol.h
[ 89%] Generating wayland-tablet-unstable-v2-protocol.c
[ 89%] Built target kcm_tablet_autogen_timestamp_deps
[ 89%] Automatic MOC for target kcm_tablet
AutoMoc warning
---------------
"SRC:/kcms/tablet/calibrationtool.cpp"
includes the moc file "calibrationtool.moc", but does not contain a Q_OBJECT, Q_GADGET, Q_NAMESPACE, Q_NAMESPACE_EXPORT, Q_GADGET_EXPORT, Q_ENUM_NS, K_PLUGIN_FACTORY, K_PLUGIN_CLASS, K_PLUGIN_FACTORY_WITH_JSON or K_PLUGIN_CLASS_WITH_JSON macro.

AutoMoc: /usr/src/plasma-desktop-6.3.1/kcms/tablet/calibrationtool.cpp: note: No relevant classes found. No output generated.
[ 89%] Built target kcm_tablet_autogen
[ 89%] Generating qrc_kcm_tablet.cpp
[ 89%] Building CXX object kcms/tablet/CMakeFiles/kcm_tablet.dir/kcm_tablet_autogen/mocs_compilation.cpp.o
[ 89%] Building CXX object kcms/tablet/CMakeFiles/kcm_tablet.dir/qrc_kcm_tablet.cpp.o
[ 90%] Building CXX object kcms/tablet/CMakeFiles/kcm_tablet.dir/logging.cpp.o
[ 90%] Building C object kcms/tablet/CMakeFiles/kcm_tablet.dir/wayland-tablet-unstable-v2-protocol.c.o
[ 90%] Building CXX object kcms/tablet/CMakeFiles/kcm_tablet.dir/qwayland-tablet-unstable-v2.cpp.o
[ 90%] Building CXX object kcms/tablet/CMakeFiles/kcm_tablet.dir/kcmtablet.cpp.o
/usr/src/plasma-desktop-6.3.1/kcms/tablet/kcmtablet.cpp: In member function 'void StylusButtonsModel::recalculateItems()':
/usr/src/plasma-desktop-6.3.1/kcms/tablet/kcmtablet.cpp:241:64: warning: 'const int* libwacom_get_supported_styli(const WacomDevice*, int*)' is deprecated [-Wdeprecated-declarations]
  241 |                 const int *styli = libwacom_get_supported_styli(device, &num_styli);
      |                                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~
In file included from /usr/src/plasma-desktop-6.3.1/kcms/tablet/kcmtablet.h:14,
                 from /usr/src/plasma-desktop-6.3.1/kcms/tablet/kcmtablet.cpp:7:
/usr/include/libwacom-1.0/libwacom/libwacom.h:678:12: note: declared here
  678 | const int *libwacom_get_supported_styli(const WacomDevice *device, int *num_styli);
      |            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/src/plasma-desktop-6.3.1/kcms/tablet/kcmtablet.cpp:243:67: warning: 'const WacomStylus* libwacom_stylus_get_for_id(const WacomDeviceDatabase*, int)' is deprecated [-Wdeprecated-declarations]
  243 |                     const auto stylus = libwacom_stylus_get_for_id(m_db, styli[0]);
      |                                         ~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~
/usr/include/libwacom-1.0/libwacom/libwacom.h:879:20: note: declared here
  879 | const WacomStylus *libwacom_stylus_get_for_id (const WacomDeviceDatabase *db, int id);
      |                    ^~~~~~~~~~~~~~~~~~~~~~~~~~
[ 90%] Building CXX object kcms/tablet/CMakeFiles/kcm_tablet.dir/tabletevents.cpp.o
[ 90%] Building CXX object kcms/tablet/CMakeFiles/kcm_tablet.dir/calibrationtool.cpp.o
[ 90%] Building CXX object kcms/tablet/CMakeFiles/kcm_tablet.dir/inputsequence.cpp.o
[ 90%] Building CXX object kcms/tablet/CMakeFiles/kcm_tablet.dir/tabletsmodel.cpp.o
[ 90%] Linking CXX shared module ../../bin/plasma/kcms/systemsettings/kcm_tablet.so
/usr/bin/ld: CMakeFiles/kcm_tablet.dir/calibrationtool.cpp.o: in function `CalibrationTool::setCalibrationMatrix(InputDevice*, QMatrix4x4 const&)':
calibrationtool.cpp:(.text+0x312): undefined reference to `InputDevice::Prop<QString>::save()'
/usr/bin/ld: CMakeFiles/kcm_tablet.dir/calibrationtool.cpp.o: in function `CalibrationTool::restoreDefaults(InputDevice*)':
calibrationtool.cpp:(.text+0xc48): undefined reference to `InputDevice::Prop<QString>::save()'
collect2: error: ld returned 1 exit status
make[2]: *** [kcms/tablet/CMakeFiles/kcm_tablet.dir/build.make:293: bin/plasma/kcms/systemsettings/kcm_tablet.so] Error 1
make[1]: *** [CMakeFiles/Makefile2:26733: kcms/tablet/CMakeFiles/kcm_tablet.dir/all] Error 2
make: *** [Makefile:136: all] Error 2


Operating System: Lunar Linux 1.8.0-daily-20250210-x86_64
KDE Plasma Version: 6.3.1
KDE Frameworks Version: 6.11.0
Qt Version: 6.8.2
Kernel Version: 6.13.2 (64-bit)
Graphics Platform: X11
Processors: 12 × Intel® Core™ i7 CPU       X 980  @ 3.33GHz
Memory: 15.6 GiB of RAM
Graphics Processor: NVIDIA GeForce RTX 3060/PCIe/SSE2
Comment 1 Nate Graham 2025-02-18 20:19:22 UTC
It builds fine for me and on our CI, which means this is a local issue on your system.

Bugzilla isn't the place to ask for help with build issues; I'd recommend getting in touch using one of these methods: https://community.kde.org/Get_Involved/development#Where_to_find_the_development_team
Comment 3 Nate Graham 2025-02-18 21:06:26 UTC
Oh! I guess it is a real issue then.
Comment 4 Fabio 2025-02-18 21:10:04 UTC
Getting the same problem on Slackware64-current:
---
[ 84%] Built target kded_touchpad_autogen
[ 85%] Built target kded_touchpad
[ 85%] Built target kcm_tablet-kcm-desktop-gen
[ 86%] Built target kcm_tablet_autogen_timestamp_deps
[ 86%] Built target kcm_tablet_autogen
[ 86%] Linking CXX shared module ../../bin/plasma/kcms/systemsettings/kcm_tablet.so
/usr/bin/ld: CMakeFiles/kcm_tablet.dir/calibrationtool.cpp.o: in function `CalibrationTool::setCalibrationMatrix(InputDevice*, QMatrix4x4 const&)':
calibrationtool.cpp:(.text+0x335): undefined reference to `InputDevice::Prop<QString>::save()'
/usr/bin/ld: CMakeFiles/kcm_tablet.dir/calibrationtool.cpp.o: in function `CalibrationTool::restoreDefaults(InputDevice*)':
calibrationtool.cpp:(.text+0xc78): undefined reference to `InputDevice::Prop<QString>::save()'
collect2: error: ld returned 1 exit status
make[2]: *** [kcms/tablet/CMakeFiles/kcm_tablet.dir/build.make:296: bin/plasma/kcms/systemsettings/kcm_tablet.so] Error 1
make[1]: *** [CMakeFiles/Makefile2:33494: kcms/tablet/CMakeFiles/kcm_tablet.dir/all] Error 2
make: *** [Makefile:136: all] Error 2
---
Comment 5 Joshua Goins 2025-02-18 23:22:05 UTC
Git commit 7e4068c7e8c3f78914a223bf98af35a5e32269a0 by Joshua Goins, on behalf of Ilya Katsnelson.
Committed on 18/02/2025 at 23:21.
Pushed by redstrate into branch 'master'.

kcms/libkwindevices: put template functions in the header

Otherwise some compilers will get confused and fail with nonsensical linking errors.

Discovered while building 6.3.1 on NixOS, and should probably be backported.

M  +1    -1    kcms/libkwindevices/CMakeLists.txt
M  +1    -1    kcms/libkwindevices/devicesmodel.cpp
M  +0    -40   kcms/libkwindevices/inputdevice.cpp
M  +36   -4    kcms/libkwindevices/inputdevice.h

https://invent.kde.org/plasma/plasma-desktop/-/commit/7e4068c7e8c3f78914a223bf98af35a5e32269a0
Comment 6 Joshua Goins 2025-02-18 23:54:39 UTC
Git commit 92c6c30f02746dfe82538dc33a051b531c5e4e54 by Joshua Goins, on behalf of Ilya Katsnelson.
Committed on 18/02/2025 at 23:24.
Pushed by redstrate into branch 'Plasma/6.3'.

kcms/libkwindevices: put template functions in the header

Otherwise some compilers will get confused and fail with nonsensical linking errors.

Discovered while building 6.3.1 on NixOS, and should probably be backported.
(cherry picked from commit 7e4068c7e8c3f78914a223bf98af35a5e32269a0)

M  +1    -1    kcms/libkwindevices/CMakeLists.txt
M  +1    -1    kcms/libkwindevices/devicesmodel.cpp
M  +0    -40   kcms/libkwindevices/inputdevice.cpp
M  +36   -4    kcms/libkwindevices/inputdevice.h

https://invent.kde.org/plasma/plasma-desktop/-/commit/92c6c30f02746dfe82538dc33a051b531c5e4e54
Comment 7 白川間瀬流 2025-02-19 08:30:08 UTC
So for maybe asking a stupid question. This bug is fixed in the current 6.3.1 tarball or is it necessary to apply the patch manually?
Comment 8 白川間瀬流 2025-02-19 11:20:03 UTC
6.3.1.1 is out which fixes this, so that answers my question^^