Hi Daryl -- Thanks for the tips. Google tells me that otool -L is the equivalent of ldd, so
> earthsea:~ adamshaw$ otool -L /Library/Python/2.6/site-packages/_pg.so > /Library/Python/2.6/site-packages/_pg.so: > /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current > version 125.2.10) Then, no dice (my nm won't accept --dynamic): > earthsea:~ adamshaw$ nm /usr/lib/libSystem.B.dylib | grep [Cc]lear > 000000000017a2ac S $ld$hide$os10.4$___clear_cache > 000000000017a2ad S $ld$hide$os10.5$___clear_cache > 00000000000066d0 T _OSAtomicTestAndClear > 00000000000066d0 T _OSAtomicTestAndClearBarrier > 000000000013cae0 T ___clear_cache > 00000000000f6725 t __asl_clear_msg > 0000000000059fa5 t __mdns_hostent_clear > 0000000000059f39 t __mdns_query_clear > 000000000005a733 t __mdns_reply_clear > 00000000000c7b79 T _acl_clear_flags_np > 00000000000c7aa0 T _acl_clear_perms > 000000000008de17 T _clearerr > 00000000000926b8 T _clearerr_unlocked > 000000000009fe0f T _dbm_clearerr > 0000000000118392 T _memberdDSmig_ClearCache > 00000000001186eb T _memberdDSmig_ClearStats > 0000000000004eeb t _szone_malloc_should_clear > 000000000007e4fa T _uuid_clear - Adam On Jun 15, 2011, at 6:25 AM, Daryl Tester wrote: > On 15/06/11 08:44, Adam Shaw wrote: > >> So far so good. But I get a complaint about _PQclear when I try to import pg. > > I've struck this problem before at a previous job (*not* the same platform, > though), but unfortunately my notes remained with that company when I moved > on. > >>> ImportError: dlopen(/Library/Python/2.6/site-packages/_pg.so, 2): Symbol >>> not found: _PQclear >>> Referenced from: /Library/Python/2.6/site-packages/_pg.so >>> Expected in: flat namespace >>> in /Library/Python/2.6/site-packages/_pg.so > > (* Assuming OSX is close enough to Unix that the devtools are similar *) > > Try diagnosing by running "ldd /Library/Python/2.6/site-packages/_pg.so" > to see which postgres client library is being used, then run > "nm --dynamic /path/to/postgres_client_lib" to see if PQclear is > actually defined as exported or not. Pay particular attention to any > files that _pg.so might report missing (it might pay to run ldd across > the client lib to see if that's missing any dependencies as well). > > > -- > Regards, > Daryl Tester > Handcrafted Computers Pty. Ltd. > _______________________________________________ > PyGreSQL mailing list > [email protected] > http://mailman.vex.net/mailman/listinfo/pygresql > _______________________________________________ PyGreSQL mailing list [email protected] http://mailman.vex.net/mailman/listinfo/pygresql
