Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 276735 - x11-themes/qtcurve-0.65.2: sh: kde4-config: command not found
Summary: x11-themes/qtcurve-0.65.2: sh: kde4-config: command not found
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Unspecified (show other bugs)
Hardware: All Linux
: High trivial (vote)
Assignee: Ben de Groot (RETIRED)
URL: http://www.kde-look.org/content/show....
Whiteboard:
Keywords:
Depends on: 278911
Blocks:
  Show dependency tree
 
Reported: 2009-07-06 10:48 UTC by Martin von Gagern
Modified: 2009-07-24 08:37 UTC (History)
1 user (show)

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 Martin von Gagern 2009-07-06 10:48:06 UTC
When running kpdf on my KDE 3.5 ~x86 system using qtcurve, it prints the following line to stderr:

sh: kde4-config: command not found

I traced the message to /usr/kde/3.5/lib/kde3/plugins/styles/qtcurve.so:
#0  kdeHome (kde3=false) at /var/tmp/portage/x11-themes/qtcurve-0.65.2/work/
    QtCurve-KDE3-0.65.2/style/qtcurve.cpp:198
#1  QtCurveStylePlugin::keys at /var/tmp/portage/x11-themes/qtcurve-0.65.2/work/
    QtCurve-KDE3-0.65.2/style/qtcurve.cpp:290
#2  QStylePluginPrivate::featureList at styles/qstyleplugin.cpp:138
#3  QGPluginManager::addLibrary at tools/qgpluginmanager.cpp:480
#4  QGPluginManager::library at tools/qgpluginmanager.cpp:391
#5  QGPluginManager::queryUnknownInterface at tools/qgpluginmanager.cpp:546
#6  QStyleFactory::create at ../include/private/qpluginmanager_p.h:70
#7  KApplication::applyGUIStyle at kapplication.cpp:1937
#8  KApplication::kdisplaySetStyle at kapplication.cpp:2128
#9  KApplication::init at kapplication.cpp:877
#10 KApplication at kapplication.cpp:634
#11 main at main.cpp:53

QtCurveStylePlugin::keys() does invoke kdeHome always twice, once for KDE3 and once for KDE4:
        getStyles(kdeHome(useQt3Settings()), list);
        getStyles(kdeHome(!useQt3Settings()), list);

kdeHome in turn does try to execute kde4-config if its kde3 argument is false, and read from its output pipe. It's the standard error of this command which causes the actual problem.
        if (fpipe = (FILE*)popen(kde3 ? "kde-config --localprefix"
                                      : "kde4-config --localprefix", "r"))

It seems that there are some fallbacks in place, so the application does recover. I believe the intention of the double invocation of kdeHome is to load settings from both kde profiles, so it should be perfectly all right and even expected for one of these to fail, if only one KDE version is installed. I believe that messages to standard error should be avoided, though. So that's what I'd like to see fixed, either at the distro level or upstream.

I also noticed some strange code a few lines later on, in the fallback code in kdeHome:
           if (!useQt3Settings() && homeDir.exists(".kde4"))
                kdeConfDir = QString("/.kde4");
I think this should be the kde3 parameter, not useQt3Settings here. But I'm not sure, as I'm not sure I correctly understand the whole intended behaviour.
Comment 1 Ben de Groot (RETIRED) gentoo-dev 2009-07-14 08:48:10 UTC
Please report this upstream if you want this changed.
Comment 2 Martin von Gagern 2009-07-14 12:04:41 UTC
(In reply to comment #1)
> Please report this upstream if you want this changed.

Reported upstream. Right now it's viewable as
http://www.kde-look.org/content/show.php?content=40492&forumpage=102#c315445
but I have no idea how long that URL will remain valid.
I do miss a serious bug tracker for this code!
Comment 3 Martin von Gagern 2009-07-15 16:06:49 UTC
(In reply to comment #2)
> Reported upstream.

FYI: Upstream maintainer Craig Drummond replied. As I don't trust the kde-look system of comments to keep this reply for future reference, I'll quote it here:

  * I'll change the 'kde4-config --localprefix' to 'kde4-config --localprefix
    2> /dev/null' So that errors are piped to /dev/null

  * The last part is correct. What it is saying is that if qt4/kde4 settings
    are to be used and ~/.kde4 exists, then use that.

So I guess that >=x11-themes/qtcurve-0.65.5 should fix the issue.