Mailinglist Archive: opensuse-packaging (284 mails)

< Previous Next >
Re: [opensuse-packaging] How do I submit a new rpm macro for inclusion?
On 02/02/2011 09:43 PM, Tejas Guruswamy wrote:
On 02/02/11 15:43, Dave Plater wrote:

On 02/02/2011 02:57 PM, Ludwig Nussel wrote:


Dave Plater wrote:


Hi, I;ve been dealing with a lot of crippled sources and also build a
few svn and git packages from time to time. I copied the contents of the
%configure macro and substituted ./configure with ./autogen.sh. This
would be ideal as a %autogen macro don't you think?


What about
%define _configure ./autogen.sh
%configure

cu
Ludwig


That runs configure twice, autogen.sh already runs configure (99% of the
time) and accepts the arguments for configure and passes them to configure.
I would also put in a check for the 1% where autogen.sh is simply a
script that runs the ac and am tools without libtool. The generic
autogen.sh has a header whereas the 1% is a small script.
It was just an idea as I was updating yet another crippled package the
expanded %configure takes a lot of space and a %autogen macro would make
the spec file more readable.
I'll carry on with this after I've finished more important tasks.
Dave P


I think you misunderstand what Ludwig meant.

The macro %{configure} is defined as
%{_configure} (configure options blah blah)
and %{_configure} is defined as ./configure.

So if you redefine %{_configure} to ./autogen.sh, %{configure} expands
to exactly what you want - autogen.sh with the configure options.

Regards,
Tejas


Ok I was in a rush then but now I understand, the macro %_configure is
used by %configure, I didn't quite realise that I could redefine
%_configure and the %configure from macros would use it.
Thanks Ludwig.that's all I need to keep the spec file tidy. I realise
the importance of spec tidiness more and more. I will also put a comment
about what has been done.
And thanks Tejas for opening my eyes.
Dave P
--
To unsubscribe, e-mail: opensuse-packaging+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-packaging+help@xxxxxxxxxxxx

< Previous Next >