Hi, On Sun, Nov 05, 2006, Peter Eisentraut wrote: > > Sure, can you comment on the best approach? Are the names of the > > binaries hardcoded everywhere? > > > > Would shipping a libapt and binaries in a non-standard prefix be > > acceptable? e.g. --libdir /usr/lib/apt-rpm. > > > > I can easily change mach to use a different apt-get than the first > > in the PATH I suppose, I will have to change it anyway if we rename > > the binaries. > Where is this going to be installed? If it goes into the chroot, you > wouldn't have to rename anything, just uninstall the real apt.
The concept is to use the host's apt-get / yum with a "target" root directory being the chroot. E.g. "yum --installroot=/var/lib/mach/roots/fedora-development-i386-core" would be invoked to install the downloaded RPMs in the chroot. I suppose yum cascades this to "rpm --root" (except yum uses the Python bindings to invoke RPM, not "rpm"). I didn't try it yet, but I suppose the "apt-get" backend of mach works in the same way, as it generated an apt.conf file with: ... RPM { Ignore { }; Hold { }; Allow-Duplicated { "^gpg-pubkey$" }; Source { Build-Command "rpmbuild --rebuild"; }; GPG-Check "false"; RootDir "/var/lib/mach/roots/fedora-development-i386-core"; Options { "--promoteepoch"; } Install-Options "--root /var/lib/mach/roots/fedora-development-i386-core"; Erase-Options "--root /var/lib/mach/roots/fedora-development-i386-core"; } Dir { Etc "/var/lib/mach/states/fedora-development-i386-core/apt/etc/apt"; Cache "/var/cache/mach/fedora-development-i386/apt"; State "/var/lib/mach/states/fedora-development-i386-core/apt/var/state/apt"; Bin { scripts "/dev/null"; }; // do not execute lua scripts } So apt-rpm must really be installed on the host, on the side of the host's apt-get. mach not only bootstraps the chroot with the host's apt-get or yum, it wont even install yum or apt-get in the chroot by default, as updates and upgrades are handled with the hosts apt-get/yum as well with "mach yum" and "mach apt-get" (not all commands are wrapped like this, only yum, apt-get and apt-cache). Bye, -- Loïc Minier <[EMAIL PROTECTED]>