RPM Community Forums

Mailing List Message of <rpm-devel>

Re: MACROSFILE extension in configure

From: Jason Corley <jason.corley@gmail.com>
Date: Wed 06 Jun 2007 - 03:28:59 CEST
Message-ID: <3118d8de0706051828i3beca906v5f8b270bb62c2ff3@mail.gmail.com>
I'm a fan of /etc/rpm/macros.d conceptually, and creating a
standardized location for vendor macros seems sane to me.
Jason

On 6/5/07, Mark Hatle <mark.hatle@windriver.com> wrote:
> I like this idea.  It would solve some issues I've had in the past.. (or
> at least make the solution easier to deal with.)
>
> --Mark
>
> Olivier Thauvin wrote:
> > In order to kill definitivelly rpmrc in mandriva rpm, I had to patch to have
> > our macros file load.
> >
> > There are two part:
> >
> > 1) extension to vendor macros files, aka:
> > ${USRLIBRPM}/%{_host_vendor}/macros and
> > ${USRLIBRPM}/%{_host_vendor}/%{_target}/macros
> >
> > This would standardize and encourage vendor to place their config
> > in /usr/lib/rpm under mandriva/, centos/, pld/, etc...
> >
> > 2) there is an issue by loading macros.*, macros.rpm{new,save} will get load,
> > so in mandriva I choose to encourage to use:
> > ${SYSCONFIGDIR}/macros.d/*.macros
> > (in addition, our config provide a macros to identify this path)
> >
> > OF course I'll commit only part having global agreement.
> >
> > WDYT ?
> >
> > Patch attached, as usuall
> >
> >
> > ------------------------------------------------------------------------
> >
> > Index: configure.ac
> > ===================================================================
> > RCS file: /v/rpm/cvs/rpm/configure.ac,v
> > retrieving revision 2.70.2.4
> > diff -u -b -B -w -p -r2.70.2.4 configure.ac
> > --- configure.ac      3 Jun 2007 22:00:08 -0000       2.70.2.4
> > +++ configure.ac      6 Jun 2007 00:56:49 -0000
> > @@ -1433,7 +1433,7 @@ AC_DEFINE_UNQUOTED(SYSCONFIGDIR, "$SYSCO
> >       [Full path to rpm system configuration directory (usually /etc/rpm)])
> >  AC_SUBST(SYSCONFIGDIR)
> >
> > -MACROFILES="${USRLIBRPM}/macros:${USRLIBRPM}/%{_target}/macros:${SYSCONFIGDIR}/macros.*:${SYSCONFIGDIR}/macros:${SYSCONFIGDIR}/%{_target}/macros:~/.rpmmacros"
> > +MACROFILES="${USRLIBRPM}/macros:${USRLIBRPM}/%{_target}/macros:${USRLIBRPM}/%{_host_vendor}/macros:${USRLIBRPM}/%{_host_vendor}/%{_target}/macros:${SYSCONFIGDIR}/macros.*:${SYSCONFIGDIR}/macros.d/*.macros:${SYSCONFIGDIR}/macros:${SYSCONFIGDIR}/%{_target}/macros:~/.rpmmacros"
> >  AC_DEFINE_UNQUOTED(MACROFILES, "$MACROFILES",
> >       [Colon separated paths of macro files to read.])
> >  AC_SUBST(MACROFILES)
>
> ______________________________________________________________________
> RPM Package Manager                                    http://rpm5.org
> Developer Communication List                        rpm-devel@rpm5.org
>
Received on Wed Jun 6 03:29:01 2007
Driven by Jeff Johnson and the RPM project team.
Hosted by OpenPKG and Ralf S. Engelschall.
Powered by FreeBSD and OpenPKG.