kdeextragear-1/k3b/src

Helge Deller deller at gmx.de
Mon Jun 23 20:23:24 BST 2003


Hi Sebastian,

<Helge Deller>
> b) writePathEntry() in 3.1 (not in 3.1 BRANCH!) was broken and wrote
> always $HOME at the beginning of strings. This should be solvable with an
> #ifdef KDE_IS_VERSION(3,1,2)

of course I meant  KDE_IS_VERSION(3,1,3) here....

<Sebastian Trueg>
> Are you sure this is a good solution? As far as I know KDE 3.1.x should be
> BC. So it's no problem to compile with KDE 3.1.2 and run with, say  KDE
> 3.1.1. This way the bug will show. Am I right? Since a lot of users are
> installing rpm packages created by other users this may occur more than
> once. I never liked #ifdefs anyway. ;)
> So what can I do instead? I could provide my own implementation (some
> wrapper) for as long as K3b will be Kde 3.1 comp.. I think that would be
> the best solution.

first, just use readPathEntry() where necessary. It is binary compatible.

With the problem about backward binary compatibility (built on 3.1.3, run on 3.1.2,
which I never liked) you might either:

a) just ignore all writePathEntry()s for KDE 3.1.x and continue to use 
writeEntry() and then use writePathEntry() only inside an #ifdef KDE_IS_VERSION(3,1,90),
where KDE 3.2 will be the first version with full roaming user support.

b) write a wrapper which detects the KDE version at runtime and use the propriate
writeXXEntry() (as you proposed)

c) build two RPMs, one for <= 3.1.2 and one for 3.1.3 and above

d) force with an RPM dependency to build and run on the same KDE version,
in which case you maybe want this:
#if KDE_IS_VERSION(3,1,3)
       writePathEntry(something)	// new coding to support roaming users
#else
       writeEntry(something)		// old "original" coding
#endif

I would propose a), b) or d), but of course it's up to you...

HTH,
Helge




More information about the kde-core-devel mailing list