You don't need --relocate=targetdir
--root, in *effect*, does a chroot()
I use it to install a base system into my chroot() jails before using
/sbin/chroot to install other required elements. You certainly might
need --nodeps, depending on the RPM's requirements, since you will have
a new, empty RPMDB, and that, of course, will fail all dependencies

--relocate /=targetdir

I seem need to specify that or it fails due to permssion, e.g.:

~> rpm --root /home/dlooney/tdir --nodeps -ivh
/usr/local/src/xfishtank-2.1tp-7.i386.rpm
warning: /usr/local/src/xfishtank-2.1tp-7.i386.rpm: V3 DSA signature:
NOKEY, key ID db42a60e
Preparing...                ###########################################
[100%]
   1:xfishtank              ###########################################
[100%]
error: unpacking of archive failed on file
/usr/X11R6/bin/xfishtank;43a21a26: cpio: open failed - Permission denied

Ah, so what I think is happening is becoz of --nodeps, /usr/X11R6/bin does
not exist (the dependant RPM would have created it) and so cpio cannot install
the file in that directory (prolly doesn't use the -d flag). But the --relocate
flag might cause cpio to use the -d flag, creating /usr/X11R6/bin for you.

When I use --root, I am installing everything that RPM needs to get installed
(about 35 RPMS) so I haven't encountered this problem, coz I'm not using 
--nodeps

All in all, rpm2cpio is prolly the easiest to work with ....

--
Michael O'Keefe                      |          [EMAIL PROTECTED]
Live on and Ride a 03 BMW F650GSDakar|          [EMAIL PROTECTED]      / |
I like less more or less less than   |Work:+1 858 845 3514        /  |
more. UNIX-live it,love it,fork() it |Fax :+1 858 845 2652       /_p_|
My views are MINE ALONE, blah, blah, |Home:+1 760 788 1296       \`O'|
blah, yackety yack - don't come back |Fax :+1 858                _/_\|_,


--
[email protected]
http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-list

Reply via email to