RPM Community Forums

Mailing List Message of <rpm-users>

Re: macro args broken

From: Arkadiusz Miskiewicz <arekm@maven.pl>
Date: Tue 26 Feb 2008 - 10:36:07 CET
Message-Id: <200802261036.07922.arekm@maven.pl>
On Thursday 21 of February 2008, Ralf S. Engelschall wrote:
> On Wed, Feb 20, 2008, Elan Ruusamäe wrote:
> > ~/.rpmmacros:
> >
> > %argtest(p:b:a:) %{-b:b=%{-b*}} 1=%1
> >
> > $ rpm -E "%argtest -p 1 -b 2 param1 param2"
> > b=2 1=param1
> >
> > $ rpm -E "%argtest param1 param2 -p 1 -b 2"
> >  1=param1
> >
> > thus, if parameters are passed before options, the options are not to be
> > seen
>
> Yes, the RPM macro parser uses positional options and does not support
> permutations of options and arguments (as it was based on getopt and
> because it makes sense for macros anyway). 

Hm, so how this was done in rpm4? (where macro args worked fine that way)

>                                        Ralf S. Engelschall


-- 
Arkadiusz Mi¶kiewicz        PLD/Linux Team
arekm / maven.pl            http://ftp.pld-linux.org/
Received on Tue Feb 26 11:09:16 2008
Driven by Jeff Johnson and the RPM project team.
Hosted by OpenPKG and Ralf S. Engelschall.
Powered by FreeBSD and OpenPKG.