[Mageia-dev] Another problem with new rpm

Pascal Terjan pterjan at gmail.com
Wed Dec 26 19:50:52 CET 2012


On Wed, Dec 26, 2012 at 6:47 PM, Pascal Terjan <pterjan at gmail.com> wrote:
> On Wed, Dec 26, 2012 at 5:46 PM, Jani Välimaa <jani.valimaa at gmail.com> wrote:
>> On Wed, 26 Dec 2012 14:13:44 +0000
>> Pascal Terjan <pterjan at gmail.com> wrote:
>>
>>> It seems you can no longer use a variable not coming from a tag as a
>>> parameter of %setup
>>>
>>> The following spec leads to error: line 88: Bad %setup option -n:
>>> missing argument
>>>
>>> %define pre     rc5
>>> %define rel     5
>>>
>>> %if %pre
>>> %define release         %mkrel 0.%{pre}.%{rel}
>>> %define distname        %{name}-%{version}-%{pre}.tar.bz2
>>> %define dirname         %{name}-%{version}~%{pre}
>>> %else
>>> %define release         %mkrel %{rel}
>>> %define distname        %{name}-%{version}.tar.bz2
>>> %define dirname         %{name}-%{version}
>>> %endif
>>>
>>> [...]
>>>
>>> %setup -q -n %{dirname}
>>>
>>> So far 8 packages are affected
>>
>> Similar approach works at least for openttd.
>>
>> However macro isn't called %dirname in openttd.spec. What if you
>> rename %dirname to something else?
>
> Ah that would make sense :-)

It works, thanks


More information about the Mageia-dev mailing list