Hide Forgot
Description of problem: Binaries like rpm2cpio and probably some others that may be used to operate on standalone RPMs without the RPM DB should live in a separate subpackage that could be installed independently on the main rpm package. The same applies to libraries. Version-Release number of selected component (if applicable): rpm-4.11.1-7.fc20.x86_64 Actual results: rpm2cpio cannot be installed without pulling in quite a big 'rpm' package that (correct me if I'm wrong) initializes the RPM DB as part of its installation process. Expected results: Possibility to install rpm2cpio + needed libraries without all the other things and RPM db being initialized. Additional info: e.g. lorax does this because it is not possible to install only libraries removefrom rpm /usr/bin/* /usr/lib/rpm/platform/* /usr/share/locale/*
Erm... the act of installing ANY packages with rpm has to initialize an rpmdb if it doesn't already exist. Nothing to do with the rpm package (whether it initializes something on install would've been easy enough to check) There are no easy savings possible here: rpm2cpio requires librpm which requires libdb and all, plus the librpmio which requires the big bad NSS. And initializing the rpm libraries does need the configuration bits as well. The translations take some amount of space of course, but they are just as much for the libraries as they are for the binaries. Rearranging the packaging somewhat would be possible, but in the end it'd drag practically all the same things in, aint worth the trouble trying to save a few tens of kilos. The single actually BIG thing in rpm package is the upstream changelog, weighing at > 700kB which is roughly a third of the entire package size. Installing with --excludedocs helps with that.
Thanks for the explanation. I guess lorax should just leave all the executables from the RPM package in place. Does yum export the rpm's --excludedocs option somehow via its API?
Yum exports it as a config option at least, look for 'tsflags' in yum.conf manual.
Nice, thanks! And I see lorax already sets it. [1] [1] https://git.fedorahosted.org/cgit/lorax.git/tree/src/sbin/lorax#n232