Creating an installable RPM
I have never created an RPM file [never felt the need to :D]. However, I now have this folder structure of some directories which I need to convert into an RPM so that it can be installed in some other machine.
More clearly, I have the following directory structure within my "source" directory [the one to be packaged]. 0/ 1/ 2/ 3/ 4/ 5/ 6/ 7/ 8/ 9/ Each of them is a directory with depth "n" [constant across all the directories]. I need to create an RPM such that it will install this directory structure into some path in a different machine. I would appreciate a simple step by step guide for this. Thanks |
Couldn't you just compress the "source" directory in a way that keeps the directory structure?
|
I will tell you what I have. I have the entire source directory in a tar format. Problem is I have never ever created an RPM. I was going through some pages, but didnt really understand much. There was some mention about creating a spec file. If you can kindly help me with that, I would be really grateful.
All I need is that the directory structure that I have [in store.tar] needs to be copied to a particular location on using the rpm. I need to create an RPM for this. Please help! |
|
Thanks for the link. I have now been able to create an RPM which does what I wanted to.
I have a new problem though. When I want to uninstall this particular RPM, giving a rpm -e <packagename> removes only the files under %files section, but doesnt remove the directory structure. What can I do about it? |
this link should help
www-128.ibm.com/developerworks/library/l-rpm3/ this will tell you how to add a post script to your rpm. i am assuming that in this post script you can tell it to remove the created directories. |
All times are GMT -5. The time now is 09:57 PM. |