Compiling KDE – Fedora: Running your build

November 9, 2008 at 7:52 pm (fedora, kde, linux) (, , , , , )

So this is the last step in having your own KDE build. In this step, I will explain how you can run what you have built without any problem whatsoever!

What you need to do is:
1- make kdm recognized
2- run kde!!

And to make KDM recognized and to actually use it, you have to access /etc/sysconfig/desktop file and change the DESKTOP and DISPLAYMANAGER values. To do that, first check if you have a file called ‘desktop’ in directory /etc/sysconfig. Then open it with a text editor (e.g. vi, emacs, nano, gedit, whatever) but MAKE SURE that when opening the file, you have admin privileges:

$ su -c 'vim /etc/sysconfig/desktop'

Now you are ready to change the values. What you see is this:

DESKTOP=blahblah
DISPLAYMANAGER=blahblah

And change it to:

DESKTOP=KDE
DISPLAYMANAGER=KDE

Now just change runlevels (5 to 3 and back to 5) or just reboot your system.
The next time, you see KDM as your display manager and then you can log in to KDE :D

And happy KDEing!!!

Note: all the credit goes to rdieter (on IRC, freenode, channel #fedora-kde) for telling me all this stuff :D

Permalink Leave a Comment

Compiling KDE – Fedora: Building

November 7, 2008 at 9:07 pm (console, fedora, kde, linux) (, , , , , , , , )

Building KDE is very easy. The only thing you need to do is:

1- Download the source code
2- Configure it with cmake
3- make && make install

Downloading the source code:
We will start from the first step. To get the source code, we will use svn:
$ svn checkout svn://anonsvn.kde.org/home/kde/...
and you replace ‘…’ with the module you want to download.

Before you download the source codes, create a folder in you home directory where you would put your sources. (Just to be more organized). I created a directory called “kdesvn” in my home:
$ mkdir ~/kdesvn
then we ‘cd’ into the created directory:
$ cd ~/kdesvn

Now we download the source codes into this directory using svn:

$ svn co svn://anonsvn.kde.org/home/kde/trunk/kdesupport kdesupport
$ svn co svn://anonsvn.kde.org/home/kde/trunk/KDE/kdelibs kdelibs
$ svn co svn://anonsvn.kde.org/home/kde/trunk/KDE/kdepimlibs kdepimlibs
$ svn co svn://anonsvn.kde.org/home/kde/trunk/KDE/kdebase kdebase

the argument after the URL is the name of the local folder (what you want the directory you are downloading be called on your computer).

We are finished with the first step!!! :D

Configuring it with cmake:
now that we have downloaded all the source codes, we need to configure it and prepare it for building and installing. To do this, we use cmake (simply because the source code requires us to use it):
$ cmake -DCMAKE_INSTALL_PREFIX=/usr ..

don’t get scared. We just run cmake with two arguments, the first argument (-DCMAKE_INSTALL_PREFIX), as the name applies, is where you want the application to be installed. I just chose /usr because it’s easier than installing it to ~. The second argument (..) is the directory you want to configure (and .. means parent directory and . (dot) means current directory).

Before starting to configure, we go to each directory of the source code and we create a ‘build’ directory in each of them (again, just to be more organized, and it’s good practice):
$ cd ~/kdesvn/kdesupport && mkdir build && cd build

and then we ‘cd’ into the ‘build’ directory.
And now is the time to configure the fabulous source code! :D

$ cmake -DCMAKE_INSTALL_PREFIX=/usr ..

if you have installed all the requirements, this shouldn’t give you any problems (as long as the source code itself is not screwed up).

And finally building it:
building the configured source code is dead easy! Just do make && sudo make install that’s all!

$ make
$ su -c 'make install'

The next post will be about how to actually run your build. So keep up ;)

Permalink Leave a Comment