On Mon, 2004-11-15 at 23:15 -0500, Sam Varshavchik wrote: > This is a bug in rpm/glibc. stracing rpm shows that it globs out > "%{_bindir}/*" by calling stat() on each filename. > > In an RPM buildroot image, intra-package soft links are obviously broken, > since they point outside the buildroot. stat() fails on them. > > Bug 139460. > > Looks like recently rpm switched from lstat() to stat(), when globbing out > %files. > > This bug must've been hiding for quite some time. You'll only hit it if > you're building a package that installs softlinks for the first time, or if > the newer version of an installed package installs new soft links. > Otherwise, inside the build root the softlinks point to the existing > installation's files, outside of the buildroot, stat() succeeds, and rpm > processes the results from glob(). Most packages avoid this problem by using relative softlinks instead of absolute ones, e.g. ln -s ../../some.dir/some.file $RPM_BUILD_ROOT/other.dir/some.file instead of ln -s /some.dir/some.file $RPM_BUILD_ROOT/other.dir/some.file This then works both inside and outside the buildroot. Paul. -- Paul Howarth <paul@xxxxxxxxxxxx>