<div dir="ltr">Hello there ; )<br><br>>if ARCH64:<br>>
    import DLFCN as dl<br>
>else:<br>>   import dl<br><br>Yep python should know the architecture, maybe that could be the solution.<br><br>I'm sending this post to kde-bindings mail list, I hope that someone can explain this things better ; ) <br>
<br>Best Regards<br>Percy<br><br><br><br><div class="gmail_quote">On Sat, Jul 19, 2008 at 8:11 AM, Teemu Rytilahti <<a href="mailto:tpr@d5k.net">tpr@d5k.net</a>> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Percy Camilo Triveño Aucahuasi kirjoitti viestissään (lähetysaika Friday 11<br>
July 2008):<br>
<div class="Ih2E3d">> Hi guys, when I was trying build "kdeutils", cmake couldn't find PyKDE4.<br>
<br>
</div>Hi,<br>
<div class="Ih2E3d"><br>
> As far I know, this was a bug in python on x86_64 enviroments. I don't know<br>
> much about python, but maybe the SIP has generated this kind of code.<br>
<br>
</div>Yup, I have also had the same problem using PyKDE4 bindings.<br>
<div class="Ih2E3d"><br>
> There is a way to solve this replace the code of<br>
> /usr/lib/python2.5/site-packages/PyKDE4/__init__.py<br>
> with this:<br>
><br>
> #BEGIN<br>
> import sys<br>
> import ctypes<br>
> libc = ctypes.CDLL('libc.so.6')<br>
> libc.prctl(15, 'EntertainerBackend', 0, 0, 0)<br>
><br>
> # This is needed to ensure that dynamic_cast and RTTI works inside kdelibs.<br>
> #sys.setdlopenflags(dl.RTLD_NOW|dl.RTLD_GLOBAL)<br>
> #END<br>
<br>
</div>I have modified my __init__.py according to some forum/wiki post to look like<br>
this and its working:<br>
#import sys, dl<br>
import sys<br>
import DLFCN as dl<br>
<div class="Ih2E3d"># This is needed to ensure that dynamic_cast and RTTI works inside kdelibs.<br>
sys.setdlopenflags(dl.RTLD_NOW|dl.RTLD_GLOBAL)<br>
<br>
</div>No idea though which way that should be handled. If Python allows detecting<br>
the processor architecture when the app is run, perhaps something like this<br>
could be as a workaround in __init__.py:<br>
<br>
if ARCH64:<br>
    import DLFCN as dl<br>
else:<br>
    import dl<br>
<br>
<br>
Anyone in charge of PyKDE4 bindings around?<br>
<div><div></div><div class="Wj3C7c"><br>
> After that kdeutils found the PyKDE4 module, but this is the right<br>
> solution? this is a bug that concer the KDE scope?<br>
><br>
> Cheers<br>
> Percy<br>
><br>
> pd: System info:<br>
> - gcc (Debian 4.3.1-2) 4.3.1<br>
> - qt build from trunk/qt-copy (last update today)<br>
> - all KDE modules from trunk (last update today)<br>
> - PyQt build from sources (version 4.4.2)<br>
> - kdebindings/python already built<br>
<br>
<br>
</div></div><font color="#888888">--<br>
Best Regards,<br>
Teemu Rytilahti<br>
<br>
<br>
<br>
>> Visit <a href="http://mail.kde.org/mailman/listinfo/kde-devel#unsub" target="_blank">http://mail.kde.org/mailman/listinfo/kde-devel#unsub</a> to unsubscribe <<<br>
</font></blockquote></div><br></div>