if [ ! -r var/lib/rpm/Packages ]; then
  ( cd var/lib/rpm/tmp ; cp -a * .. )
fi
( cd var/lib/rpm && rm -f tmp/* && rmdir tmp )
# Symlinks:
( cd usr/bin ; rm -rf rpmquery )
( cd usr/bin ; ln -sf ../../bin/rpm rpmquery )
( cd usr/bin ; rm -rf rpmverify )
( cd usr/bin ; ln -sf ../../bin/rpm rpmverify )
( cd usr/lib64 ; rm -rf librpmio.so.7 )
( cd usr/lib64 ; ln -sf librpmio.so.7.0.1 librpmio.so.7 )
( cd usr/lib64 ; rm -rf librpm.so )
( cd usr/lib64 ; ln -sf librpm.so.7.0.1 librpm.so )
( cd usr/lib64 ; rm -rf librpmsign.so )
( cd usr/lib64 ; ln -sf librpmsign.so.7.0.1 librpmsign.so )
( cd usr/lib64 ; rm -rf librpmio.so )
( cd usr/lib64 ; ln -sf librpmio.so.7.0.1 librpmio.so )
( cd usr/lib64 ; rm -rf librpm.so.7 )
( cd usr/lib64 ; ln -sf librpm.so.7.0.1 librpm.so.7 )
( cd usr/lib64 ; rm -rf librpmbuild.so.7 )
( cd usr/lib64 ; ln -sf librpmbuild.so.7.0.1 librpmbuild.so.7 )
( cd usr/lib64 ; rm -rf librpmbuild.so )
( cd usr/lib64 ; ln -sf librpmbuild.so.7.0.1 librpmbuild.so )
( cd usr/lib64 ; rm -rf librpmsign.so.7 )
( cd usr/lib64 ; ln -sf librpmsign.so.7.0.1 librpmsign.so.7 )
