This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, rs6000] ELFv2 ABI 1/8: Add options and infrastructure
- From: Jakub Jelinek <jakub at redhat dot com>
- To: Ulrich Weigand <uweigand at de dot ibm dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Tue, 12 Nov 2013 00:17:48 +0100
- Subject: Re: [PATCH, rs6000] ELFv2 ABI 1/8: Add options and infrastructure
- Authentication-results: sourceware.org; auth=none
- References: <201311111440 dot rABEem5T003872 at d06av02 dot portsmouth dot uk dot ibm dot com>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Mon, Nov 11, 2013 at 03:40:48PM +0100, Ulrich Weigand wrote:
> @@ -355,7 +364,11 @@ extern int dot_symbols;
> #define LINK_OS_DEFAULT_SPEC "%(link_os_linux)"
>
> #define GLIBC_DYNAMIC_LINKER32 "/lib/ld.so.1"
> -#define GLIBC_DYNAMIC_LINKER64 "/lib64/ld64.so.1"
> +#ifdef LINUX64_DEFAULT_ABI_ELFv2
> +#define GLIBC_DYNAMIC_LINKER64 "%{mabi=elfv1:/lib64/ld64.so.1;:/lib64/ld64.so.2}"
> +#else
> +#define GLIBC_DYNAMIC_LINKER64 "%{mabi=elfv2:/lib64/ld64.so.2;:/lib64/ld64.so.1}"
> +#endif
I agree with Joseph that it would be nice to keep the number of supported
ABIs down, if it could be old powerpc64-linux big-endian ELFv1 and powerpc64le-linux
ELFv2 only, that would be ideal. Can little-endian and big-endian binaries
coexist on the same kernel, or will there be big endian only kernels vs.
little endian only kernels? If they can coexist, perhaps it would be better
to use different libQUAL suffix from lib64 (lib64be?), if they can't, using lib64
is fine. If they can coexist, then there is certainly an issue with various
shared binary files that typically some way handle different word size these
days, but not endianity (utmp/wtmp, ld.so.cache, locale-archive, various
other files).
Jakub