LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (http://www.linuxquestions.org/questions/slackware-14/)
-   -   Compiling KDE4 KAlarm Without Akonadi (http://www.linuxquestions.org/questions/slackware-14/compiling-kde4-kalarm-without-akonadi-4175456076/)

Woodsman 03-29-2013 07:05 PM

Compiling KDE4 KAlarm Without Akonadi
 
I ran across a wonderful statement in the KDE forums indicating KAlarm can be built without Akonadi support. :D

I browsed the kdepim 4.10.1 sources. Looks like these options still exist. Seems all that is needed is to add -DKALARM_USE_KRESOURCES=ON to the cmake compile options.

In the KDE4 slackbuilds, how do I set those build options? There is no separate kalarm or kdepim build script. I'm guessing I have to create a kdepim file in the cmake directory? I'm still trying to wrap my mind around how the whole KDE4 build scripts work.

I appreciate all help! :)

Note: I haven't yet found any such options for KMail. :(

wildwizard 03-30-2013 03:51 AM

Quote:

Originally Posted by Woodsman (Post 4921334)
In the KDE4 slackbuilds, how do I set those build options? There is no separate kalarm or kdepim build script. I'm guessing I have to create a kdepim file in the cmake directory?

Your on the right path there, just copy the default cmake file into your kdepim file and add your extra options to it.

Do note that kalarm is still bundled in kdepim so the build script will be called kdepim not kalarm.

To start the rebuild of the package you execute "./KDE.Slackbuild kdepim" to build kdepim

Might also be a good idea to add a build number to the build directory, it works the same as the cmake scripts only all the file contains is the build number.

Alien Bob 03-30-2013 07:16 AM

You can find the KDE.SLakBuild framework documented here if you want to know how to change stuff: http://alien.slackbook.org/blog/kde-...de-slackbuild/

Eric

Woodsman 03-30-2013 01:39 PM

I'm doing something wrong. :(

I created a cmake/kdepim config file:

Code:

mkdir -p build
cd build
  cmake \
    $KDE_OPT_ARGS \
    -DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \
    -DCMAKE_C_FLAGS_RELEASE:STRING="$SLKCFLAGS" \
    -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \
    -DCMAKE_CXX_FLAGS_RELEASE:STRING="$SLKCFLAGS" \
    -DCMAKE_BUILD_TYPE=Release \
    -DCMAKE_INSTALL_PREFIX=/usr \
    -DMAN_INSTALL_DIR=/usr/man \
    -DSYSCONF_INSTALL_DIR=/etc/kde \
    -DLIB_SUFFIX=${LIBDIRSUFFIX} \
    -DKALARM_USE_KRESOURCES=ON \          <-- The important option
    -DKALARM_USE_AKONADI=OFF \            <-- The important option
    ..

I created a cmake/kdepimlibs config file:

Code:

mkdir -p build
cd build
  cmake \
    $KDE_OPT_ARGS \
    -DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \
    -DCMAKE_C_FLAGS_RELEASE:STRING="$SLKCFLAGS" \
    -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \
    -DCMAKE_CXX_FLAGS_RELEASE:STRING="$SLKCFLAGS" \
    -DCMAKE_BUILD_TYPE=Release \
    -DCMAKE_INSTALL_PREFIX=/usr \
    -DMAN_INSTALL_DIR=/usr/man \
    -DSYSCONF_INSTALL_DIR=/etc/kde \
    -DLIB_SUFFIX=${LIBDIRSUFFIX} \
    -DKDEPIM_NO_KRESOURCES=OFF \          <-- The important option
    ..

I ran the build like this:

BUILD=1a ./KDE.SlackBuild kdepim | tee ./build/kdepim-build-1a.log

After the cmake configuration completed I checked the cmake cache txt file and saw this:

grep -n KALARM_USE $TMP/kde-build/kdepim/kdepim-4.10.1/build/CMakeCache.txt

298:KALARM_USE_AKONADI:BOOL=OFF
301:KALARM_USE_KRESOURCES:UNINITIALIZED=ON

No errors during the build.

I installed the new packages with upgradepkg.

I started KAlarm from the command line to capture any stderr messages. There were no such messages. KAlarm starts (the KAlarm window appears) but is all grey with the infamous red X and the message "The Akonadi personal information management service is not operational." :scratch:

Here are the errors of the report:

Akonadi Server Self-Test Report
===============================

Test 7: ERROR
--------
Akonadi control process not registered at D-Bus.

Test 8: ERROR
--------
Akonadi server process not registered at D-Bus.

Test 9: ERROR
--------
Nepomuk search service not registered at D-Bus.

Test 11: ERROR
--------
No resource agents found.

I have Nepomuk disabled and I do not start Akonadi, which is part of this whole idea. :)

