Buchan Milne <[EMAIL PROTECTED]> writes:

> > it should be written:
> > %define build_foo 0
> > %{?_with_foo: %{expand: %%global build_foo 1}}
> >                        ^^^^^^^^
> 
> Dump the %expand, it's not necessary:
> %{?_with_foo: %global build_foo 1}

FYI, I used the following to make it work in adiusbadsl :

%{expand:%%define build_modules %(if [[ `/bin/uname -r|sed 's/-.*$//'` < 2.4.21 ]]; 
then echo 1; else echo 0; fi)}
#- how to use the following: rpm --without modules -ba SPECS/...
%{?_with_modules: %{expand: %%define build_modules 1}}
%{?_without_modules: %{expand: %%define build_modules 0}}

But I'am not expert, this could be simplfied using %global ?

François.

Reply via email to