I have reviewed several related questions - the closest being: Extract the spec file out of an RPM -- AND I must add I would have phrased my question the same way. However, it seems the .spec file is not in the .rpm file (when it is a binary package).
So, my question is: how to get the information that originated in a spec file - at least as much as possible.
- I know there is a command to list the contents of the .rpm (at least
two actually -
rpm2cpio xxx.rpm | cpio -itv
being one - other commands to get what is required
- in particular: WHAT command(s) to get the pre/post/etc scripts that are run as part of the install process.
Ideally, the answer is a single command - but if it must be several commands, c'est la vie.
p.s. I have examined rpmbuild --rebuild
(says it expects source RPM) and cannot locate rpmlint
Thank you.