how to use the source (rpm)?
It is reletively easier to use the tar ball to install.
While could anybody tell me how to recompile the source rpm? My specific question is: 1. where can I find the source which rpm installs? 2. how to compile? (gcc or something? do I need additional option?) Really I am new to this. Thank you for any input. Qu Chen |
you just have to find a whateverprogram.src.rpm package and do:
rpm -i whateverprogram.src.rpm it will put the files for example if you're using redhat in /usr/src/redhat . Where you will find the spec and source directories. You can create an rpm from there, www.rpm.org, or just take the source and compile it as always, using ./configure make and make install. |
Really Thank you very much aizkorri. :)
I am using RH9. Do you mean the rpm command rpm -i whateverprogram.src.rpm, would likely to put everything in /usr/src/redhat/whateverprogram? And as for the compile, do you mean the process is identical to the "tar.gz" format? if so what is the difference between these two? Sorry for the basic question but I am really new. Qu Chen |
If you want to install a rpm, you don't have to compile anything, you just look for e.g emacs-20.7-1.i386.rpm in the net if you want to install emacs and then type this as superuser:
rpm -i emacs-20.7-1.i386.rpm --without src If you want to find the tar.gz files, in /usr/src/redhat you have this directories: SPECS RPMS SOURCES, and some more. After doing rpm -i yourFile.src.rpm In SOURCES you'll find the source code, it is actually a tar.gz file. In the other hand, you can create a new rpm changing what you want or just creating againg the rpm in the way it is explained in the web page I gave to you. |
Ah, again thank you aizkorri. :D
I now understand the output of rpm -i whateverprogram.src.rpm is a tar.gz file in /usr/src/redhat/SOURCE Really your explaination helps me a lot :) Qu Chen |
you'd use "rpm -ta blah.src.rpm" to actually compiel the source rather than just installingt the source, which is generally pretty useless.
|
Ah acid_kewpie. Thank you for your message.:) But would you tell me why installing the source is useless? Actually I have to try all the above thing when going back but I think it is OK if I use "rpm -i" and receive a tar.gz, or, there are some other things I need to know?
Besides, thank you for "rpm -ta blah.src.rpm". I think it will do everything and leave the executable file. While in this way, how could I see the "makefile" to know where the executable file is installed? Sorry if my question sounds stupid... but sincerely thank you all. Qu Chen |
And Chris, the number of your post is ... :eek: :eek: :eek:
|
i think it's -ta... might also be -tb, -ba or -bb, depending on how you want it built...
i just meant it was pointless as -i-ing it will just dump a tar.gz in /usr/src/RPM/SOURCES or similar, in which case you might have just got the source tarball in the first place... as for where the binaries go.. doesn't matter. it'll be on your path somewhere, so just run it. |
Thanks again Chris. I think your last sentence means the binary would be put into the directory path redefined by some certain file (I forgot the exact name).
Thank you all :D Qu Chen |
All times are GMT -5. The time now is 05:46 AM. |