Hi, On Tue, 3 Jun 2008, Andre Hübner wrote:
I use similar specs for a time. Variables in %install or %post sections work on each maschine where i installed it. if there is no way to use my variable in %files section i have to install on hard linked folder and copy/remove in %post and %postun section. not very nice... why %files is different to %install etc?
Because the %files section provides the list of filenames (rpm -ql) whereas the %install section simply expands to a shell script (hence you can use backticks). The filenames stand for themself and don't have to be interpreted, and that's a good thing, you don't want to run huge shell-scripts just to get a file list. If your package really insists on having its file in a directory named according to its hostname, and can't be configured in some other way, then I would advise you to place the files in some fixed directory, and only create a softlink (named like hostname) to that directory. Ciao, Michael.