Red Hat Bugzilla – Bug 121134
device-mapper source package won't build as non-root
Last modified: 2007-11-30 17:10:40 EST
Description of problem:
The source package device-mapper-1.00.14-3.src.rpm will not build as a
Version-Release number of selected component (if applicable):
'rpmbuild --rebuild device-mapper-1.00.14-3.src.rpm' as non-root user
Building fails, the last few lines of message are
make -C man install
make: Entering directory
*** Installing in
/home/ed/bin/install: cannot change owner and/or group of
`/var/tmp/device-mapper-1.00.14-3-buildroot': Operation not permitted
make: *** [install] Error 1
make: Leaving directory
make: *** [man.install] Error 2
error: Bad exit status from /var/tmp/rpm-tmp.4056 (%install)
It should be possible to build the package as an ordinary user.
This is because of lines in the various makefiles like
@INSTALL@ -D -o $(OWNER) -g $(GROUP) -m 444 $$f $(MAN8DIR)/$$f; \
Because $(OWNER) and $(GROUP) are set to 'root' by configure, the
makefiles try to chown files to root, which isn't permitted. I think
you may be able to fix this using the --with-user or --without-user
options to configure.
The 'install' that I'm used to ignores -o when not running as root. It
looks like that behaviour has been changed without providing a
Should be fixed in device-mapper-1.00.17-1
(lvm2 package fixed similarly, lvm2-2.00.15-1.0)
device-mapper-1.00.14-3.src.rpm rebuilds for me non root on my test3
box synced against available rawhide.
One minor thing..is a missing buildrequirement for libselinux-devel
package that i hit...which imho isn't worthy of being a blocker. I'll
refile that as a new bug against device-mapper.
Here is the command I just ran:
rpmbuild --rebuild device-mapper-1.00.14-3.src.rpm
using .rpmmacros file:
%_topdir %(echo $HOME)/rpmbuild
1.00.17-1 is not available in rawhide for me to test afaict
I thought I submitted this to fc2 - but it isn't there, only in
fc2-scratch. Sorry about that.
(Might need the same selinux return 0->return 1 fix as lvm2 needed.
I can look next week.)
Submitted 1.00.17-2 to dist-fc3