Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 836361 - [kde overlay] kde-frameworks/kconfigwidgets-9999: hardcode current USE=auth option?
Summary: [kde overlay] kde-frameworks/kconfigwidgets-9999: hardcode current USE=auth o...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Overlays (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo KDE team
URL: https://bugs.kde.org/show_bug.cgi?id=...
Whiteboard:
Keywords:
Depends on: 835580 835581 835584
Blocks:
  Show dependency tree
 
Reported: 2022-03-29 08:41 UTC by Duncan
Modified: 2022-08-07 16:30 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Duncan 2022-03-29 08:41:03 UTC
Recently several kde packages added usage of new kauth headers such that they now require kconfigwidgets[auth] and won't build with USE=-auth.  Among these packages are kwin (see cf6cc5165, tho I didn't bisect to these specific commits but they look to be the ones based on the commits and the errors), systemsettings (1c004d6c6), plasma-desktop (67ded113d)... Those are the ones I remember that smart-live-rebuild wanted to rebuild but couldn't.  There are likely others I don't remember or don't have merged, but I do know it's not /all/ the kconfigwidgets revdeps as some still build/run with a USE=-auth kconfigwidgets.


So I'm wondering.  Is it worth adding the kconfigwidgets[auth] to the deps in multiple ebuilds, or since it seems upstream's now assuming/requiring it in multiple places it didn't before, maybe just hard-code the current USE=auth in kconfigwidgets itself and not have to worry about the use-dep.

Tho I see it is already IUSE=+auth, but despite that it wasn't required for those builds before.

If you decide to do the individual package fixes and want me to file the individual bugs, I can, but there are likely others I missed...

Here's what the errors look like when kconfigwidgets is build with USE=-auth, this one from systemsettings.  Again, they build fine with kconfigwidgets build with USE=auth:

FAILED: core/CMakeFiles/systemsettingsview.dir/ModuleView.cpp.o 
/usr/lib/ccache/bin/x86_64-pc-linux-gnu-g++ -DKCONFIGWIDGETS_NO_KAUTH -DKCOREADDONS_LIB -DKF_DISABLE_DEPRECATED_BEFORE_AND_AT=0x055700 -DQT_CORE_LIB -DQT_DBUS_LIB -DQT_DISABLE_DEPRECATED_BEFORE=0x050f02 -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_NO_CAST_FROM_ASCII -DQT_NO_CAST_TO_ASCII -DQT_NO_DEBUG -DQT_NO_URL_CAST_FROM_STRING -DQT_USE_QSTRINGBUILDER -DQT_WIDGETS_LIB -DQT_XML_LIB -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -Dsystemsettingsview_EXPORTS -I/tmp/portage/kde-plasma/systemsettings-9999/work/systemsettings-9999_build/core -I/tmp/portage/kde-plasma/systemsettings-9999/work/systemsettings-9999/core -I/tmp/portage/kde-plasma/systemsettings-9999/work/systemsettings-9999_build/core/systemsettingsview_autogen/include -isystem /usr/include/KF5/KItemViews -isystem /usr/include/KF5 -isystem /usr/include/qt5 -isystem /usr/include/qt5/QtWidgets -isystem /usr/include/qt5/QtGui -isystem /usr/include/qt5/QtCore -isystem /usr/lib64/qt5/mkspecs/linux-g++ -isystem /usr/include/KF5/KCMUtils -isystem /usr/include/KF5/KConfigWidgets -isystem /usr/include/KF5/KCodecs -isystem /usr/include/KF5/KWidgetsAddons -isystem /usr/include/KF5/KConfig -isystem /usr/include/KF5/KConfigGui -isystem /usr/include/qt5/QtXml -isystem /usr/include/KF5/KConfigCore -isystem /usr/include/KF5/KService -isystem /usr/include/KF5/KCoreAddons -isystem /usr/include/KF5/KI18n -isystem /usr/include/KF5/KIOWidgets -isystem /usr/include/KF5/KIOGui -isystem /usr/include/KF5/KIOCore -isystem /usr/include/KF5/KIO -isystem /usr/include/qt5/QtNetwork -isystem /usr/include/qt5/QtDBus -isystem /usr/include/KF5/KWindowSystem -isystem /usr/include/KF5/KJobWidgets -isystem /usr/include/KF5/Solid -isystem /usr/include/KF5/KCompletion -isystem /usr/include/KF5/KIconThemes -isystem /usr/include/KF5/KActivities  -DQT_NO_DEBUG -march=native -O2 -fgcse-sm -fgcse-las -fgcse-after-reload -ftree-vectorize -fdiagnostics-color -fno-operator-names -fno-exceptions -Wall -Wextra -Wcast-align -Wchar-subscripts -Wformat-security -Wno-long-long -Wpointer-arith -Wundef -Wnon-virtual-dtor -Woverloaded-virtual -Werror=return-type -Werror=init-self -Wvla -Wdate-time -Wsuggest-override -Wlogical-op -fdiagnostics-color=always -fPIC -fvisibility=hidden -fvisibility-inlines-hidden -fPIC -std=gnu++11 -MD -MT core/CMakeFiles/systemsettingsview.dir/ModuleView.cpp.o -MF core/CMakeFiles/systemsettingsview.dir/ModuleView.cpp.o.d -o core/CMakeFiles/systemsettingsview.dir/ModuleView.cpp.o -c /tmp/portage/kde-plasma/systemsettings-9999/work/systemsettings-9999/core/ModuleView.cpp
/tmp/portage/kde-plasma/systemsettings-9999/work/systemsettings-9999/core/ModuleView.cpp:27:10: fatal error: kauth_version.h: No such file or directory
27 | #include <kauth_version.h>
|          ^~~~~~~~~~~~~~~~~
compilation terminated.
[...]
ninja: build stopped: subcommand failed.
* ERROR: kde-plasma/systemsettings-9999::kde failed (compile phase):
Comment 1 Duncan 2022-03-29 09:54:22 UTC
Hmm.  Actually it's a whole lot more packages due to an (upstream) indirect dependency on kcoreaddons that kconfigwidgets fills, but now *ONLY* when kconfigwidgets is build with USE=auth.  When it's not, it doesn't fill the indirect dependencies for kcoreaddons.

