Hi List,
I just started working on RPM Packaging and had few questions.
1. Where can i find good "WORKING" Examples of packages.spec
2. Is mach, or mock, really the better version of rpmbiuld ?
OK, so you want to build a binary RPM package for deployment on your
servers. You have a .spec file or .src.rpm that you got from one of the many
repositories such as freshrpms.net or
dag.wieers.com, or that you wrote yourself.
Why not just build it using
rpmbuild
?There are several problems you may come across.
- Given a spec file, rpmbuild won't download the source tarball and/or patches. You have to fetch those yourself into the SOURCES directory.
- rpmbuild will abort if any build-time dependencies are missing, forcing you to stop what you're doing, and go and build and install those packages too.
- When your package configures itself, it may auto-detect libraries which are available on your build system, but which are not going to be available on the target system. For example, if openldap-devel is present then openldap may be linked into your binaries, but if the RPM doesn't declare openldap as a dependency, then it will fail to run on the target system. This is an insiduous problem, which I call "the curse of autoconf".
- You can only build packages for the same type of system as your build machine (e.g. CentOS 4 binaries on a CentOS 4 build system)
If you want an example of how bad the problem is, try building the package
perl-SOAP-Lite from its
spec file. You will
quickly find yourself in dependency hell, with 16 other packages needing to
be installed or built, all in the correct order.
The solution: mach
3. Can i install "use sudo yum install <package name> , inside a SPEC file ?
4. How can do a CHROOT inside a SPEC File
5. How do i introduce versions, r=for RPMs, when there is NO version in the SCM ( we are using Mercurial )
6. Is there a working automation framework for rpmbuild ?
7. I tried using autospec , but it includes all the source files as well. I used it as:
tar tzf myapp-0.1.tar.gz | autospec -bd -c GPL -g Utilities/System -n myapp-0.1 -l '' > myapp.spec
Thanks,
-Kamal.
-- packaging mailing list packaging@xxxxxxxxxxxxxxxxxxxxxxx https://admin.fedoraproject.org/mailman/listinfo/packaging