Fwd: Kde 4.2 beta1 feedback: Notes on cmake scripts

Allen Winter winter at kde.org
Fri Dec 19 13:13:43 CET 2008


Forwarding to the buildsystem folks:
-----------------------------------------------------------------------------
Firstly I'd like to say thank you for an awesome kde 4.2 beta 1, it's  
looking really good.

I would like to raise a few issues about the build scripts and offer  
some suggestions.
I regret that I have not been able to try the latest "beta 2" that was  
released today,
but I will try it as soon as I have time.

I am using GoboLinux. GoboLinux does not use the FHS, which means  
certain
assumptions that are true for many distributions do not hold in this  
case.

While installing KDE-4.2 beta 1 I ran in to 2 areas of trouble which  
required three patches
in total.

The first trouble spot is with the cmake modules that kde-libs  
installs on the system.
The "kdelibs-4.1.80/cmake/modules/FindKdepimLibs.cmake" file
specifies KDE4_LIB_DIR as the location for the kdepimlibs libraries.  
This does not
work on GoboLinux because we do not install the whole of KDE to the  
same prefix
instead we have /Programs/KDE-Libs/Current, /Programs/KDE-PIM-Libs/ 
Current,
/Programs/KDE-Base/Current, etc.

This means that in the Gobolinux case KDE4_LIB_DIR will point to
/Programs/KDE-Libs/Current, which is obviously the wrong prefix for  
PIM-Libs.

I solved this by substituting CMAKE_LIBRARY_PATH in the place of  
KDE4_LIB_DIR
and setting CMAKE_LIBRARY_PATH=/System/Links/Libraries where all  
libraries can
be found.

I had a quick browse of kde web svn before sending this email and it  
would appear
that FindKdepimLibs has changed quite a bit. I haven't had a chance to  
read very deeply
into the code, but I hope that CMAKE_LIBRARY_PATH is used more instead  
of KDE4_LIB_DIR.

The other problem I had was with KDE-Base-Workspace and KDE-Base- 
Runtime locating
DBUS interface definitions in the scripts powerdevil/daemon/ 
CMakeLists.txt and
kwalletd/CMakeLists.txt. Both scripts originially used the variable  
DBUS_INTERFACES_INSTALL_DIR
to refer to preexisting interface definition files. On a system where  
all DBUS interfaces are
installed in the same location this is not a problem. However, on  
GoboLinux each package
installs its DBUS interface  definitions under the package prefix and  
these are symlinked
to /System/Links/Shared/dbus-1/interfaces/ .

In the end this means when building either KDE-Base Workspace or  
Runtime the build script
looks under the installation prefix and of course it won't find  
anything there because
that prefix hasn't been created yet (and the files its looking for are  
never going to be there anyway)!

To resolve this I substituted DBUS_INTERFACES_INSTALL_DIR with  
KDE4_DBUS_INTERFACES_DIR
and set KDE4_DBUS_INTERFACES_DIR appropriately (i.e. to  /System/Links/ 
Shared/dbus-1/interfaces)
when compiling KDE-Libs.

 From browsing kde web svn, this seems to be the approach you are  
taking now. I would like to strongly
encourage you to include this in the final release! :-)

I include my patches with this email for clarity. I apologise for  
accidentally changing a WIN32 setting in
01-kwalletd-CMakeLists.patch this was not my intension and I do not  
know if it is appropriate or not.
The patch is really just to illustrate the change I would make and by  
the looks of the svn code I don't think you
will be needing it!

Do people on this list think it is likely that these amendments might  
make the final release?
(Not my patches, just the general ideas!)

Thanks,

Frank Wilson


-------------- next part --------------
A non-text attachment was scrubbed...
Name: 01-powerdevil-daemon-CMakeLists.patch
Type: application/octet-stream
Size: 1397 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/kde-buildsystem/attachments/20081219/4e8a667b/attachment.dll 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 01-kwalletd-CMakeLists.patch
Type: application/octet-stream
Size: 730 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/kde-buildsystem/attachments/20081219/4e8a667b/attachment-0001.dll 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 01-FindKdepimLibs.patch
Type: application/octet-stream
Size: 5383 bytes
Desc: not available
Url : http://mail.kde.org/pipermail/kde-buildsystem/attachments/20081219/4e8a667b/attachment-0002.dll 


More information about the Kde-buildsystem mailing list