LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-16-2004, 09:36 PM   #1
halechris
LQ Newbie
 
Registered: Nov 2004
Posts: 1

Rep: Reputation: 0
Question Srpm?


I am currently attending courses to become LPIC certified and while studying for part II of the exam a question arised in the class that I am hoping somebody might be able to respond to.
While discussing compiling source code into an actual .rpm, one of the directories that is discussed is /usr/src/redhat/SRPMS. We understood what all the other directories where used for when compiling source code. But what exactly is the SRPMS directory and what purpose does it serve. The explanation in the textbook is source RPM. A little more insight as to what exactly this is. The directory /usr/src/redhat/RPMS was stated that it contains the FINAL binary rpm. So maybe I am putting too much or too little thought into this but huh? What exactly is the SRPMS? and it purpose?
 
Old 11-16-2004, 10:23 PM   #2
btmiller
Senior Member
 
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,275

Rep: Reputation: 370Reputation: 370Reputation: 370Reputation: 370
SRPM is, as your book states, source RPMs. When you install an SRPM you actually are putting the soiurce code for the program in the /usr/src/redhat directory hirerarchy. You can then go ahead and use the rpmbuild command to build a regular (binary) RPM, compiling the code, making the binaries, etc. If you have a source RPM you can modify the source and/or the RPM spec file if you want to make changes. The directory structure in /usr/src/redhat just lays the source out in a reasonably coherent fashion.
 
Old 11-16-2004, 11:04 PM   #3
bigrigdriver
LQ Addict
 
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian Jessie 8.4
Posts: 5,873

Rep: Reputation: 348Reputation: 348Reputation: 348Reputation: 348
When you install a .src.rpm, you get the tarball (plus any attendant patch files) in the SOURCES folder, and the rpm .spec file in the SPECS folder. To compile a binary rpm, you would use the rpm -bb option to get a binary compiled for your system. The new binary would be placed in the RPMS folder.
If you also want a new .src.rpm for your system, use rpm -ba (to get both a binary and source rpm). The new binary will be placed in the RPMS folder, and the new .src.rpm will be placed in the SRPMS folder.

I should add, if there is anything you want to add to the new binary/source package, you copy it to the SOURCES folder, and it will be added to the package. You would then have to also edit the .spec file appropriately to account for the new parts, and what rpm should do with them.

Last edited by bigrigdriver; 11-16-2004 at 11:07 PM.
 
  


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
Looking for RPM/SRPM stefaandk Red Hat 1 06-28-2005 09:36 AM
finding srpm edgjerp Linux - Software 1 06-26-2005 03:59 PM
how do I install an SRPM ricklerre Linux - Newbie 3 07-27-2004 09:45 PM
SRPM or ISO?? w0000422 Linux - General 5 01-07-2004 08:01 PM
noarch SRPM demmylls Linux - General 1 12-18-2003 03:13 PM


All times are GMT -5. The time now is 06:34 AM.

Main Menu
Advertisement
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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration