[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
RE: Binary RPM naming | doubt
- From: "Lis Maria Thomas" <lthomas2 sapient com>
- To: "RPM Package Manager" <rpm-list redhat com>
- Subject: RE: Binary RPM naming | doubt
- Date: Thu, 26 Oct 2006 17:00:03 +0530
Hi
I have tried using the SPEC files conditional statements.
My spec file contains
%define my_build_name_fmt xxx
%define _build_name_fmt my_build_name_fmt.%_arch.rpm
And I am building the rpm as
rpmbuild -ba yyy.spec --define "_build_name_fmt
$my_build_name_fmt.%_arch.rpm"
The output I am getting is
Wrote: /home/sapient/redhat/RPMS/my_build_name_fmt.i386.rpm
Wrote: /home/sapient/redhat/RPMS/my_build_name_fmt.i386.rpm
Please help...
-----Original Message-----
From: rpm-list-bounces redhat com [mailto:rpm-list-bounces redhat com]
On Behalf Of Luciano Miguel Ferreira Rocha
Sent: Thursday, October 26, 2006 3:56 PM
To: rpm-list redhat com
Subject: Re: Binary RPM naming | doubt
On Thu, Oct 26, 2006 at 03:20:31PM +0530, Lis Maria Thomas wrote:
> Hi
>
> There is a variable defind at my %prep section as
>
> new_variable_new=aaa
>
> And while doing the rpm build, I am givin the following command
>
> rpmbuild -ba yyy.spec --define "_build_name_fmt
> $new_variable_new.%_arch.rpm"
>
>
> The binary rpm it is creating is not takin the value specified, rather
> it is giving the output as :
>
> Wrote: /home/sssss/redhat/RPMS/.i386.rpm
> Wrote: /home/sssss/redhat/RPMS/.i386.rpm
It is taking the value you specified. At the moment you called rpmbuild,
$new_variable_new didn't exist, did it?
The %prep, %build, %install, and others are scripts that rpmbuild
creates, and executes as outside programs. They can't influence rpmbuild
environment.
> Can u help me out with what could be the possible mistake I have
> made...
You'll have to use spec's conditional statements to set _build_name_fmt.
And you can set _build_name_fmt to the output of a script too, with
something like:
%define _build_name_fmt %(echo pkg)
--
lfr
0/0
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]