FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > RPM Package Manager

 
 
LinkBack Thread Tools
 
Old 01-16-2008, 03:08 PM
 
Default %clean section not processed

Hi,


I’m using rpm 4.4.7
which I have built on HPUX 11.23 / ia64. I have written a spec file with a specific
%clean section. However, it seems that this one is not processed, but replaced
by a default one which simply removes the buildroot directory. Is there
something new to set or configure with this version, in order to use its own
%clean section ?


Regards,


mailto: patrice.elasri@sofrecom.com

phone: +33 1
43985883


*







_______________________________________________
Rpm-list mailing list
Rpm-list@redhat.com
https://www.redhat.com/mailman/listinfo/rpm-list
 
Old 01-16-2008, 07:00 PM
Michael Jennings
 
Default %clean section not processed

On Wednesday, 16 January 2008, at 17:08:23 (+0100),
patrice.elasri@sofrecom.com wrote:

> I'm using rpm 4.4.7 which I have built on HPUX 11.23 / ia64. I have
> written a spec file with a specific %clean section. However, it
> seems that this one is not processed, but replaced by a default one
> which simply removes the buildroot directory. Is there something new
> to set or configure with this version, in order to use its own
> %clean section ?

The %clean section is deprecated because it was almost always
identical to the new built-in version, or it was incorrect/missing.
If your package requires something in %clean that isn't covered in the
default, you've probably made a packaging error.

If you pastebin the spec file, I'm sure folks would be willing to take
a gander at it for you and give you some feedback.

Michael

PS: You probably want to move this to rpm-users@rpm5.org for all
versions of RPM > 4.4.2

--
Michael Jennings (a.k.a. KainX) http://www.kainx.org/ <mej@kainx.org>
Linux Server/Cluster Admin, LBL.gov Author, Eterm (www.eterm.org)
-----------------------------------------------------------------------
"I have failed over and over again in my life. And that is why I
succeed." -- Michael Jordan

_______________________________________________
Rpm-list mailing list
Rpm-list@redhat.com
https://www.redhat.com/mailman/listinfo/rpm-list
 
Old 01-17-2008, 05:50 AM
"manjunath k"
 
Default %clean section not processed

Hi,

Instead of the command " rm -rf %{buildroot} " in the
%clean section use something like "rm -rf src" where the
folder src is the one which you want to clean.

Regards,
Manjunath

On 1/16/08, patrice.elasri@sofrecom.com <patrice.elasri@sofrecom.com> wrote:
>
>
>
>
> Hi,
>
> I'm using rpm 4.4.7 which I have built on HPUX 11.23 / ia64. I have written
> a spec file with a specific %clean section. However, it seems that this one
> is not processed, but replaced by a default one which simply removes the
> buildroot directory. Is there something new to set or configure with this
> version, in order to use its own %clean section ?
>
> Regards,
>
> mailto: patrice.elasri@sofrecom.com
> phone: +33 1 43985883
>
>
> _______________________________________________
> Rpm-list mailing list
> Rpm-list@redhat.com
> https://www.redhat.com/mailman/listinfo/rpm-list
>

_______________________________________________
Rpm-list mailing list
Rpm-list@redhat.com
https://www.redhat.com/mailman/listinfo/rpm-list
 
Old 01-17-2008, 06:41 AM
Jos Vos
 
Default %clean section not processed

On Thu, Jan 17, 2008 at 12:20:32PM +0530, manjunath k wrote:

> Instead of the command " rm -rf %{buildroot} " in the
> %clean section use something like "rm -rf src" where the
> folder src is the one which you want to clean.

It looks like you didn't parse the original question very well.

--
-- Jos Vos <jos@xos.nl>
-- X/OS Experts in Open Systems BV | Phone: +31 20 6938364
-- Amsterdam, The Netherlands | Fax: +31 20 6948204

_______________________________________________
Rpm-list mailing list
Rpm-list@redhat.com
https://www.redhat.com/mailman/listinfo/rpm-list
 
Old 01-17-2008, 08:47 AM
 
Default %clean section not processed

In fact, I'm using the %{buildroot}.tmp as a temporary working directory to store especially my own find_requires script (including "%{__cat} >/dev/null") and a env.sh shell script, used to pass some environment variables between the building scriptlets. So my %clean section removes both %{buildroot} and %{buildroot}.tmp directories.
Is there really no way at all to enable the %clean section ?

-----Message d'origine-----
De*: rpm-list-bounces@redhat.com [mailto:rpm-list-bounces@redhat.com] De la part de Michael Jennings
Envoy*: mercredi 16 janvier 2008 21:01
*: rpm-list@redhat.com
Objet*: Re: %clean section not processed

On Wednesday, 16 January 2008, at 17:08:23 (+0100),
patrice.elasri@sofrecom.com wrote:

> I'm using rpm 4.4.7 which I have built on HPUX 11.23 / ia64. I have
> written a spec file with a specific %clean section. However, it
> seems that this one is not processed, but replaced by a default one
> which simply removes the buildroot directory. Is there something new
> to set or configure with this version, in order to use its own
> %clean section ?

The %clean section is deprecated because it was almost always
identical to the new built-in version, or it was incorrect/missing.
If your package requires something in %clean that isn't covered in the
default, you've probably made a packaging error.

If you pastebin the spec file, I'm sure folks would be willing to take
a gander at it for you and give you some feedback.

Michael

PS: You probably want to move this to rpm-users@rpm5.org for all
versions of RPM > 4.4.2

--
Michael Jennings (a.k.a. KainX) http://www.kainx.org/ <mej@kainx.org>
Linux Server/Cluster Admin, LBL.gov Author, Eterm (www.eterm.org)
-----------------------------------------------------------------------
"I have failed over and over again in my life. And that is why I
succeed." -- Michael Jordan

_______________________________________________
Rpm-list mailing list
Rpm-list@redhat.com
https://www.redhat.com/mailman/listinfo/rpm-list

_______________________________________________
Rpm-list mailing list
Rpm-list@redhat.com
https://www.redhat.com/mailman/listinfo/rpm-list
 
Old 01-17-2008, 11:40 AM
Jos Vos
 
Default %clean section not processed

On Thu, Jan 17, 2008 at 10:47:56AM +0100, patrice.elasri@sofrecom.com wrote:

