LinuxQuestions.org
Visit Jeremy's Blog.
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 10-15-2003, 02:44 PM   #1
elluva
Member
 
Registered: Aug 2003
Location: Belguim, Ostend and Ghent
Distribution: Ubuntu
Posts: 600

Rep: Reputation: 30
Installing from Source Rpms(*.src.rpm)


Is anyone able to give me a straight answer on how to do this?
RPM's aren't a problem, neither is source, but I keep finding file packed in src.rpm
and can't seem to find a way to install them.

Tnx,
Elluva
 
Old 10-15-2003, 03:03 PM   #2
slightcrazed
Member
 
Registered: May 2003
Location: Lisbon Falls, Maine
Distribution: RH 8.0, 9.0, FC2 - 4, Slack 9.0 - 10.2, Knoppix 3.4 - 4.0, LFS,
Posts: 789

Rep: Reputation: 30
src.rpms are just the source files for the program, and they will be installed into whatever directory the creater of the program has chosen. I *think* that the usual place is /usr/src, but it can be different for any program. Once the source is installed you can cd to that directory and compile and install the program.

slight
 
Old 10-15-2003, 03:06 PM   #3
seriv
Member
 
Registered: Jul 2003
Location: Oak Ridge, TN
Distribution: red hat 9.0
Posts: 35

Rep: Reputation: 15
why?

Why don't they just use tar.gz or something like it?
-Seriv
 
Old 10-15-2003, 03:26 PM   #4
slightcrazed
Member
 
Registered: May 2003
Location: Lisbon Falls, Maine
Distribution: RH 8.0, 9.0, FC2 - 4, Slack 9.0 - 10.2, Knoppix 3.4 - 4.0, LFS,
Posts: 789

Rep: Reputation: 30
src.rpms are nice because developers can specify a path for where the source is stored, and if the app is ever upgraded, the old source gets copied over by the new source. This can be a nice feature if you were like me in the beginning and had source trees stored in 9 different directories.

slight
 
Old 10-15-2003, 03:51 PM   #5
case1984
Member
 
Registered: Feb 2003
Location: Baton Rouge, LA
Distribution: ubuntu
Posts: 137

Rep: Reputation: 15
I'm really having a hard time figuring this out also (I know nothing about programming and I've never compiled anything in my life).
I searched the web, looked at rute and the linux cookbook, and can't really find anything other than to use "rpmbild" to build an rpm from the source rpm, and then install that. Apparently I'm either doing it wrong or I didn't install rpmbuild when I installed RH9 - I can't find it.
Can anyone point me in the direction of an RPM for RPMBUILD (yes, I did look)?
Does anyone know where I can find a good how-to for compiling a program from source code?
TIA
Michael
 
Old 10-15-2003, 04:42 PM   #6
slightcrazed
Member
 
Registered: May 2003
Location: Lisbon Falls, Maine
Distribution: RH 8.0, 9.0, FC2 - 4, Slack 9.0 - 10.2, Knoppix 3.4 - 4.0, LFS,
Posts: 789

Rep: Reputation: 30
Personally, I avoid src.rpm's whenever possible. I think it is easiest with an RPM based system (RedHat or Mandrake) to just install from an .rpm, if you can find it for the program that you want. I prefer to dl source code as a .tar.gz or .tgz or .tar.bz2 (all 3 are referred to as tarballs commonly) and compile and install this way.

I keep all of my source trees in /usr/src/name_of_tarball.

So I dl program_v1.0.tar.gz from the makers website. I save it in my home directory, unzip it:

gunzip program_v1.0.tar.gz

and then untar it:

tar -xvf program_v1.0.tar

and it creats a directory called program_v1.0 in my home directory. I then su to root, and mv the source tree to /usr/src:

mv program_v1.0 /usr/src

and then exit back to my user, and then:

./configure && make

then su to root again and:

make install

exit back to user and then just run the proggie.

Trickykid wrote a great tutorial on installing from source, great place to start:

http://www.linuxquestions.org/questi...threadid=45094

Let me know if you have any questions.

slight
 
Old 10-15-2003, 05:32 PM   #7
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,353
Blog Entries: 55

Rep: Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541Reputation: 3541
can't really find anything other than to use "rpmbild" to build an rpm from the source rpm, and then install that. Apparently I'm either doing it wrong or I didn't install rpmbuild when I installed RH9 - I can't find it.

The RPM is called rpm-build. As root doing "rpm -q rpm-build" shows if it is installed and if it is, the version. Else it's is on one of your RH9 install cdroms.

Building from source rpm isn't hard unless it trips over dependencies but then you'll have the same problem building from source. Install the src.rpm, locate the spec file (default is /usr/src/redhat/SPECS/), then do "rpm -ba <specfile>" and it will build the rpm.
 
  


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
Idiot's guide to installing 'linux-source.src.rpm' in SuSE 9.1 personal needed! ZephyrAnima Linux - Newbie 1 08-12-2004 11:28 AM
Can't find the source after -Uvh *.src.rpm matthanley Linux - Newbie 1 04-28-2004 07:04 PM
RPM hell, how to remove source rpms? baudchaser Linux - Newbie 3 02-13-2004 10:16 AM
.rpms, .tar.gz, .tgz, .src.rpm, & .tar.bz2 whoots Mandriva 10 10-18-2003 12:08 PM
Difference between src.rpm files and source.rpm files ja_nch Red Hat 2 09-06-2003 06:12 PM


All times are GMT -5. The time now is 02:53 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