LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   How to install source rpm's? (https://www.linuxquestions.org/questions/linux-newbie-8/how-to-install-source-rpms-8598/)

concoran 11-11-2001 06:09 PM

How to install packages from 'source rpm's?
 
This is seemingly a stupid question.
But I would like to know how to install a package from what they call 'source rpm'?
I have seen some packages come as xxx.src.rpm.

WindozBytes 11-12-2001 03:04 AM

I always thought the source code rpm was just that, an rpm for installing the source code on your machine. So, if you want to tinker with it or compile it just for the exercise, you can, but if you just want to execute, you don't need the source rpm.

dorward 11-12-2001 05:45 AM

Directory paths may vary between distros, but something like this should work:

Code:

rpm -ivh file.src.rpm
cd /usr/src/RPM/SPECS/
rpm -ba file.spec
cd ../RPMS/i386
rpm -ivh file*rpm

The initial install puts the source code, patch files, and spec (compile instructions) in various directorys. The the ba section is for Build All - which builds the rpm going through all the stages specified in the spec file).

ugge 11-13-2001 02:03 PM

You can make .rpm file by running rpm --rebuild <filename>.src.rpm
This will compile the source code to binary files and then make a regular rpm-package like the ones found on the internet.

There is also an option called [b]--recompile[b] I think, this is supposed to compile the source and leave the binaries as they are. Haven't tried this optin my self.


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