When I started, I had no idea how to do this, either, so I found a couple of documents about this. The URL which helped me the most is:
If you have any specific questions not answered by these, let me know.
The steps that I took, in general, are:
i pkginfo=pkginfo i postinstall=postinstall.sh d none /usr ? ? ? d none /usr/local ? ? ? d none /usr/local/bin ? ? ? d none /usr/local/include ? ? ? d none /usr/local/lib ? ? ? d none /usr/local/man ? ? ? d none /usr/local/man/man8 ? ? ? f none /usr/local/bin/rpm 0755 bin bin f none /usr/local/bin/rpm2cpio 0755 bin bin f none /usr/local/bin/find-provides 0755 bin bin f none /usr/local/bin/find-requires 0755 bin bin d none /usr/local/include/rpm 0755 bin bin f none /usr/local/include/rpm/dbindex.h 0644 bin bin f none /usr/local/include/rpm/header.h 0644 bin bin f none /usr/local/include/rpm/rpmlib.h 0644 bin bin f none /usr/local/lib/librpm.a 0644 bin bin f none /usr/local/lib/rpmpopt 0644 bin bin f none /usr/local/lib/rpmrc 0644 bin bin f none /usr/local/man/man8/rpm.8 0644 bin bin f none /usr/local/man/man8/rpm2cpio.8 0644 bin bin d none /var/local 0755 bin bin d none /var/local/lib 0755 bin bin d none /var/local/lib/rpm 0755 bin bin
PKG="rpm" NAME="Red Hat Package Manager" ARCH="sparc" VERSION="2.4.3" CATEGORY="administration" DESC="rpm 2.4.3, package installation/monitoring tool for maintaining files as part of packages" CLASSES="none"postinstall.sh:
#!/bin/sh
# RPM post-installation script
# Rob Payne 07/10/97
# Initialize Database
if [ -f '/var/local/lib/rpm/packages.rpm' ]; then
echo "RPM Database already exists, doing nothing"
else
echo "Initializing RPM Database, as it doesn't already exist"
/usr/local/bin/rpm --initdb
fi