Hi All, Using: Python 2.5.2, f2py ver 2_4422, gfortran --version GNU Fortran (GCC) 4.2.3 (Ubuntu 4.2.3-2ubuntu7) on kubuntu 8.04 (Hardy) up-to-date on a Thinkpad T60. After building and using an f2py-generated lib for a while with this command: f2py --opt="-O3" -c -m fd_rrt1d --fcompiler=gnu95 \ --link-lapack_opt *.f I had to regenerate it after some code changes (just commenting out some debugging info). Altho the shared lib gets built correctly, when the calling python is run, I now get this: ./1d.py Traceback (most recent call last): File "./1d.py", line 27, in <module> from fd_rrt1d import * ImportError: /home/hjm/shaka/1D-Mangalam-py/fd_rrt1d.so: undefined symbol: zgemm_ sure enough, nm reports it as undefined: nm fd_rrt1d.so |tail 000065b0 t string_from_pyobj U strlen@@GLIBC_2.0 U strncpy@@GLIBC_2.0 0001df40 b u.1294 00013bee T umatrix1d_dms0_ 000128c3 T umatrix1d_dms1_ 00015458 T umatrix1d_ms0_ U zgemm_ U zgemv_ U zgesv_ but why the recent change? Google and the numpy list seem not to have heard about this one.. -- Harry Mangalam - Research Computing, NACS, E2148, Engineering Gateway, UC Irvine 92697 949 824-0084(o), 949 285-4487(c) -- ..Kick at the darkness til it bleeds daylight. (Lovers in a Dangerous Time) - Bruce Cockburn
The problem seems to have been a conflicting version of liblapack. I installed a newer version of liblapack (liblapack-dev, from the Ubuntu 8.04 tree) and recompiled and that seems to have addressed the issue. Even tho the previously offending symbols are still undefined, the wrapped code doesn't complain about them and it runs to completion satisfactorily. hjm On Wednesday 30 July 2008, Harry Mangalam wrote:
I had to regenerate it after some code changes (just commenting out some debugging info). Altho the shared lib gets built correctly, when the calling python is run, I now get this:
./1d.py Traceback (most recent call last): File "./1d.py", line 27, in <module> from fd_rrt1d import * ImportError: /home/hjm/shaka/1D-Mangalam-py/fd_rrt1d.so: undefined symbol: zgemm_
sure enough, nm reports it as undefined:
nm fd_rrt1d.so |tail 000065b0 t string_from_pyobj U strlen@@GLIBC_2.0 U strncpy@@GLIBC_2.0 0001df40 b u.1294 00013bee T umatrix1d_dms0_ 000128c3 T umatrix1d_dms1_ 00015458 T umatrix1d_ms0_ U zgemm_ U zgemv_ U zgesv_
-- Harry Mangalam - Research Computing, NACS, E2148, Engineering Gateway, UC Irvine 92697 949 824-0084(o), 949 285-4487(c) -- ..Kick at the darkness til it bleeds daylight. (Lovers in a Dangerous Time) - Bruce Cockburn
participants (1)
-
Harry Mangalam