I’ve found an interesting problem when I was in the process of building base packages for Jedo Linux. I could compile coreutils okay, but I then found that the command “rm” when used with the -r option, would fail. As an example:
mkdir -p /tmp/junk/foo/bar/mydir rm -rf /tmp/junk rm: cannot remove `/tmp/junk': Function not implemented
After spending a long time looking into this problem, making sure my toolchain was okay, etc, I finally got a hint of the problem from this post, relating to a build problem with BeOS that causes the same/simular problem.
The author goes on to mention that it can be reproduced under Linux, by making /proc inaccessible at build time.
Since I’ve been building in a chroot, /proc wasn’t mounted. After mounting it and building coreutils again – it worked!
So: To anyone out there building coreutils – MAKE SURE /proc IS MOUNTED!! :-)
UPDATE
Interesting…. it seems that the problem occurs anytime if /proc is not mounted! I’m not sure if this is a requirement of coreutils, or some kind of weird bug….