libc, perl, python and nnrpd don't mix well

Erik Klavon erik at eriq.org
Thu Jan 9 00:22:48 UTC 2003


Hi

So I've been trying to track down some mysterious errors which occur
in nnrpd only when both python and perl are specified at configure
time. nnrpd segfaults on things like closing file descriptors or on
exit. On a whim I removed libc while linking nnrpd with perl and
python and my errors went away. I poked around a bit and noticed that
libc is only included when --with-perl is specified at configure
time. (Including libc explicitly on my platform isn't even needed.)
When --with-python is given to configure, one of the added arguments
to gcc when linking is -pthread. The gcc man page says under -pthread:
"Link a user-threaded process against libc_r instead of libc."
-pthread is needed for python. So it would seem that using both of
these libraries at the same time is problematic; the solution is to
dump the libc include at least whenever python is configured in.

Do we need libc included explicitly for other platforms/build
environments (I'm developing on FreeBSD at the moment). If so, would it
be possible to hack autoconf to drop the include of libc wherever
-pthread is supplied as an argument? 

This has been keeping me from moving forward on the new python
hooks. I'm going to start testing things with this new mod now.

Erik

-- 
erik         | "It is idle to think that, by means of words, | Maurice
  kl at von     | any real communication can ever pass | Maeterlinck
    eriq.org | from one [human] to another." | Silence


More information about the inn-workers mailing list