Generating rpm spec from autoconf/automake packages for Fedora

Nils O. Selåsdal NOS at Utel.no
Wed Jun 16 07:08:07 UTC 2004


On Wed, 2004-06-16 at 09:00, Didier Casse wrote:
> Dear All,
>          I am trying to convert some autonconf/automake packages or
> libraries to rpms. Well to generate the spec, fitting
> the
> 
> -------------
> ./configure
> make
> make install
> -------------
Take a look at the fedora .spec template at
http://www.fedora.us/docs/spec.html
Now, remember that one doesn't use ./configure in a .spec usually,
but rather %configure , that will try to make the make install
install it temporary while packaging in non default location, such as 
/var/tmp/foo-2.4.3-root/ , now when you do an rpmbuild , and if it
fails, you can just go to /var/tmp/foo-2.4.3-root/ an look at which
files it installed.
> is straightforward! But the autoconf packages install lots of files around
> the system.
> 
> So the problem lies in dealing with the part:
> 
> %files
> %defattr(-,root,root)
> %{_bindir}/
Never do the above , it will make the package own the bindir
(usr/bin), you don't want that. use %{_bindir}/*
> %{_libdir}/lib*
> %doc AUTHORS
> %doc COPYING
> %doc README
> 
> 
> where we have to specify all the files that have been installed. Since the
> autoconf/automake packages have not been made by me, I do not know which
> files are being installed and I have to do everytime  a "make install" to
> watch which files are being installed!
A good packager must know every file of a package !

> Now is there a way to convert all these autoconf/automake packages
> directly to rpms or is there a systematic/automated system to know which
> files are being installed and fit directly in the specs?
See above.
> Now bear in mind that there are several of these packages and it would be
> tedious compiling and looking at one by one to know which files is being
> installed and the name of the files and location can change anytime. These
> packages weren't created by me so I have no control over them! Thanks for
> any kind help.
You really only need to know each directory it places files in, and 
which directories the package should own.

> 





More information about the fedora-devel-list mailing list