[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: [PATCH] kcmoduleinfo [WAS] Plugin linking problem
From:       "=?UTF-8?Q?Rafael_Fern=C3=A1ndez_L=C3=B3pez?=" <ereslibre () gmail ! com>
Date:       2007-08-09 21:51:30
Message-ID: 93f85fee0708091451p7562fe3cr578e43a46b164d2e () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (text/plain)]

Hi,

2007/8/9, Andreas Pakulat <apaku@gmx.de>:
>
> On 09.08.07 23:36:25, Rafael Fernández López wrote:
> > The main problem was here (at kcmoduleinfo.cpp):
> >
> > -   if( !lib.startsWith( QLatin1String( "kcm_" ) ) )
> > -     lib = QLatin1String( "kcm_" ) + lib;
> >
> > When it tries to load the KCM factory from the library it will fail,
> because
> > if the library is " foo.so", it will try to load from "kcm_foo.so", what
> > won't find.
> >
> > For that reason I'm removing that as well as this change on the same
> file:
> >
> > -  handle = tmp.isValid() ? tmp.toString() :
> > lib.right( lib.length() - 4 ); // lib without kcm_ prefix
> > +  handle = tmp.isValid() ? tmp.toString() : lib;
> >
> > This way what I've been working on is adapting all *.desktop files that
> had
> > X-KDE-Library variable without kcm_ on the beginning, and of course,
> fixing
> > some .cpp files that hadn't X-KDE-FactoryName on their .desktop files
> > (because there X-KDE-Library was taken), and as far as it was modified
> > adding "kcm_", it was needed to add "kcm_" on the
> > K_EXPORT_COMPONENT_FACTORY.
> >
> > Everything on kdebase/kdelibs/kdepimlibs (I have checked all I think)
> works.
> > I have to fix the rest of modules. kdevplatform and kdevelop were
> > contributed by apaku, and I just need to search for KCModule on the rest
> of
> > *.desktop files on the rest of modules (I don't think they will be too
> > much).
>
> Even though the main purpose for this change seems to be going away
> (looks like Kate will drop KPluginSelector again), I still think it
> should be applied because it makes it possible to "transport" a kcm in
> any kind of plugin-like-library and doesn't force specific names on the
> developer for that.


yeah, but I don't care if they're throwing it away. This is a blocker, and
it shouldn't be that way. We could still be interested in a library
providing "something" and a KCModule too :)


Bye,
Rafael Fernández López.

[Attachment #3 (text/html)]

Hi,<br><br><div><span class="gmail_quote">2007/8/9, Andreas Pakulat &lt;<a \
href="mailto:apaku@gmx.de">apaku@gmx.de</a>&gt;:</span><blockquote \
class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt \
0pt 0.8ex; padding-left: 1ex;"> On 09.08.07 23:36:25, Rafael Fernández López \
wrote:<br>&gt; The main problem was here (at kcmoduleinfo.cpp):<br>&gt;<br>&gt; \
-&nbsp;&nbsp; if( !lib.startsWith( QLatin1String( &quot;kcm_&quot; ) ) )<br>&gt; \
-&nbsp;&nbsp;&nbsp;&nbsp; lib = QLatin1String( &quot;kcm_&quot; ) + lib; \
<br>&gt;<br>&gt; When it tries to load the KCM factory from the library it will fail, \
because<br>&gt; if the library is &quot; foo.so&quot;, it will try to load from \
&quot;kcm_foo.so&quot;, what<br>&gt; won&#39;t find.<br> &gt;<br>&gt; For that reason \
I&#39;m removing that as well as this change on the same file:<br>&gt;<br>&gt; \
-&nbsp;&nbsp;handle = tmp.isValid() ? tmp.toString() :<br>&gt; lib.right( \
lib.length() - 4 ); // lib without kcm_ prefix<br> &gt; +&nbsp;&nbsp;handle = \
tmp.isValid() ? tmp.toString() : lib;<br>&gt;<br>&gt; This way what I&#39;ve been \
working on is adapting all *.desktop files that had<br>&gt; X-KDE-Library variable \
without kcm_ on the beginning, and of course, fixing <br>&gt; some .cpp files that \
hadn&#39;t X-KDE-FactoryName on their .desktop files<br>&gt; (because there \
X-KDE-Library was taken), and as far as it was modified<br>&gt; adding \
&quot;kcm_&quot;, it was needed to add &quot;kcm_&quot; on the <br>&gt; \
K_EXPORT_COMPONENT_FACTORY.<br>&gt;<br>&gt; Everything on kdebase/kdelibs/kdepimlibs \
(I have checked all I think) works.<br>&gt; I have to fix the rest of modules. \
kdevplatform and kdevelop were<br>&gt; contributed by apaku, and I just need to \
search for KCModule on the rest of <br>&gt; *.desktop files on the rest of modules (I \
don&#39;t think they will be too<br>&gt; much).<br><br>Even though the main purpose \
for this change seems to be going away<br>(looks like Kate will drop KPluginSelector \
again), I still think it <br>should be applied because it makes it possible to \
&quot;transport&quot; a kcm in<br>any kind of plugin-like-library and doesn&#39;t \
force specific names on the<br>developer for that.</blockquote><div><br>yeah, but I \
don&#39;t care if they&#39;re throwing it away. This is a blocker, and it \
shouldn&#39;t be that way. We could still be interested in a library providing \
&quot;something&quot; and a KCModule too :) <br></div><br><br></div>Bye,<br>Rafael \
Fernández López.



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic