Issue
I am writing a rpm spec file to convert a tar.gz to a .rpm.
The tar contains all the files. To avoid re-writing of the spec everytime a new file is added/removed. I dont want to mention the files.
Is there a macro or somewhere I can use that will help with the above requirement? Or should a build procedure copy the file names to the .spec file
Solution
Just add the parent directory where you unpacked all of the files:
%setup
tar xvf mytarball.tar.gz -C %{buildroot}/mypkg
%files
mypkg
Answered By - jayhendren Answer Checked By - David Goodson (WPSolving Volunteer)