To extract or “unbuild” and RPM so you can see its files you have to use two programs. The first is rpm2cpio, the second is cpio.
rpm2cpio: Extract cpio archive from RPM Package Manager (RPM) package.
cpio – allows a user to copy file to and from an archive.
[code lang=”bash” title=”Do this as root”]linux:/tmp/rpmsource# rpm2cpio <>.src.rpm | cpio -idmv [/code]
Explanation: rpm2cpio takes the rpm and runs the extraction that is then piped through cpio to extract the files to a local directory. FLAGS: -i extract, -d make directories where needed, -m preserve modification time, -v verbose mode will list the names of the files as they are extracted.
I’m not sure if this will work for non-src rpms.