The reason I didn't see this before is because I was patching the packages' CMakeLists.txt to add the KF5::CoreAddons dependencies directly, and had filed the associated bugs upstream, not realizing they were related to this kconfigwidgets[auth] bug until now.

So add to the list kcharselect, kcolorchooser, kmix, kruler, breeze and oxygen.  There are definitely others including a few games (bovo, several others...) I (finally, after repeatedly rebuilding them for years) took the opportunity to try, and decided I didn't need them installed to constantly rebuild anyway, so rather than develop a patch I unmerged them.  Most of those I did patch (listed above) have upstream bugs filed.  See https://bugs.kde.org/show_bug.cgi?id=451751 and its dependency tree (because I used clone) for the patches I was using, but they were mostly variants of this one for kcharselect:

--- a/CMakeLists.txt	2022-03-20 19:01:52.305389470 -0700
+++ b/CMakeLists.txt	2022-03-20 19:05:05.572668773 -0700
@@ -28,6 +28,7 @@ find_package (Qt${QT_MAJOR_VERSION} ${QT
 
 find_package(KF5 ${KF5_MIN_VERSION} REQUIRED COMPONENTS
     Bookmarks
+    CoreAddons
     Crash
     I18n
     WidgetsAddons
@@ -62,6 +63,7 @@ target_sources(kcharselect PRIVATE
 
 target_link_libraries(kcharselect
     KF5::Bookmarks
+    KF5::CoreAddons
     KF5::Crash
     KF5::I18n
     KF5::WidgetsAddons

Now it turns out the patch was unneeded for kconfigwidgets[auth] as it apparently then supplies the kcoreaddons dep indirectly. <shrug>

Here's a typical error, from kruler in this case, that demonstrates why the kcoreaddons patch is needed (KAboutData is in KCoreAddons, in kmix it was KProcess missing, also in KCoreAddons).  But it's only needed if kconfigwidgets is built without auth. <still shrugging>

FAILED: CMakeFiles/kruler.dir/klineal.cpp.o 
/usr/lib/ccache/bin/x86_64-pc-linux-gnu-g++ -DKCONFIGWIDGETS_NO_KAUTH -DKF_DEPRECATED_WARNINGS_SINCE=0x060000 -DKF_DISABLE_DEPRECATED_BEFORE_AND_AT=0x055800 -DQT_CORE_LIB -DQT_DBUS_LIB -DQT_DEPRECATED_WARNINGS_SINCE=0x060000 -DQT_DISABLE_DEPRECATED_BEFORE=0x050F00 -DQT_GUI_LIB -DQT_NO_CAST_FROM_ASCII -DQT_NO_CAST_FROM_BYTEARRAY -DQT_NO_CAST_TO_ASCII -DQT_NO_DEBUG -DQT_NO_FOREACH -DQT_NO_KEYWORDS -DQT_NO_NARROWING_CONVERSIONS_IN_CONNECT -DQT_NO_URL_CAST_FROM_STRING -DQT_STRICT_ITERATORS -DQT_USE_QSTRINGBUILDER -DQT_WIDGETS_LIB -DQT_X11EXTRAS_LIB -DQT_XML_LIB -DTRANSLATION_DOMAIN=\"kruler\" -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/tmp/portage/kde-apps/kruler-9999/work/kruler-9999_build -I/tmp/portage/kde-apps/kruler-9999/work/kruler-9999 -I/tmp/portage/kde-apps/kruler-9999/work/kruler-9999_build/kruler_autogen/include -isystem /usr/include/KF5/KI18n -isystem /usr/include/KF5 -isystem /usr/include/qt5 -isystem /usr/include/qt5/QtCore -isystem /usr/lib64/qt5/mkspecs/linux-g++ -isystem /usr/include/KF5/KNotifications -isystem /usr/include/qt5/QtGui -isystem /usr/include/qt5/QtWidgets -isystem /usr/include/qt5/QtDBus -isystem /usr/include/KF5/KWindowSystem -isystem /usr/include/KF5/KXmlGui -isystem /usr/include/qt5/QtXml -isystem /usr/include/KF5/KConfig -isystem /usr/include/KF5/KConfigCore -isystem /usr/include/KF5/KConfigWidgets -isystem /usr/include/KF5/KCodecs -isystem /usr/include/KF5/KWidgetsAddons -isystem /usr/include/KF5/KConfigGui -isystem //include/qt5 -isystem //include/qt5/QtX11Extras  -DQT_NO_DEBUG -march=native -O2 -fgcse-sm -fgcse-las -fgcse-after-reload -ftree-vectorize -fdiagnostics-color -fno-operator-names -fno-exceptions -Wall -Wextra -Wcast-align -Wchar-subscripts -Wformat-security -Wno-long-long -Wpointer-arith -Wundef -Wnon-virtual-dtor -Woverloaded-virtual -Werror=return-type -Werror=init-self -Wvla -Wdate-time -Wsuggest-override -Wlogical-op -pedantic -Wzero-as-null-pointer-constant -Wmissing-include-dirs -fdiagnostics-color=always -fvisibility=hidden -fvisibility-inlines-hidden -fPIC -std=c++17 -MD -MT CMakeFiles/kruler.dir/klineal.cpp.o -MF CMakeFiles/kruler.dir/klineal.cpp.o.d -o CMakeFiles/kruler.dir/klineal.cpp.o -c /tmp/portage/kde-apps/kruler-9999/work/kruler-9999/klineal.cpp
/tmp/portage/kde-apps/kruler-9999/work/kruler-9999/klineal.cpp:23:10: fatal error: KAboutData: No such file or directory
23 | #include <KAboutData>
|          ^~~~~~~~~~~~

So... umm... yeah, I think hardcode the now USE=auth for kconfigwidgets and avoid all the pain, as otherwise you're not only fighting the auth problems, but a bunch of missing kcoreaddons problems that kconfigwidgets[auth] apparently fixes by indirectly providing it, as well.

Either that or try to get all the direct kcoreaddons deps added upstream (tho for the indirectly provided kcoreaddons deps that's arguably the proper fix), as well as straightening out the direct kconfigwidgets[auth] problems.
Comment 2 Andreas Sturmlechner gentoo-dev 2022-03-29 11:03:02 UTC
(In reply to Duncan from comment #0)
> Tho I see it is already IUSE=+auth, but despite that it wasn't required for
> those builds before.
You need to look at kde overlay commit abbdc3f6711687ce2cba17cc98c1545dcb0777bf "kde-frameworks/kconfigwidgets: Add IUSE auth" to see that it made an existing dependency optional. I was wary about providing the option, then did it anyway, but did not have the time to look into follow-up revdep changes.
Comment 3 Andreas Sturmlechner gentoo-dev 2022-03-29 13:38:08 UTC
I've picked all your upstream bug report patches to invent.kde.org since that's where code contributions ought to go to - attachments on bugs.kde.org usually are not considered. Linking more fixes of my own here.
Comment 4 Duncan 2022-03-30 00:02:58 UTC
(In reply to Andreas Sturmlechner from comment #2)
> (In reply to Duncan from comment #0)
> > Tho I see it is already IUSE=+auth, but despite that it wasn't required for
> > those builds before.
> You need to look at kde overlay commit
> abbdc3f6711687ce2cba17cc98c1545dcb0777bf "kde-frameworks/kconfigwidgets: Add
> IUSE auth" to see that it made an existing dependency optional. I was wary
> about providing the option, then did it anyway, but did not have the time to
> look into follow-up revdep changes.

[I have a feeling this is a bit jumbled.  Still rather underslept due to all this and I think I'm going in rhetorical-logic circles even more than usual!  Sorry! =:^\)

OK, so I both saw abbdc3f67 in my git log review and the new USE=auth in --ask --verbose, but didn't think too much about it as from the description it was a pretty straightforward kauth controlling USE flag, which I figured I'd probably not need since I took it to be polkit related and by local policy I both have that off AND don't use GUI tools as root, only CLI/TUI (mc, etc, tho mostly in konsole unless I can't get into wayland or konsole won't run)

Then I promptly forgot about it, or more accurately, conflated it with the upstream kauth git log entries mentioned in comment 0.  *NOW* I know what that nagging feeling that I was forgetting something critical in those git logs was all about!  But I just kept going back to the upstream kauth header commits and thinking that must be what was triggering that feeling!

Anyway, when I saw the kauth header problems I remembered the upstream commits and went looking that way, entirely oblivious to that kde overlay commit I had conflated with the upstream kauth stuff.

That nicely explains the rock vs. hard-place I found myself dealing with for the last couple weeks...  Hopefully lesson-learned on my part!

What it does /not/ explain is all those upstream indirect deps from comment 1.  I guess those are real indirect-dep bugs that need fixed (my patches being a start), that neither the automated tests nor the human devs ever came across before as probably nobody had ever thought to try building all the kconfigwidgets revdeps without its kauth support turned on, thus triggering all the errors due to missing deps otherwise indirectly provided by kconfigwidgets.

So while I did put myself through a lot of unnecessary pain, at least it seems to have turned up that whole set of indirect-deps bugs which can now be fixed. =:^)

As for the hardcoding, I suspect after all the indirect-deps bugs are fixed USE=auth can (arguably should) stay.  But you might consider either a news item or at least a pretend/post-inst elog telling people about it, because hopefully that'll avoid the blindness that affected me and you'll get fewer dup-bug reports as this works its way into ~arch and then stable, as a result.

(Now to sync and thus grab the ECM and okular patch-rebases and anything else new in the overlay, then do today's rebuilds, as konsole's currently segfaulting without showing a window or leaving much but the bare segfault error in STDERR to go on when I try to run it from my backup-term, weston-terminal.  I might have another bug to file if the update doesn't fix it and I can figure out enough of the "why" to file something reasonable, but with any luck...)
Comment 5 Larry the Git Cow gentoo-dev 2022-04-09 16:07:11 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a71bd2f4602ac581a44b1e32ffe9be8f530472b7

commit a71bd2f4602ac581a44b1e32ffe9be8f530472b7
Author:     Andreas Sturmlechner <asturm@gentoo.org>
AuthorDate: 2022-04-09 15:16:25 +0000
Commit:     Andreas Sturmlechner <asturm@gentoo.org>
CommitDate: 2022-04-09 16:03:02 +0000

    kde-frameworks/kconfigwidgets: Drop IUSE=auth, fix graphical glitch
    
    Upstream commit babd8078cc92b3f46dbab0286d7629ada1c2d10f
    KDE-bug: https://bugs.kde.org/show_bug.cgi?id=452211
    
    Bug: https://bugs.gentoo.org/836361
    Package-Manager: Portage-3.0.30, Repoman-3.0.3
    Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>

 ...ets-5.92.0-khamburgermenu-ensure-polished.patch | 32 ++++++++++++++++++++++
 ...92.0.ebuild => kconfigwidgets-5.92.0-r1.ebuild} |  7 +++--
 kde-frameworks/kconfigwidgets/metadata.xml         |  1 -
 3 files changed, 36 insertions(+), 4 deletions(-)
Comment 6 Larry the Git Cow gentoo-dev 2022-08-07 16:30:21 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/proj/kde.git/commit/?id=b4e4225cb5dd08676088bb7011b1d31e5810250a

commit b4e4225cb5dd08676088bb7011b1d31e5810250a
Author:     Andreas Sturmlechner <asturm@gentoo.org>
AuthorDate: 2022-08-07 16:07:02 +0000
Commit:     Andreas Sturmlechner <asturm@gentoo.org>
CommitDate: 2022-08-07 16:26:55 +0000

    kde-frameworks/kconfigwidgets: Revert "Add IUSE qml"
    
    It was fun while it lasted, we fixed a bunch of packages' cmake deps,
    but it makes no sense to keep this any longer.
    
    This reverts commit abbdc3f6711687ce2cba17cc98c1545dcb0777bf.
    
    Closes: https://bugs.gentoo.org/836361
    Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>

 kde-frameworks/kconfigwidgets/kconfigwidgets-9999.ebuild | 5 ++---
 kde-frameworks/kconfigwidgets/metadata.xml               | 1 -
 2 files changed, 2 insertions(+), 4 deletions(-)