[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
macro with args question
- From: James Olin Oden <joden lee k12 nc us>
- To: rpm-list redhat com
- Subject: macro with args question
- Date: Thu, 12 Aug 2004 10:32:01 -0400 (EDT)
Hi All,
I have the following macro defined in my build environment
%revert_script(n:) %{revert_script_dir}/%{?-n*}%{!-n:%{name}}-%{version}-%{release}.sh
The idea is in a package, say its (N,V,R) = (x,1,2), you can do:
%{revert_script}
and get back:
/some/path/x-1-2.sh
And if same SRPM has a sub package, say its called x-y, I can do:
%{revert_script -n x-y}
And get back:
/some/path/x-y-1-2.sh
This works. But then say I want to do:
%{revert_script -n %{name}-y}
I want to get back:
/some/path/x-y-1-2.sh
But instead I get back:
error: Unterminated {: {name
3< (empty)
2< (empty)
1< /var/TKLC/backout/revert.d/
0</var/TKLC/backout/revert.d/
error: line 156: /some/path/
I have tried:
%{revert_script -n %%{name}-y}
But then I get:
/some/path/%{name-1-2.sh-y}
I try to add expands in various places, and then it looks like the output
gets completely eaten.
How might I get this to work? Also, am I perhaps tripping over a bug?
Or are my expectations/thinking buggy (-;?
Cheers...james
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]