This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] Disable building with i386-*, -march=i386 or -mcpu=i386.
- From: Roland McGrath <roland at hack dot frob dot com>
- To: "Carlos O'Donell" <carlos at redhat dot com>
- Cc: Allan McRae <allan at archlinux dot org>, "Joseph S. Myers" <joseph at codesourcery dot com>, GNU C Library <libc-alpha at sourceware dot org>, Andreas Jaeger <aj at suse dot com>, Thomas Schwinge <thomas at codesourcery dot com>
- Date: Tue, 16 Apr 2013 13:47:33 -0700 (PDT)
- Subject: Re: [PATCH] Disable building with i386-*, -march=i386 or -mcpu=i386.
- References: <513FE49D dot 3050406 at redhat dot com> <Pine dot LNX dot 4 dot 64 dot 1303131610540 dot 19781 at digraph dot polyomino dot org dot uk> <51526E77 dot 4040801 at redhat dot com> <Pine dot LNX dot 4 dot 64 dot 1303271431550 dot 23096 at digraph dot polyomino dot org dot uk> <5154668A dot 6000700 at redhat dot com> <5160465E dot 8060400 at redhat dot com> <20130408210918 dot D97632C074 at topped-with-meat dot com> <51634DE2 dot 1060109 at redhat dot com> <20130408231128 dot DA09C2C0A2 at topped-with-meat dot com> <5163516D dot 1060705 at archlinux dot org> <516805F1 dot 2090504 at redhat dot com> <516D9093 dot 1070705 at redhat dot com>
> * sysdeps/i386/preconfigure.in: New file.
> * sysdeps/i386/preconfigure: Regenerate.
"New generated file." (You can't regenerate what's never been generated.)
But you don't need a preconfigure if it's just going to be an error. The
only time you need a preconfigure is when it's going to do something that
actually influences sysdeps selection.
> diff --git a/sysdeps/i386/configure.in b/sysdeps/i386/configure.in
> index 56a7c1f..ee55efd 100644
> --- a/sysdeps/i386/configure.in
> +++ b/sysdeps/i386/configure.in
> @@ -18,7 +18,8 @@ LIBC_COMPILER_BUILTIN_INLINED(
> [libc_cv_unsupported_i386=no],
> [AC_MSG_ERROR([
> *** Building with -march=i386/-mcpu=i386 is not supported.
> -*** Please use host i786, i686, i586, or i486.])])
> +*** Please use host i786, i686, i586, or i486.
> +*** For example: export CFLAGS="-O2 -march=i386"])])
Never suggest setting variables in the environment!
(Also, you're suggesting exactly what's prohibited.)
Better would be:
*** For example, pass CFLAGS='-O2 -march=i686' to configure.
> +# Configure for i686 if the user asks for i386. We don't support
> +# i386 any more but it continues to be common for users to configure
> +# 32-bit x86 as i386. We build for i686 instead.
The comment no longer matches the code.