Hello,
I recently ran into a problem when compiling python 2.6.5 under FreeBSD 8.0-p2 . I searched around, asked in FreeBSD forums ( http://forums.freebsd.org/showthread.php?t=14268 ) and then e-mailed the python-help mailing list. The problem isn't yet solved. My problem is that when I compile python 2.6.5, I get a "sem_init: No space left on device" message when the script is building the _ssl extension: ------------------------------ (...) ===> Building for python26-2.6.5 (...) ranlib libpython2.6.a cc -pthread -Wl,--export-dynamic -o python Modules/python.o libpython2.6.a -ldl -lutil -lm libpython2.6.a(posixmodule.o)(.text+0x765): In function `posix_tmpnam': : warning: warning: tmpnam() possibly used unsafely; consider using mkstemp() libpython2.6.a(posixmodule.o)(.text+0x85c): In function `posix_tempnam': : warning: warning: tempnam() possibly used unsafely; consider using mkstemp() running build running build_ext building '_struct' extension creating build creating build/temp.freebsd-8.0-RELEASE-p2-i386-2.6 creating build/temp.freebsd-8.0-RELEASE-p2-i386-2.6/usr creating build/temp.freebsd-8.0-RELEASE-p2-i386-2.6/usr/ports creating build/temp.freebsd-8.0-RELEASE-p2-i386-2.6/usr/ports/lang creating build/temp.freebsd-8.0-RELEASE-p2-i386-2.6/usr/ports/lang/python26 creating build/temp.freebsd-8.0-RELEASE-p2-i386-2.6/usr/ports/lang/python26/work creating build/temp.freebsd-8.0-RELEASE-p2-i386-2.6/usr/ports/lang/python26/work/Python-2.6.5 creating build/temp.freebsd-8.0-RELEASE-p2-i386-2.6/usr/ports/lang/python26/work/Python-2.6.5/Modules cc -fPIC -fno-strict-aliasing -DNDEBUG -O2 -pipe -D__wchar_t=wchar_t -DTHREAD_STACK_SIZE=0x100000 -fno-strict-aliasing -I. -I/usr/ports /lang/python26/work/Python-2.6.5/./Include -I. -IInclude -I./../Include -I/usr/local/include -I/usr/ports/lang/python26/work/Python- 2.6.5/portbld.static/Include -I/usr/ports/lang/python26/work/Python-2.6.5/portbld.static -c /usr/ports/lang/python26/work/Python-2.6.5/Modules /_struct.c -o build/temp.freebsd-8.0-RELEASE-p2-i386-2.6/usr/ports/lang/python26/work/Python-2.6.5/Modules/_struct.o creating build/lib.freebsd-8.0-RELEASE-p2-i386-2.6 cc -shared -pthread -O2 -pipe -D__wchar_t=wchar_t -DTHREAD_STACK_SIZE=0x100000 -fno-strict-aliasing build/temp.freebsd-8.0-RELEASE-p2-i386-2.6 /usr/ports/lang/python26/work/Python-2.6.5/Modules/_struct.o -L/usr/local/lib -o build/lib.freebsd-8.0-RELEASE-p2-i386-2.6/_struct.so building '_ctypes_test' extension creating build/temp.freebsd-8.0-RELEASE-p2-i386-2.6/usr/ports/lang/python26/work/Python-2.6.5/Modules/_ctypes cc -fPIC -fno-strict-aliasing -DNDEBUG -O2 -pipe -D__wchar_t=wchar_t -DTHREAD_STACK_SIZE=0x100000 -fno-strict-aliasing -I. -I/usr/ports /lang/python26/work/Python-2.6.5/./Include -I. -IInclude -I./../Include -I/usr/local/include -I/usr/ports/lang/python26/work/Python- 2.6.5/portbld.static/Include -I/usr/ports/lang/python26/work/Python-2.6.5/portbld.static -c /usr/ports/lang/python26/work/Python-2.6.5/Modules /_ctypes/_ctypes_test.c -o build/temp.freebsd-8.0-RELEASE-p2-i386-2.6/usr/ports/lang/python26/work/Python-2.6.5/Modules/_ctypes/_ctypes_test.o cc -shared -pthread -O2 -pipe -D__wchar_t=wchar_t -DTHREAD_STACK_SIZE=0x100000 -fno-strict-aliasing build/temp.freebsd-8.0-RELEASE-p2-i386-2.6 /usr/ports/lang/python26/work/Python-2.6.5/Modules/_ctypes/_ctypes_test.o -L/usr/local/lib -o build/lib.freebsd-8.0-RELEASE-p2-i386-2.6 /_ctypes_test.so (...) building '_ssl' extension cc -fPIC -fno-strict-aliasing -DNDEBUG -O2 -pipe -D__wchar_t=wchar_t -DTHREAD_STACK_SIZE=0x100000 -fno-strict-aliasing -I. -I/usr/ports /lang/python26/work/Python-2.6.5/./Include -I. -IInclude -I./../Include -I/usr/local/include -I/usr/ports/lang/python26/work/Python- 2.6.5/portbld.static/Include -I/usr/ports/lang/python26/work/Python-2.6.5/portbld.static -c /usr/ports/lang/python26/work/Python-2.6.5/Modules /_ssl.c -o build/temp.freebsd-8.0-RELEASE-p2-i386-2.6/usr/ports/lang/python26/work/Python-2.6.5/Modules/_ssl.o cc -shared -pthread -O2 -pipe -D__wchar_t=wchar_t -DTHREAD_STACK_SIZE=0x100000 -fno-strict-aliasing build/temp.freebsd-8.0-RELEASE-p2-i386-2.6 /usr/ports/lang/python26/work/Python-2.6.5/Modules/_ssl.o -L/usr/local/lib -lssl -lcrypto -o build/lib.freebsd-8.0-RELEASE-p2-i386-2.6/_ssl.so sem_init: No space left on device ------------------------------ This then transforms into the following problem when importing SSLError, which is used by other apps: ------------------------------ Python 2.6.5 (r265:79063, May 15 2010, 19:22:30) [GCC 4.2.1 20070719 [FreeBSD]] on freebsd8 Type "help", "copyright", "credits" or "license" for more information. >>> from _ssl import SSLError as sslerror sem_init: No space left on device Traceback (most recent call last): File "<stdin>", line 1, in <module> ImportError: cannot import name SSLError ------------------------------ At the python-help mailing list, it was suggested that I compiled the port manually. I compiled python-2.6.5 manually ( "./configure; make" ) and I no longer got the "sem_init: no space left on device" error. When building the _ssl extension, it goes ok: ------------------------------ (...) building '_ssl' extension gcc -pthread -fPIC -fno-strict-aliasing -DNDEBUG -I. -I/tmp/python/Python-2.6.5/./Include -I. -IInclude -I./Include -I/usr/local/include -I/tmp/python/Python-2.6.5/Include -I/tmp/python/Python-2.6.5 -c /tmp/python/Python-2.6.5/Modules/_ssl.c -o build/temp.freebsd-8.0-RELEASE-p2-i386-2.6/tmp/python/Python-2.6.5/Modules/_ssl.o gcc -shared build/temp.freebsd-8.0-RELEASE-p2-i386-2.6/tmp/python/Python-2.6.5/Modules/_ssl.o -L/usr/local/lib -lssl -lcrypto -o build/lib.freebsd-8.0-RELEASE-p2-i386-2.6/_ssl.so building '_hashlib' extension (...) ------------------------------ So it narrows down the problem to some patch file that is applied, they suggested. I tried to look at the files, but I couldn't identify anything as the source of the problem. It was also suggested that I contacted the port maintainer to see if something could come up, and thus this e-mail. I am using a custom kernel because of the hplip port, but I only removed the ulpt module and added the snp module. I attach the GENERIC and the custom kernels as well as a diff for those two. Also, here is my system info. ------------------------------ %uname -a FreeBSD FPserver.WORKGROUP 8.0-RELEASE-p2 FreeBSD 8.0-RELEASE-p2 #2: Tue Jan 26 06:10:27 WET 2010 r...@fpserver.workgroup:/usr/obj/usr/src/sys/NOULPTKERNEL i386 ------------------------------ If you need further info (build logs, etc), please let me know and I'll send you. Can you help me? Best regards, -- Bernardo Maciel
diffCustomKernelGeneric.diff
Description: Binary data
GENERIC
Description: Binary data
NOULPTKERNEL
Description: Binary data
_______________________________________________ freebsd-python@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-python To unsubscribe, send any mail to "freebsd-python-unsubscr...@freebsd.org"