Vinay Sajip <vinay_sa...@yahoo.co.uk> added the comment: There is a problem in this area of the code, not especially with the patch but with how gcc works (or doesn't). To illustrate:
----------------------- Version info ----------------------- vinay@eta-hardy:/tmp$ uname -a Linux eta-hardy 2.6.24-29-generic #1 SMP Wed Aug 10 16:34:32 UTC 2011 i686 GNU/Linux vinay@eta-hardy:/tmp$ gcc --version gcc (GCC) 4.2.4 (Ubuntu 4.2.4-1ubuntu4) Copyright (C) 2007 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. ----------------------- Create an empty file: ----------------------- vinay@eta-hardy:/tmp$ touch dummy.c ----------------------- Compile a shared library from it: ----------------------- vinay@eta-hardy:/tmp$ gcc -shared -o libdummy.so dummy.c ----------------------- Invoke gcc with patched command line: ----------------------- vinay@eta-hardy:/tmp$ gcc -L /tmp -Wl,t -o /dev/null -ldummy /usr/bin/ld: t: No such file: No such file or directory collect2: ld returned 1 exit status ----------------------- It's not patch related, here's what happens with the unpatched line ----------------------- vinay@eta-hardy:/tmp$ gcc -Wl,t -o /dev/null -ldummy /usr/bin/ld: t: No such file: No such file or directory collect2: ld returned 1 exit status ----------------------- Calling ld directly works as expected. With no search path: ----------------------- vinay@eta-hardy:/tmp$ ld -t -o /dev/null -ldummy ld: mode elf_i386 ld: cannot find -ldummy ----------------------- With the search path supplied: ----------------------- vinay@eta-hardy:/tmp$ ld -t -L /tmp -o /dev/null -ldummy ld: mode elf_i386 -ldummy (/tmp/libdummy.so) ld: warning: cannot find entry symbol _start; not setting start address vinay@eta-hardy:/tmp$ So, ISTM that the find_library code needs changing to use ld, else it will not work on all platforms. ---------- nosy: +vinay.sajip _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue9998> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com