Johnny Hughes a écrit : > Notice the .el5 in our (and RedHat's) build. The one with a .el5 is > "greater than" the one without .el5, so RPM wants to replace the lower > version (yours, without the .el5) with the higher version (ours, with > .el5). > > What you need to do (if there is a %{?dist} in the "Release" string) is > to create a .rpmmacros file in the "home" directory of the user that you > use to build RPMS with, and in that file, use a "dist" tag that starts > with something that is "greater than" .el5 ... it could be .kv, .kovac, > or .el5.kv ... etc. > > The line would look like: > > %dist .el5.kv Thank you very much for your detailed explanation. I tried out what you suggested, and it works as expected! > > If you are building as root, you also want to probably change that as > bad things can happen as root if an RPM is not properly written (bad > things as in it can install things to the system when it builds). Here > is an example of how to build as a non root user: > > http://www.owlriver.com/tips/non-root/ Usually - on my Arch system - I build things as normal user. But if it's only for rebuilding CentOS SRPMS from [base], I don't bother to setup a build environment for a normal user. But I know what you mean: I've been using Slackware for a few years, where my habit was to write and use SlackBuild scripts as root... I remember very well how it felt doing an rm -rf $TMP/ with an unset TMP variable :oD Niki