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 > Red Hat Linux

 
 
LinkBack Thread Tools
 
Old 08-01-2008, 04:26 AM
Joel Heenan
 
Default SPEC files: Include RHEL distribution in the release

I'm building an RPM on a number of different RHEL versions. Is there
something I can include in the RPM spec file which will auto-set the
distribution name and version?

I tried:

Release: 1%{distribution}

In the spec file but this did not seem to do the trick. I'm feeling what
I'm trying to achieve is simple but I haven't found any examples yet.
--
Joel Heenan
************************************************** ********************
This message is intended for the addressee named and may contain
privileged information or confidential information or both. If you
are not the intended recipient please delete it and notify the sender.
************************************************** ********************

--
redhat-list mailing list
unsubscribe mailto:redhat-list-request@redhat.com?subject=unsubscribe
https://www.redhat.com/mailman/listinfo/redhat-list
 
Old 08-01-2008, 07:02 AM
Juergen Zahrer
 
Default SPEC files: Include RHEL distribution in the release

Joel Heenan wrote:

I'm building an RPM on a number of different RHEL versions. Is there
something I can include in the RPM spec file which will auto-set the
distribution name and version?

I tried:

Release: 1%{distribution}

In the spec file but this did not seem to do the trick. I'm feeling what
I'm trying to achieve is simple but I haven't found any examples yet.


Hi,

create a .rpmmacros file in your home:

all in one line:
#############################
%distribution ) %(echo `cat /etc/redhat-release | grep -q '^CentOS
release 4' && echo 'el4'`)%(echo `cat /etc/redhat-release | grep -q
'^CentOS release 5' && echo 'el5'`)

#############################

you may add other systems as well

--
Mit freundlichen Grüssen,
Mag. Jürgen Zahrer

Leiter System Services
Universität Salzburg / ITServices

Hellbrunner Strasse 34
5020 Salzburg
Austria

Phone: ++43-(0)662-8044-6745
Cell: ++43-(0)664-2823790
Fax: ++43-(0)662-6389-6745
key ID 7B34AB4C


--
redhat-list mailing list
unsubscribe mailto:redhat-list-request@redhat.com?subject=unsubscribe
https://www.redhat.com/mailman/listinfo/redhat-list
 

Thread Tools




All times are GMT. The time now is 12:47 PM.

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