I recently set up, for a learning exercise, an Ubuntu desktop PC with KDE 4.2, installed Eclipse and started to look for information on how to develop for KDE. I know there's KDevelop and will probably have a look at that at some time in the future. Right now, however, I don't have the correct headers and libraries for creating KDE applications in C/C++ using Eclipse. If I have the following:
#include <kapplication.h>
it fails to compile since there are dependancies on other header files that are not present on my hard disk or reference classes that aren't declared anywhere.
So, the question is, what packages do I need to install in order to have the correct set of headers to allow me to write applications for KDE 4.2? Are there any packages I shouldn't have? Alternatively, if there are no packages then where can I get the appropriate files?
As a corollary, are there any good tutorials on KDE development, something like the Petzold Windows book?
EDIT: Clarifying what I'm really after: where can I download the correct set of header files / libraries in order to build a KDE application? IDEs to compile code aren't a real problem and are easy to get, as is setting up compiler options for include search paths and so on. Does the KDevelop package have all the correct include and library files or are they separate? I guess they are separate as KDevelop is an IDE that can do other languages as well, but I'm probably wrong. So, the KDE/Qt header files I have don't work, where do I get the right ones?
Skizz
Make sure you have installed the build-essential package. For more documentation available from the command line, install glibc-doc, manpages-dev, gcc-*-doc, libstdc++*-doc (replace '*' with suitable version numbers for your system)
Getting Started/Build/KDE4/Kubuntu and Debian had a pair of sudo aptitude install
commands which I used to get some required packages. I also got the KDevelop and QDevelop applications, although I'm not sure they are required. There was also another package I needed (kdelibs5-dev) and this one appears to be the key package. Everything eventually worked after getting that one. Eclipse and KDevelop were both happy building a simple application once the compiler settings were set up; Eclipse required setting search paths and library filenames.
From first impressions, Eclipse appears better than KDevelop for the single reason that the tool windows in Eclipse can be detached from the main window and float - useful on a dual monitor setup. I couldn't see anyway to do that in KDevelop (I'm sure someone will comment on how to do this).