> In fact, I'm using the %{buildroot}.tmp as a temporary working directory
> to store especially my own find_requires script (including "%{__cat}
> >/dev/null") and a env.sh shell script, used to pass some environment
> variables between the building scriptlets. So my %clean section removes
> both %{buildroot} and %{buildroot}.tmp directories.

In your case you can just do "rm -rf %{buildroot}.tmp" at the end of
%install, isn't it?

--
-- Jos Vos <jos@xos.nl>
-- X/OS Experts in Open Systems BV | Phone: +31 20 6938364
-- Amsterdam, The Netherlands | Fax: +31 20 6948204

_______________________________________________
Rpm-list mailing list
Rpm-list@redhat.com
https://www.redhat.com/mailman/listinfo/rpm-list
 
Old 01-17-2008, 01:30 PM
 
Default %clean section not processed

And what about the find_requires script used by the __find_requires macro ?

-----Message d'origine-----
De*: rpm-list-bounces@redhat.com [mailto:rpm-list-bounces@redhat.com] De la part de Jos Vos
Envoy*: jeudi 17 janvier 2008 13:40
*: RPM Package Manager
Objet*: Re: RE : %clean section not processed

On Thu, Jan 17, 2008 at 10:47:56AM +0100, patrice.elasri@sofrecom.com wrote:

> In fact, I'm using the %{buildroot}.tmp as a temporary working directory
> to store especially my own find_requires script (including "%{__cat}
> >/dev/null") and a env.sh shell script, used to pass some environment
> variables between the building scriptlets. So my %clean section removes
> both %{buildroot} and %{buildroot}.tmp directories.

In your case you can just do "rm -rf %{buildroot}.tmp" at the end of
%install, isn't it?

--
-- Jos Vos <jos@xos.nl>
-- X/OS Experts in Open Systems BV | Phone: +31 20 6938364
-- Amsterdam, The Netherlands | Fax: +31 20 6948204

_______________________________________________
Rpm-list mailing list
Rpm-list@redhat.com
https://www.redhat.com/mailman/listinfo/rpm-list

_______________________________________________
Rpm-list mailing list
Rpm-list@redhat.com
https://www.redhat.com/mailman/listinfo/rpm-list
 
Old 01-17-2008, 01:38 PM
Jos Vos
 
Default %clean section not processed

On Thu, Jan 17, 2008 at 03:30:53PM +0100, patrice.elasri@sofrecom.com wrote:

> And what about the find_requires script used by the __find_requires macro ?

Good point, but you can also store that in your build tree (or directly
refer to %{SOURCEx} if it's a static script provided by you).

--
-- Jos Vos <jos@xos.nl>
-- X/OS Experts in Open Systems BV | Phone: +31 20 6938364
-- Amsterdam, The Netherlands | Fax: +31 20 6948204

_______________________________________________
Rpm-list mailing list
Rpm-list@redhat.com
https://www.redhat.com/mailman/listinfo/rpm-list
 
Old 01-17-2008, 02:15 PM
"Jeff Johnson"
 
Default %clean section not processed

On Jan 17, 2008 4:47 AM, <patrice.elasri@sofrecom.com> wrote:

In fact, I'm using the %{buildroot}.tmp as a temporary working directory to store especially my own find_requires script (including "%{__cat} >/dev/null") and a env.sh shell script, used to pass some environment variables between the building scriptlets. So my %clean section removes both %{buildroot} and %{buildroot}.tmp directories.

Is there really no way at all to enable the %clean section ?
The %clean section has been refactor'd to be part of build configuration rather
than package recipe.Override this macro in your specfile if you want to change what %clean doesin rpm-4.4.7 and later (the default value, simplified, is included):
** *%define __spec_clean_body * rm -rf %{buildroot};There are likelier better ways than %{buildroot}.tmp to carry customdependency filters, but I'll leave the packaging style choices to you.
73 de Jeff
_______________________________________________
Rpm-list mailing list
Rpm-list@redhat.com
https://www.redhat.com/mailman/listinfo/rpm-list
 
Old 01-17-2008, 05:10 PM
 
Default %clean section not processed

In fact, it seems that
the %__spec_clean_post needs to be set instead of
*%__spec_clean_body.


*


-----Message d'origine-----

De*: rpm-list-bounces@redhat.com
[mailto:rpm-list-bounces@redhat.com] De la
part de Jeff Johnson

Envoy*: jeudi 17 janvier
2008 16:16

*: RPM Package Manager

Objet*: Re: RE : %clean
section not processed


*


*




On Jan 17, 2008 4:47 AM,
<patrice.elasri@sofrecom.com>
wrote:


In fact, I'm using the
%{buildroot}.tmp as a temporary working directory to store especially my own
find_requires script (including "%{__cat} >/dev/null") and a
env.sh shell script, used to pass some environment variables between the
building scriptlets. So my %clean section removes both %{buildroot} and
%{buildroot}.tmp directories.

Is there really no way at all to enable the %clean section ?




*






The %clean section has
been refactor'd to be part of build configuration rather






than package recipe.






*






Override this macro in
your specfile if you want to change what %clean does






in rpm-4.4.7 and later
(the default value, simplified, is included):






**
*%define __spec_clean_body * rm -rf %{buildroot};






*






There are likelier better
ways than %{buildroot}.tmp to carry custom






dependency filters, but
I'll leave the packaging style choices to you.






*






73 de Jeff











_______________________________________________
Rpm-list mailing list
Rpm-list@redhat.com
https://www.redhat.com/mailman/listinfo/rpm-list
 

Thread Tools




All times are GMT. The time now is 04:00 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org