[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [patches] eglibc & powerpc-linuxspe-gcc (problem configuring/compiling eglibc svn trunk for mpc8540)



Joseph S. Myers wrote:

> EGLIBC should move towards less and less dependence on the nominal target 
> triplet name.  This includes, for example, allowing 32-bit hard-float, 
> 64-bit hard-float, 32-bit soft-float and 32-bit E500 all to be built with 
> a configuration as powerpc-linux-gnu, with the compiler properties tested 
> automatically to determine what multilib is in use and glibc configured 
> accordingly.

I fully agree.  It's an unfortunate limitation that a lot of the GNU
toolchain depends on the target name, not just on Power, but on other
architectures.  Most compilers can target multiple operating systems,
and even multiple architectures, from a single binary, whereas for GCC
we often have to have multiple versions.

> particular, installed headers need to be suitable for all multilibs
for an
> architecture (and therefore contain appropriate conditionals) so that one
> set of installed headers can be used with a compiler supporting several
> multilibs (e.g. the four listed above).

Yes, I think that's the right decision too.  (AFAIK, the Linux kernel
has a similar strategy; there are common headers, and then <asm/$cpu>
directories for CPU-specific stuff, so that you can probably build (say)
Power and Intel binaries using the same kernel headers.)

Of course, it would be theoretically possible for (E)GLIBC to be
configured with a different triplet from GCC (so, power-linux-gnu, for
GCC, and then multilibs for E(GBLIC) configured with power-linux-gnu,
powerspe-linux-gnu, power74xx-linux-gnu, or whatever) -- but that would
be difficult o manage.  Configuring all the multilibs with a
power-linux-gnu target and then using --with-cpu=<something> seems better.

-- 
Mark Mitchell
CodeSourcery
mark@xxxxxxxxxxxxxxxx
(650) 331-3385 x713