Defining macro name as the value of another macro

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

 



Hello there

I'm trying to do the above but without success, so I could do something like this:

%if %centos
	foo
%else
%if %suse
	bar
%endif
%endif

I've tried using the value of '%_vendor' as the name of a macro with the value of '1', like this in '~/.rpmmacros' :

'%{expand:%_vendor} 1'

Or

'%define '%{expand:%_vendor} 1'

In a separate macro file.



Is it possible? If yes, what am I doing wrong?
I've tried in centos 6.5 (rpm 4.8.0) and suse 11.3 (4.4.2.3) .



TIA,
Fabricio
_______________________________________________
Rpm-list mailing list
Rpm-list@xxxxxxxxxxxxx
http://lists.rpm.org/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