LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 06-16-2004, 12:02 AM   #1
Brian of Gep
Member
 
Registered: Jul 2003
Location: Arlington, Texas
Distribution: Red Hat 9, Fedora Core 2-test1
Posts: 55

Rep: Reputation: 15
%file attribute for RPM SPEC files


I'm attempting to make some RPM packages, but I'm not sure how to go about writing the %file list.

The programs that I'm trying to install have makefiles, so I'll be using .configure/make/make install, but I don't know how to determine what all files need to be associated with the RPM. I've googled, but I can't seem to find a solution, anywhere.

Any help would be greatly appreciated!
 
Old 06-16-2004, 10:23 AM   #2
Ice9
Member
 
Registered: Jun 2002
Location: Belgium
Distribution: Sidux
Posts: 313

Rep: Reputation: 30
Ok, I'm trying to package rpm files myself with mixed success (I have packaged a few and I'm still cursing on others ...), so I can't say for sure that I'm doing the right thing here but generally I leave the %files section empty and only put someting in there when I get an error message complaining about installed but unpackaged files, I then include these files under the %file section.
 
Old 06-18-2004, 04:38 AM   #3
Brian of Gep
Member
 
Registered: Jul 2003
Location: Arlington, Texas
Distribution: Red Hat 9, Fedora Core 2-test1
Posts: 55

Original Poster
Rep: Reputation: 15
Does that mean that all installed files are then put on the list? Else it would render the RPM un-uninstallable.
 
Old 06-18-2004, 04:51 AM   #4
Ice9
Member
 
Registered: Jun 2002
Location: Belgium
Distribution: Sidux
Posts: 313

Rep: Reputation: 30
As I understand it the %files section lists all the files that need ot be packaged for the rpm to install.
When you run rpmbuild -ba package.spec it generates a directory /var/tmp/package_name-buildroot

If you cd to /var/tmp/package_name-buildroot and do
$ find
it will produce a list.
Make sure that the files listed are present in your %files section.

But as I said I proceed by elimination (until I learn about a better way) so I leave the %files section blank and when at the end of the process I get the list of "installed but unpackaged files" I copy that list in the %files section and it works all the time.

There's probably a much "cleaner" or "more correct" way of doing this but I don't know about it yet.
I packaged a bunch of files and they install without any problem on various systems.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
RPM Spec file creation, %files section question davidas Linux - Software 1 09-13-2007 02:26 AM
questions on writing own rpm .spec file adrianmak Linux - Software 0 08-18-2005 06:03 AM
%file attribute for RPM SPEC files Brian of Gep Fedora 0 06-15-2004 07:12 PM
RPM Spec file creation: %file section question davidas Linux - Newbie 0 03-16-2004 10:36 PM
rpm spec files pk21 Programming 3 06-11-2003 04:53 AM


All times are GMT -5. The time now is 01:27 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration