Python test suit /tmp removal

Matthew Burgess matthew at
Thu Aug 9 03:28:17 PDT 2007

On Thu, 09 Aug 2007 04:42:09 -0500, Randy McMurchy <randy at> wrote:
> dragosi at wrote these words on 08/08/07 23:50 CST:
>> I've noticed that the Python test suite removes the /tmp directory when
>> "make test" is run as root.
> It seems someone else mentioned this a while back.

I remember running into this, so hope that the above report was from me.

> I can't remember what we decided to do.

Well, the reason for the removal of the /tmp dir is that one of the tests does a recursive delete on the /tmp directory.  This means that if /tmp is empty (which it normally is during a build of Python early on in a BLFS build), the directory itself will be removed.  My workaround was to simply `touch /tmp/dummy' prior to the Python testsuite run and `rm /tmp/dummy' immediately afterwards.  As you point out, Randy, BLFS already warns folks not to compile/test stuff as root, so whether or not the workaround is suitable for the book instructions is up to you.



More information about the blfs-dev mailing list