Yes, the python .so is in my LD path.&nbsp; <br>I can import the module from python without changing any environment variables.<br><br>As the compiler flag reveals, I am building a Matlab extension.&nbsp; I need some numpy functionality which I don&#39;t want to re-code.<br>
<br>Perhaps Matlab uses a different method to dynamically load libraries? <br><br><div class="gmail_quote">On Tue, Jan 13, 2009 at 12:20 AM, Michael Abshoff <span dir="ltr">&lt;<a href="mailto:michael.abshoff@googlemail.com">michael.abshoff@googlemail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="Ih2E3d">Igor Sylvester wrote:<br>
&gt; I built it against *Python 2.5.1.<br>
&gt;<br>
&gt; compile:*<br>
&gt; gcc -c<br>
&gt; -I/usr/lib/python2.5/site-packages/numpy-1.0.4.0002-py2.5-linux-x86_64.egg/numpy/core/include<br>
&gt; -I/usr/bin/python/2.5.1/include/python2.5 -fPIC -fno-omit-frame-pointer<br>
&gt; -pthread -fexceptions -ansi -D_GNU_SOURCE &nbsp;-DMX_COMPAT_32 -g &nbsp;main.c<br>
&gt;<br>
&gt; compile line for the other c-file is identical to main.c&#39;s<br>
&gt;<br>
&gt; *link:*<br>
&gt; gcc -g -pthread -shared &nbsp;main.o module.o &nbsp;-L/usr/bin/python/2.5.1/lib<br>
&gt; *-lpython2.5* -ldl -lm -lpthread -lutil -lmx -lmex -lmat -lm -lm -lstdc++<br>
&gt;<br>
<br>
</div>Ok, so far so good. Is /usr/bin/python/2.5.1/lib in LD_LIBRARY_PATH ?<br>
<br>
Out of curiosity: Are you building something against matlab, i.e. are<br>
you linking against MATLAB&#39;s mex?<br>
<br>
Cheers,<br>
<br>
Michael<br>
<br>
&lt;SNIP&gt;<br>
<div><div></div><div class="Wj3C7c">_______________________________________________<br>
Cython-dev mailing list<br>
<a href="mailto:Cython-dev@codespeak.net">Cython-dev@codespeak.net</a><br>
<a href="http://codespeak.net/mailman/listinfo/cython-dev" target="_blank">http://codespeak.net/mailman/listinfo/cython-dev</a><br>
</div></div></blockquote></div><br>