[CentOS] the tag Obsoletes: in spec files

Philippe Naudin philippe.naudin at supagro.inra.fr
Tue May 31 12:57:56 UTC 2011


How exactly to use the tag "Obsoletes:" in a spec file ?

I need to offer texlive to users on Centos-5.6, so I packaged it (based
on a Mandriva src.rpm), and that works. 

But I want rpm to *replace* tetex by texlive, instead of just adding
texlive, when users do a : 
$ yum install texlive
(we have a local repo here).

So I added this line in texlive.spec :
Obsoletes:  tetex
and of course I rebuilt the package, and (of course) that just don't
work, despite tetex is listed among the Obsoleted packages :
$ rpm -qp --obsoletes texlive-20110312-0phn.x86_64.rpm
dvi2tty <= 5.3.1
jadetex
kpathsea <= 20100722
kpathsea-devel <= 20100722
kpathsea-static-devel <= 20100722
pdfjam <= 1.21
ps2eps <= 1.64
tetex
tetex-context
tetex-devel
tetex-dvipdfm
tetex-dvips
tetex-dvilj
tetex-latex
tetex-mfwin
tetex-texi2html
tetex-usrlocal
tetex-xdvi
etc...
(tetex is the CentOS one : tetex-3.0-33.8.el5_5.6)

Can someone explain me why this fails, and eventually an other way to
solve this problem ?

Thanks,

-- 
Philippe



More information about the CentOS mailing list