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
From: Philippe Naudin <philippe.naudin at supagro.inra.fr>> 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:? tetexNot an rpm expert but maybe some other package requires tetex? rpm -q --whatrequires tetex Or are these packages tetex requirement automaticaly changed to the replacement package? I think it works just once and won't prevent tetex from being reinstalled... JD
> 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: tetexDoes your package provide tetex? If not, use Provides: tetex And note, there is also Conflicts: but you don't need it I think. Simon> 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 > _______________________________________________ > CentOS mailing list > CentOS at centos.org > http://lists.centos.org/mailman/listinfo/centos >