
I want to rebuild some rpms for various reasons, but mostly to change some of the configure settings. I must not be looking in the right place for directions on this, but all I can seem to find are directions on building a rpm file. I'm looking for tips and to make sure that my thinking is correct in what I do. Does building from srpm update the rpm database? To change some of the ./configure settings, would I simply change the spec file, or is there some other way of doing it? Thanks Jeff -- Registered Linux user #304026. "lynx -source http://www.rallycentral.us/~linux/jharris.asc | gpg --import" or "gpg --keyserver pgp.mit.edu --recv-key BD23A31E" Key fingerprint = FB8C 3210 8DE1 78F4 6505 5918 0C34 BE94 BD23 A31E

Hi Jeff, On Friday 29 August 2003 01:09, Jeff Harris wrote:
I want to rebuild some rpms for various reasons, but mostly to change some of the configure settings. I must not be looking in the right place for directions on this, but all I can seem to find are directions on building a rpm file.
Straight from 'man rpm': REBUILD AND RECOMPILE OPTIONS There are two other ways to invoke building with rpm: rpm --recompile <source_package_file>+ rpm --rebuild <source_package_file>+ When invoked this way, rpm installs the named source package, and does a prep, compile and install. In addition, --rebuild builds a new binary package. When the build has completed, the build directory is removed (as in --clean) and the the sources and spec file for the package are removed. Cheers, Andreas -- Andreas Otto <andreas@php4win.de> Using PHP on Windows? www.php4win.de

