micha...@tnrglobal.com wrote:
> On Sep 16, 4:23 pm, "R.I.Pienaar" <r...@devco.net> wrote:
>> rpmbuild -ba -D 'dist .el5' -D 'rhel 5' -D '_without_augeas 1' puppet.spec
>
> Great- that works. I also just tried:
> rpmbuild  --without augeas --without selinux --rebuild
> puppet-2.6.1-0.5.el5.src.rpm

FWIW, the spec file has this at the very top:

# Augeas and SELinux requirements may be disabled at build time by passing
# --without augeas and/or --without selinux to rpmbuild or mock

For any non-ancient rpm, that should work as well as the -D syntax
above.  (RHEL4 rpm qualifies as ancient and isn't something I test
with very often.)

Also note that the rpmbuild command you used above, without the -D
'dist .el5' -D 'rhel 5' would lack requirements on ruby(abi) = 1.8 and
ruby-shadow and would not build noarch packages.  Both of those things
depending on those macros being set (as they are on the EPEL build
system).  In fact, lacking those macros will cause augeas and selinux
to not be required either, irregardless of setting --without augeas or
selinux.

If you rebuild a lot of packages from Fedora or EPEL on RHEL/CentOS
systems, you may want to use mock for building or install the
buildsys-macros package which provides these common macros:

    
http://buildsys.fedoraproject.org/buildgroups/rhel5/x86_64/buildsys-macros-5-5.el5.noarch.rpm

On all supported Fedora releases, these macros are defined as part of
the stock install.  I believe that's the case for RHEL6 too, but I
don't have access to any RHEL6 beta systems at the moment to verify
that.

-- 
Todd        OpenPGP -> KeyID: 0xBEAF0CE3 | URL: www.pobox.com/~tmz/pgp
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
There are no stupid questions, but there are a LOT of inquisitive
idiots.
    -- Demotivators (www.despair.com)

Attachment: pgpsMp4DXHNmT.pgp
Description: PGP signature

Reply via email to