[PLUG] rpm spec file macro expansion

Galen Seitz galens at seitzassoc.com
Mon Oct 3 06:48:58 UTC 2005


I'm trying to build some cross tools for the AVR microcontrollers, and I
need to work around an issue with file collisions.  When I build
cross versions of binutils, gcc, and gdb, the info files that get created
have the same name and path as the corresponding files for the native
host tools.  In order to eliminate the conflict, I'd like to do something
like the following in my spec file:

%define _infodir %{_infodir}/avr

Due to the way macros are evaluated, this results in infinite recursion.
What is the correct way to accomplish this?  

I'm bit surprised that this issue with cross tool info file collisions
hasn't been addressed.  The actual executables aren't a problem.  They
are installed in two different places, neither of which causes a
conflict.  For instance, gcc gets installed as /usr/bin/avr-gcc and
/usr/avr/bin/gcc.  The man pages are also installed in a way that avoids
conflicts.  Only the info files seem to be a problem.

thanks,
galen



More information about the PLUG mailing list