Woodsman 03-30-2013 03:26 PM

Update:

Regarding my previous post, I wasn't rebuilding kdepimlibs. :banghead:

I rebuilt again in this order:

BUILD=1b ./KDE.SlackBuild kdepimlibs | tee ./build/kdepimlibs-build-1b.log
BUILD=1b ./KDE.SlackBuild kdepim | tee ./build/kdepim-build-1b.log

That created three packages.

Unfortunately, same results. KAlarm wants to start Akonadi and fails to start.

wildwizard 03-31-2013 12:14 AM

I had a look at the source to see if there was anything else and it requires DEPRECATED features to be enabled and the build scripts in Slackware turn it all off.

Your going to have to go into the cmake directory and check everything in there for the option to turn them off and remove it and then rebuild the whole thing from scratch.

Woodsman 03-31-2013 02:10 PM

Okay, but I'm not a cmake guru. Which features need to be enabled? :)

Rebuild from scratch: do you mean the entire KDE package set and deps or just the PIM packages?

Thanks. :)

Woodsman 03-31-2013 03:44 PM

One note: I had the KALARM_USE_KRESOURCES=ON option in the kdepim config rather than kdepimlibs. After correcting kdepimlibs built fine but kdepim failed to build:

Code:

[ 70%] Building CXX object kalarm/CMakeFiles/kalarm_bin.dir/kalarmapp.o
/dev/shm/kde-build/kdepim/kdepim-4.10.1/kalarm/kalarmapp.cpp: In member function 'QStringList KAlarmApp::scheduledAlarmList()':
/dev/shm/kde-build/kdepim/kdepim-4.10.1/kalarm/kalarmapp.cpp:1212:48: error: no matching function for call to 'KAlarmCal::AlarmText::summary(KAlarmCal::KAEvent*&, int)'
/dev/shm/kde-build/kdepim/kdepim-4.10.1/kalarm/kalarmapp.cpp:1212:48: note: candidates are:
In file included from /dev/shm/kde-build/kdepim/kdepim-4.10.1/kalarm/editdlg.h:24:0,
                from /dev/shm/kde-build/kdepim/kdepim-4.10.1/kalarm/commandoptions.h:24,
                from /dev/shm/kde-build/kdepim/kdepim-4.10.1/kalarm/kalarmapp.cpp:28:
/usr/include/kalarmcal/alarmtext.h:136:17: note: QString KAlarmCal::AlarmText::summary() const
/usr/include/kalarmcal/alarmtext.h:136:17: note:  candidate expects 0 arguments, 2 provided
/usr/include/kalarmcal/alarmtext.h:171:24: note: static QString KAlarmCal::AlarmText::summary(const KAlarmCal::KAEvent&, int, bool*)
/usr/include/kalarmcal/alarmtext.h:171:24: note:  no known conversion for argument 1 from 'KAlarmCal::KAEvent*' to 'const KAlarmCal::KAEvent&'
make[2]: *** [kalarm/CMakeFiles/kalarm_bin.dir/kalarmapp.o] Error 1
make[1]: *** [kalarm/CMakeFiles/kalarm_bin.dir/all] Error 2
make: *** [all] Error 2
kdepim failed to build.

I noticed in the default cmake/cmake the build option KDE_PLATFORM_FEATURE_DISABLE_DEPRECATED=TRUE. I don't know whether that has to be changed to FALSE.

wildwizard 03-31-2013 07:10 PM

Quote:

Originally Posted by Woodsman (Post 4922258)
I noticed in the default cmake/cmake the build option KDE_PLATFORM_FEATURE_DISABLE_DEPRECATED=TRUE. I don't know whether that has to be changed to FALSE.

That is the option I was talking about. Though I'm not sure about the errors you got in your last post.


All times are GMT -5. The time now is 03:13 AM.