Re: tagging files (RPM packaging)

Werner Reisberger <[email protected]>
Newsgroups gmane.comp.programming.tools.scons.user
Message-ID <[email protected]>
On 2022-01-03 21:53, Mats Wichmann wrote:
> Manpage:
> 
>  Tag(node, tags)
> 
>     Annotates file or directory Nodes  ...
> 
> and it is indeed expecting to actually get a Node - this is why your
> working example works, you explicitly create the Nodes first.  it
> doesn't pay any attention to whether it's a string and if so generating
> a node from it.  Will leave it to Bill to comment whether it should
> (basically, calling env.argnodes(target) to convert, I believe).
> 
> Obviously, we can correct the docs if nothing else.

Sorry to come back with this so late but there is not only the 
issue/ambiguity string vs node.

Following the man page the tagging even doesn't work if I use a node:

    Tag(node, DOC)

should create a '%doc ' macro in front of a file name in a rpm spec 
file. But this call fails with

    NameError: name 'DOC' is not defined:

You have to say

    Tag(node, DOC=' ')

to make it work. This workaround can not be easily deduced from the man 
page and has to be applied to many other RPM file tags (e.g. CONFIG).

Please check my example code on GitHub as posted earlier.

--Werner
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.