On Dec 27, 2007, at 11:35 AM, Jeff Johnson wrote:
>
> On Dec 27, 2007, at 11:30 AM, Ralf S. Engelschall wrote:
>
>> On Thu, Dec 27, 2007, Jeff Johnson wrote:
>>
>>> This patch. although more convoluted than simple,
>>> is likelier a better forward looking approach to
>>> accessing metadata uniformly no matter what
>>> the RPM_FOO_TYPE, or whether its a macro or a tag
>>> or an array or lua or ....
>>>
>>> https://lists.dulug.duke.edu/pipermail/rpm-maint/2007-November/
>>> 000567.html
>>>
>>> The patch is integrated (although largely untested
>>> and unused other than as a means to popuate
>>> RPMTAG_BUILDMACROS so far).
>>
>> Well, if you looked at my recent RPM Lua hacks in detail you will
>> see that I'm actually using rpm.macros() in all of them. This
>> *IS* exactly this patch you have applied. My OpenPKG-specific
>> "append-tag-value-to-macro" patch I applied today just allows one
>> in Lua
>> to fetch from rpm.macros() all(!) values of a tag, not just the last
>> one.
>
> Good.
>
> There are two possible implementations available with macros
> if you need/want a tuple.
>
> CSV is one, but note also that macro values are stacks, all the
> previous values are there, just not top-of-stack.
>
I should be less oblique:
A macro primitive to coalesce a stack into a CSV list is what I'd
like to see.
73 de Jeff
Received on Thu Dec 27 17:59:00 2007