KConfigXT singleton pointer mess

Milian Wolff mail at milianw.de
Mon Jun 1 17:45:23 UTC 2009


Hi guys, i got a problem I cannot solve.

Over the weekend I made the php-docs plugin in playground configurable (i.e. 
the location to the php documentation) and had a look at 
kdevelop/tools/coverage as inspiration. It uses KConfigXT to generate a 
KConfigSkeleton singleton which apparently uses some K_GLOBAL_STATIC magic I'm 
not acquainted with.

Well, basic configuration and such works fine, the problem is that for changes 
to take affect I have to restart KDevelop. Why? Because it looks like the 
documentation plugin got a different KConfigSkeleton pointer (via self() 
singleton) than the configuration!

I really don't know how to fix that... I bet its something I do wrong in the 
CMakeLists.txt, i.e. the linking...

$ make -B                                                                                                                    
makeobj[0]: Entering directory `/home/milian/projects/.build/kde4/php-docs'                                                                                      
[ 10%] [ 20%] Generating ui_phpdocsconfig.h                                                                                                                      
Generating phpdocssettings.h, phpdocssettings.cpp                                                                                                                
[ 30%] Generating phpdocssettings.h, phpdocssettings.cpp
...

I.e. phpdocssettings.* is generated twice. Could this be the issue? But then 
they are both generated in the same folder and hence should overwrite 
themselves...

Or is it simply that I add the kcfg files to both targets (i.e. the 
documentation plugin and its settings plugin)? Do I have to build that as a 
shared library target or something? Can't this be done any simpler?!


-- 
Milian Wolff
mail at milianw.de
http://milianw.de
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20090601/1b624e34/attachment.sig>


More information about the KDevelop-devel mailing list