KDE 3.5 Troubleshooting
A place to list solutions to problems that were hard to track down.
Trouble Compiling kdelibs
I ran into a problem compiling kdelibs, I kept getting errors like this:
./kopenssl.h:453: error: ISO C++ forbids declaration of 'ASN1_METHOD' with no type
./kopenssl.h:453: error: expected ';' before '*' token
./kopenssl.h:526: error: expected ';' before '(' token
The problem is that KDE 3 was updated to work with OpenSSH version 1.x but since it is deprecated this release will never be marked “stable” so it has to be allowed using keywords.1) So place the following keywords entries in /etc/portage/package.keywords2):
<kde-base/kdelibs-4.0 ~amd64 ~x86 <kde-base/kcontrol-4.0 ~amd64 ~x86
You can leave out whichever architecture you don't need (i.e., just use either ~amd64 or ~x86).
Return to emerging KDE:
emerge -vau kde-meta
Empty Applications Menu
Sometimes the KDE applications menu can suddenly be blank or missing many items. The times I saw this happen it turned out every time that it was due to a bad entry in the file. Apparently, KDE stops reading when it reaches the bad entry and your menu will only contain what was read before the error was encountered.
The menu file is stored in ~/.config/menus/, e.g.,
~/.config/menus/applications-kmenuedit.menu
The file is ASCII text so it can be edited (which is what I chose to do). Make a back-up copy before editing or re-generating it.
The command kbuildsycoca can be used to test and re-generate the menu.
$ kbuildsycoca --menutest kbuildsycoca running... Reusing existing ksycoca kio (KService*): WARNING: Invalid Service : kmplayer_part.desktop kbuildsycoca: ERROR: applications.menu not found in (/home/ab/.config/menus/,/etc/xdg/menus/) kio (KService*): WARNING: The desktop entry file .hidden/dirfilterplugin.desktop has Type=Service but is located under "apps" instead of "services" kio (KService*): WARNING: Invalid Service : .hidden/dirfilterplugin.desktop
To re-generate the menu:
kbuildsycoca --noincremental
In my case this did no good because there was an error message and, thus, the menu was not re-generated. So I ended up making a copy of the file then erased a segment (a portion from the bottom), with the plan of erasing parts until I isolated the problem. It takes a few seconds after making a change to the menu before it appears – it took about 5 seconds for the menu to re-appear when I erased the lower half of the file, but when I restored the old copy (the one that has a problem) the menu remained unchanged for much longer (minutes) before going blank again.
I learnt that the lower part of the file contains layout customisations and it was quickest for me to work from the bottom upwards. Since I do a lot of customising to my menus, I have many “Layout” sections that define what is added, moved, or excluded from the default menus. If I remove a Layout section the KDE menu reverts back to the default layout within a few seconds, and if I restore a Layout section it likewise shows my customisations in a few seconds. Most recently, I found that removing about 20 lines of “Move” sections at the bottom of the file (which contained applications I do not use or even have installed) restored the menu to normal.
Avahi and Remote Desktop
http://avahi.org/Avahi service discovery is required in order to use KDE Remote Desktop Connection (krdc). Version 3.5.10 of krdc requires libavahi-qt3, which appears to have been dropped after version 0.6.30-r1 in Gentoo: When I compile 0.6.30-r3 I only get libavahi-qt4, whereas compiling 0.6.30-r1 gives me both libraries.
A problem is that Avahi 0.6.30-r1 bombs if you have a version of Automake higher than 1.11.1. It also happens that the MySQL WorkBench also fails to compile with Automake higher than 1.11.1. So the steps I found that worked were:
- Downgrade Automake
- Lock Avahi at version 0.6.30-r1
- (Re-)Install Avahi
- Upgrade Automake back to the current version, if desired, although you may not have any packages that require a newer Automake and may run into others, like MySQL Workbench, that fail with newer versions.
- (Re-)Install krdc
The emerge command looks like this:
emerge -va =sys-devel/automake-1.11.1 =net-dns/avahi-0.6.30-r1 kde-base/krdc
You should see qt3 listed on the avahi line. If not, put qt3 in your USE flags in /etc/make.conf.
You probably also want to put this in /etc/portage/package.mask:
# Avahi 0.6.30-r1 was the last one to have QT3 support, which is required for krdc. >net-dns/avahi-0.6.30-r1