Discussion:
How to affix packager label to package
Drew Bertola
2008-03-02 04:53:44 UTC
Permalink
Hi,

I'd like to build a set of rpms for internal usage. I'd like the
resulting srpms and bin rpms to carry an identifier for our repo, since
a lot of the packages are going to be created from rebuilding those from
other repos, I don't want to have to edit all the spec files. Is this
possible?

I can give an example: I'd like to use php-5.2.4 on our centos servers,
so I grab the rpm from fedora and try rpmbuild --rebuild
php-5.2.4...fc8.srpm. During the rebuild, a macro is picked up
(somewhere in /etc/rpm/macro*, I'd guess) that appends ".abc" to the
release number.

I know how to do this by editing the spec file, but there must be a
convenient way to do this with one step, as in doing the --rebuild of an
existing srpm.

Any ideas?
--
Drew Bertola

-------------------------------------------------
* PHP/LAMP Consultant, ZCE-1000 *
* *
* Tel: 408-966-6671 *
* *
* current resume: *
* http://drewb.com/blog/about/resume/ *
-------------------------------------------------
Valery Reznic
2008-03-02 07:16:47 UTC
Permalink
Post by Drew Bertola
Hi,
I'd like to build a set of rpms for internal usage.
I'd like the
resulting srpms and bin rpms to carry an identifier
for our repo, since
a lot of the packages are going to be created from
rebuilding those from
other repos, I don't want to have to edit all the
spec files. Is this
possible?
I can give an example: I'd like to use php-5.2.4 on
our centos servers,
so I grab the rpm from fedora and try rpmbuild
--rebuild
php-5.2.4...fc8.srpm. During the rebuild, a macro
is picked up
(somewhere in /etc/rpm/macro*, I'd guess) that
appends ".abc" to the
release number.
For binary rpm you can use rpmrebuild
(http://rpmrebuild.sf.net) to change revision (or
anything else).

Valery.
Post by Drew Bertola
I know how to do this by editing the spec file, but
there must be a
convenient way to do this with one step, as in doing
the --rebuild of an
existing srpm.
Any ideas?
--
Drew Bertola
-------------------------------------------------
* PHP/LAMP Consultant, ZCE-1000 *
* *
* Tel: 408-966-6671 *
* *
* current resume: *
* http://drewb.com/blog/about/resume/ *
-------------------------------------------------
_______________________________________________
Rpm-list mailing list
https://www.redhat.com/mailman/listinfo/rpm-list
____________________________________________________________________________________
Looking for last minute shopping deals?
Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping
Matthew Miller
2008-03-02 12:59:24 UTC
Permalink
Post by Drew Bertola
I can give an example: I'd like to use php-5.2.4 on our centos servers,
so I grab the rpm from fedora and try rpmbuild --rebuild
php-5.2.4...fc8.srpm. During the rebuild, a macro is picked up
(somewhere in /etc/rpm/macro*, I'd guess) that appends ".abc" to the
release number.
Since you're building on Fedora, there happens to be a convention which will
help you. Almost all Fedora packages contain %{?dist} as part of their
release string, so, put something like

%dist %{?dist}.abc

in your ~/.rpmmacros file and there you go.
--
Matthew Miller ***@mattdm.org <http://mattdm.org/>
Boston University Linux ------> <http://linux.bu.edu/>
Loading...