After upgrading from rpm-3.0.2-5.x (RHL 5.2 updates) to rpm-3.0.3-5x (as provided on rpm.org), rpm building fails with a chown error. Example: [root@esme SPECS]# rpm -bp mutt.spec Executing: %prep + umask 022 + cd /usr/src/redhat/BUILD + cd /usr/src/redhat/BUILD + rm -rf mutt-1.0.1 + /bin/gzip -dc /usr/src/redhat/SOURCES/mutt-1.0.1i.tar.gz [...] + STATUS=0 + [ 0 -ne 0 ] + cd mutt-1.0.1 ++ /usr/bin/id -u + [ 0 = 0 ] + /bin/chown -Rhf root . /bin/chown: --no-dereference (-h) is not supported on this system Bad exit status from /var/tmp/rpm-tmp.67297 (%prep) Indeed, chown doesn't support -h on this RHL 5.2 system (all upgrades applied). [root@esme SPECS]# rpm -qf /bin/chown fileutils-3.16-10 I tracked this down to a change in /usr/lib/rpm/macros: %_fixowner [ `%{__id} -u` = '0' ] && %{__chown} -Rhf root In the 3.0.2-5.x RPM, this used to be: %_fixowner [ `%{__id} -u` = '0' ] && %{__chown} -Rf root The same problem occurs with regard to chgrp, i.e. error message complaining about the -h flag. Workaround: Setting both macros to their old values in /etc/rpm/macros Fix (I suppose): Changing /usr/lib/rpm/macros in the RPM to the old values. Regards, Thomas
Update: This problem is still present in the 3.0.4-5x RPMs.
*** This bug has been marked as a duplicate of 14271 ***