This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [Patch] Fix MIPS build failure caused by -Werror=undef
- From: "Maciej W. Rozycki" <macro at linux-mips dot org>
- To: Steve Ellcey <sellcey at imgtec dot com>
- Cc: libc-alpha at sourceware dot org
- Date: Sat, 14 Feb 2015 14:33:50 +0000 (GMT)
- Subject: Re: [Patch] Fix MIPS build failure caused by -Werror=undef
- Authentication-results: sourceware.org; auth=none
- References: <04dee4c5-a06d-447e-8174-ab39f52a4b48 at BAMAIL02 dot ba dot imgtec dot org>
On Fri, 13 Feb 2015, Steve Ellcey wrote:
> The recent change to use -Werror=undef on assembly language files
> caused a build failure on MIPS. GCC defines __MIPSEB only in
> big-endian mode and leaves it undefined in little endian mode (where
> it defines __MIPSEL instead).
[...]
> 2015-02-13 Steve Ellcey <sellcey@imgtec.com>
>
> * sysdeps/mips/bits/endian.h (__MIPSEB): Use #ifdef instead of #if.
> * sysdeps/mips/memcpy.S (__MIPSEB): Ditto.
> * sysdeps/mips/memset.S (__MIPSEB): Ditto.
>
>
> diff --git a/sysdeps/mips/bits/endian.h b/sysdeps/mips/bits/endian.h
> index 9586104..43ce009 100644
> --- a/sysdeps/mips/bits/endian.h
> +++ b/sysdeps/mips/bits/endian.h
> @@ -5,7 +5,7 @@
> # error "Never use <bits/endian.h> directly; include <endian.h> instead."
> #endif
>
> -#if __MIPSEB
> +#ifdef __MIPSEB
> # define __BYTE_ORDER __BIG_ENDIAN
> #endif
> #if __MIPSEL
^^^^^^^^^^^^
Don't we need a complementing change for __MIPSEL here then too?
Maciej