On Friday 29 Aug 2003 00:09, Jeff Harris wrote:
Does building from srpm update the rpm database?
No, installing the binary rpm package produced by your build updates the rpm database. Running ldconfig, or SuSEconfig after installs may be necessary if you add libraries, or want man pages and menu items available.
To change some of the ./configure settings, would I simply change the spec file, or is there some other way of doing it?
Basically yes, don't forget to increment the version number, and comment your changes in the changelog section, of the specfile. Packman rpm's seem to protect themselves against Online Update when they're installed, perhaps it's a feature of the Software manager for hand installed rpm's. You can also add patch files (made with diff -u), to the spec files, should you need to add fixes, or more complicated changes to the software package. I've added an english translation of the Packman FAQ, which might be useful. Rob http://packman.links2linux.de/index.php4?action=faq Die PackMan-FAQ Version 0.6 (en-0.0) Translated on 3rd March 2003, Rob Davies <rob_davies@ntlworld.com> 1. Packman-Team They pack Software packages together to facilitate simple installs of software that doesn't appear, or is found only in old superceded versions. 2. How to install With Browswer or FTP client download, then rpm -Uvh package.rpm 3. How to remove rpm -e 4) What do I do if a package for my Version or Distro isn't handy?/ # rpm --rebuild package.src.rpm If you're lucky everything it requires will be there and you can install the rpm built. Some software might not run on old Distros. 5. What do you do when there's a missing feature or missing patch? Again, when source packages are usable, you can rebuild it from your system. # rpm -i paketname.src.rpm The SPEC files are found under /usr/src/packages/SPECS/. It holds all the info that RPM requirries, to build a source package. Also all the steps for an instatl are to be found in the rpm data and header info. 6. What to do when a Package doesn't install first time? Simply send an email to the packager, perhaps he can help you solve it. $ rpm rpm -qpi paketname.rpm|grep Packager You don't know exactly what Info the Packager needs to know about your system? As a starting point, you can this Bashscript (info4packman) ftp://ftp.links2linux.de/pub/packman/info4packman download and run. $ bash info4packman The report created in /tmp/info4packman.log should be sent as well to the Packager. 7. I heard, that BInary packages allow all kinds of misschief. Isn't it insecure to install your Packages? Before installing you can check the package, to make sure nothing underhand happens to you. # rpm -qpil --changelog --scripts paketname.rpm | less Now you see who has built the package, what he's done since the last release, what files will be installed, and what scripts will be run. Additionally all our packagess are signed, so that you can check who really built the package, or if it's been manipulated and whether it's been downloaded without errors. You can check this in serveral ways. You should have GnuPG (1.x or later) or PGP (5.x or later) installed (PGP 2.x doesn't work). GNU Privacy Guard Homepage: http://www.gnupg.org Pretty Good Privacy Homepage: http://www.pgpi.net First you need the public key of the the packager : For GnuPG: $ lynx --dump ftp://ftp.links2linux.de/pub/packman/public-keys.asc | gpg --import Or the datafile ftp://ftp.links2linux.de/pub/packman/public-keys.asc dowanload and import like this : $ gpg --import public-keys.asc For PGP : $ lynx --dump ftp://ftp.links2linux.de/pub/packman/public-keys.asc | pgp -fka Or the Data File ftp://ftp.links2linux.de/pub/packman/public-keys.asc dowanload and import like this : $ pgp -ka public-keys.asc With RPM und GNU Privacy Guard: To do this you must create as user the file .rpmmacros with following contents: $ vi ~/.rpmmacros %_signature gpg %_gpg_name Waldemar Brodkorb (Linux rulez!) <brodkorb@onlinehome.de> %_gpg_path /home/waldemar/.gnupg/ %_gpg_bin /usr/bin/gpg Of course customised for your own login :-) Now you can check all downloaded packages before installation: $ rpm -vK package.rpm Only using GNU Privacy Guard: You need to download the sepeare ASCII Signature file of every package to do this. (download with Browser or FTP): $ gpg --verify package.rpm.asc (when they're downloaded into the same directory as the package) With RPM und Pretty Good Privacy: To do this you must create as user the file .rpmmacros with following contents: $ vi ~/.rpmmacros %_signature pgp %_pgp_name Waldemar Brodkorb (Linux rulez!) <brodkorb@onlinehome.de> %_pgp_path /home/waldemar/.pgp/ %_pgp_bin /usr/bin/pgp Of course customised for your own login :-) Now you can check all downloaded packages before installation: $ rpm -vK package.rpm Only with Pretty Good Privacy: You need to download the sepeare ASCII Signature file of every package to do this. (download with Browser or FTP): $ pgp package.rpm.asc (when they're downloaded into the same directory as the package) How do I extract files singly from the RPM's/SRPM's Very simply first list all the contents : $ rpm2cpio paket.rpm | cpio --list Single files can be extracted like this : $ rpm2cpio package.rpm | cpio --extract filename 9. Why is the package choice restricted to the SuSE Distro? This has several reasons : o There are few sites that offer RPMs specially for the SuSE Distro. o The Site is intended for German speaking LInux user's and SuSE is widely distributed in Germany. In spite of this, we plan to put on the Net various Debian packages, when we have had time to figure out the Debian policy and package management system. 10. Where do I find more information about RPM? Maximum RPM: http://rpmdp.org/rpmbook/ RPM-HowTo: http://www.ibiblio.org/pub/Linux/docs/HOWTO/other-formats/html_single/RPM-HO... Manpage: $ man rpm 11. Where else can I find RPM's for SuSE? http://www.suse.de http://www.mahowi.de/download/ http://www.suse.m-st.net/index.html http://sourceforge.net/projects/rpmsforsuse/ http://www.netonecom.net/~bbcat 12. Where can I find out about changes made to the software in new package versions? rpm -qp --changelog Paketname.rpm Mostly however the changes made to the pristine sources by the original author are more interesting. These are mostly found in a file CHANGES or CHANGELOG recorded. The files of installed packages can be found in /usr/share/doc/packages/<Package>/. * Rob FHS/LSB correction * Furthermore the changes are mostly found on the program Internet homepages. Normally the Homepage URL is included in the PackMan-Uebersicht (Overview) , should it be absent or if the Homepage site shows no Changelog, then it's a good idea over on Freshmeat.NET to make available the Homepage or a direct link to the change log. Almost every program will be registered on Freshmeat! 13. Can I help with the project? Yes, register with me (waldemar@links2linux.de) and I'll explain everything necessary to you.
participants (3)
-
Andreas Otto
-
Jeff Harris
-
Robert Davies