Re: %{expand:...} documentation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On Aug 27, 2007, at 2:26 PM, Jos Vos wrote:

Hi,

Where can I find documentation about how %{expand:...} exactly is
defined and when it is useful?


The macro primitive %{expand:...} is like eval in shell.

All it does is continue a macro expansion from the beginning, not
the end, of whatever was justr expanded.

So if, say, you wanted to define
   %define foo	bing
    %define %{foo} bang
to have the result be
    %bing bang
then this construct accomplishes
%{expand:%%define %{foo} bang}

The 1st pass substitutes "bing" for %{foo}, the second pass
accomplishes the define.

When browsing through spec files, I have the impression that it is
unnecessarily used in a lot of cases.


Likely.

73 de Jeff

_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/rpm-list

[Index of Archives]     [RPM Ecosystem]     [Linux Kernel]     [Red Hat Install]     [PAM]     [Red Hat Watch]     [Red Hat Development]     [Red Hat]     [Gimp]     [Yosemite News]     [IETF Discussion]

  Powered by Linux