[Kmymoney-devel] Two instances at once, was: Debugging plugins

Chris DeveloperChris at rebel.com.au
Tue Apr 1 11:41:38 UTC 2014



It checks every file to see if it needs rebuilding and I haven't worked out 
how to stop that. Of course it doesnt take overly long. probably less than 1 
minute but I find it annoying. I did say I was impatient.

The symlink solution solves it though, I just deploy once, create the 
symlink to the actual file and then I don't need to do an install after 
every build.

Chris



On 1/04/2014 8:34 PM, Allan wrote:
> On 01/04/14 10:35, Chris wrote:
>>
>> Yes Thank you for all your information
>>
>> I have chewed it over and decided that the best bet for me is to trash
>> my entire install and start over once again. I shall have to see how it
>> goes once the environment is rebuilt. I could not get QTCreator to
>> properly debug the plugin It simply would not load the symbol table. I
>> could get msvc2010 to debug it but I was hoping QTCreator would be more
>> friendly It certainly has better environment options.
>>
>> For debugging I think the best bet for me is to symlink the files I am
>> currently working on as I tend to fix/compile/run. Doing an install
>> after every edit is very time consuming, I am impatient like that.
>
> Is that something specific to Windows?  I find that it's the make that 
> takes the time, with the install being much quicker.  An edit on a single 
> file is very quick all round, it's a new make from scratch that takes time.
>>
>> Chris
>>
>>
>>
>> On 1/04/2014 6:58 PM, Cristian Oneț wrote:
>>> Hi Christian,
>>>
>>> A big thanks for providing this detailed information. I hope that this
>>> ends the debate over the "supposed lack of developer/user mixing
>>> support" in the platform and the application.
>>>
>>> Regards,
>>> Cristian
>>>
>>>
>>> 2014-03-31 12:32 GMT+03:00 Christian Dávid <christian-david at web.de
>>> <mailto:christian-david at web.de>>:
>>>
>>>     Hello!
>>>
>>>     Am Sonntag, 30. März 2014, 19:08:08 schrieb Jack:
>>>     > > It would appear in KDE you need to pollute your application name
>>>     > > space to debug a plugin which means you cannot simultaneously
>>> have a
>>>     > > devel version and a release version running at the same time.
>>>     >
>>>     > Ah, you have run into one of my recurring rants.  I have never
>>>     > succeeded (on Linux) to install two versions of KMyMoney at once
>>> […]
>>>
>>>     As this comes up quite often I retried my approach from scratch. You
>>>     "just"
>>>     need all build dependencies installed. I did it with Linux, but it
>>>     should be
>>>     the same on windows except one command (and you have to replace cd).
>>>     If you
>>>     test it and it works as well, I can publish it on techbase. With
>>> windows
>>>     specific stuff it would even be better.
>>>
>>>     # Get sources
>>>     git clone git://anongit.kde.org/kmymoney
>>> <http://anongit.kde.org/kmymoney>
>>>     cd kmymoney/
>>>
>>>     # Create directory for out of source build
>>>     mkdir build
>>>     cd build/
>>>
>>>     # Run cmake and set an install prefix
>>>     # "make install" will copy all files there
>>>     cmake -DCMAKE_INSTALL_PREFIX=../install/ ../
>>>
>>>     # Build and install
>>>     make
>>>     make install
>>>     cd ../install/
>>>
>>>     # Give KDE's trader the chance to find the new services (= our
>>> plugins)
>>>     # I guess on Windows (and maybe OS X) this command is different.
>>>     # You need  to set an environment variable to your current folder
>>>     export KDEDIRS=`pwd`
>>>
>>>     # Refresh cache of the trader
>>>     # after the next run of make install you do not need this again
>>>     kbuildsycoca4
>>>
>>>     # Here you can test if it worked
>>>     # It does not show the library path but X-KDE-PluginInfo-Version
>>>     contains the
>>>     # version. At the end is the git commit.
>>>     ktraderclient --servicetype "KMyMoneyPlugin"
>>>
>>>     # run your own build
>>>     bin/kmymoney
>>>
>>>     This allows you to install multiple versions of KMyMoney at the same
>>>     time. You
>>>     just have to set and unset KDEDIRS and run kbuildsycoca4.
>>>
>>>     If you also want to run them at the same time you can use your IDE.
>>>     This is the
>>>     way you should do it anyway as it is quicker for every day use.
>>>
>>>     KDevelop and QtCreator allow you to set a "run environment". Just
>>> tell
>>>     them to
>>>     set KDEDIRS to the appropriate folder there. Your IDE must install
>>>     KMyMoney
>>>     every time and execute "kbuildsycoca4" before you run KMyMoney
>>>     (KDevelop has
>>>     no direct option for this, you need a script — I think).
>>>
>>>     One problem left: If you run another instance of KMyMoney now, you
>>> have to
>>>     rebuild the cache (kbuildsycoca4) as SyCoCa tracks the files in it's
>>>     cache but
>>>     not the environment variable. So it doesn't notice that a service is
>>>     no longer
>>>     available if you just change KDEDIRS (but it notices if you remove or
>>>     update a
>>>     .so/.desktop file).
>>>
>>>     More tutorials on traders and the system configuration cache
>>> (SyCoCa) are
>>>     available on
>>>
>>> http://techbase.kde.org/Development/Tutorials#Services:_Applications_and_Plugins 
>>>
>>>
>>>
>>>     > > Ever thought of breaking KMymoney out of the dependency on
>>> KDE? It
>>>     > > would have much wider appeal.
>>>
>>>     A lot of KMyMoney current appeal comes from the use of KDE. And from
>>>     experience I know: That would result in solutions which are as
>>> complex
>>>     as the
>>>     the current ones but with less documentation, less testing, horrible
>>>     maintenance and less people who can help.
>>>
>>>     > […]
>>>     > Also, it might be worth exploring the impacts of
>>>     > the coming switch to Frameworks - if it will make working on
>>> OS-X and
>>>     > Windows easier, it may be worth accelerating, although I fear it
>>> may be
>>>     > as difficult and painful as the switch from kde3 to kde4.
>>>
>>>     Frameworks will make the build on OS-X and windows easier.
>>>
>>>     I hope this helps.
>>>     Greetings
>>>     Christian
>>>     _______________________________________________
>>>     KMyMoney-devel mailing list
>>>     KMyMoney-devel at kde.org <mailto:KMyMoney-devel at kde.org>
>>>     https://mail.kde.org/mailman/listinfo/kmymoney-devel
>>>
>>>
>>>
>>>
>>> _______________________________________________
>>> KMyMoney-devel mailing list
>>> KMyMoney-devel at kde.org
>>> https://mail.kde.org/mailman/listinfo/kmymoney-devel
>>
>>
>>
>>
>> _______________________________________________
>> KMyMoney-devel mailing list
>> KMyMoney-devel at kde.org
>> https://mail.kde.org/mailman/listinfo/kmymoney-devel
>>
>
>



More information about the KMyMoney-devel mailing list