From patchwork Thu Nov 20 07:31:32 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mike Frysinger X-Patchwork-Id: 3808 Received: (qmail 4889 invoked by alias); 20 Nov 2014 06:32:25 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 4872 invoked by uid 89); 20 Nov 2014 06:32:24 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.1 required=5.0 tests=AWL, BAYES_00, SPF_PASS, T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-HELO: smtp.gentoo.org From: Mike Frysinger To: libc-alpha@sourceware.org Cc: roland@hack.frob.com Subject: [PATCH] arm: do not abort EABI check for bootstrapping Date: Thu, 20 Nov 2014 02:31:32 -0500 Message-Id: <1416468692-4317-1-git-send-email-vapier@gentoo.org> The change to simplify the EABI/OABI check from a tuple to a compile test broke the ability to bootstrap a cross-compiler when generating the glibc headers. At that point, there is no compiler yet, so this compile-time test will always fail. Wrap the error with a basic sanity check so that if the compiler fails, we assume this setup. Signed-off-by: Mike Frysinger --- Note: an alternative might be to just delete the EABI check altogether. It's not like an OABI compiler will be able to properly build glibc ... sysdeps/arm/preconfigure | 4 ++++ sysdeps/arm/preconfigure.ac | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/sysdeps/arm/preconfigure b/sysdeps/arm/preconfigure index 59d776d..6a4c84e 100644 --- a/sysdeps/arm/preconfigure +++ b/sysdeps/arm/preconfigure @@ -7,9 +7,13 @@ arm*) cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +/* Do not abort when bootstrapping initial glibc headers -- determine that with + a basic sanity check. */ +#ifdef __arm__ #if !__ARM_EABI__ #error #endif +#endif int main () { diff --git a/sysdeps/arm/preconfigure.ac b/sysdeps/arm/preconfigure.ac index d78817b..157e822 100644 --- a/sysdeps/arm/preconfigure.ac +++ b/sysdeps/arm/preconfigure.ac @@ -4,8 +4,12 @@ GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory. case "$machine" in arm*) AC_TRY_COMPILE([ +/* Do not abort when bootstrapping initial glibc headers -- determine that with + a basic sanity check. */ +#ifdef __arm__ #if !__ARM_EABI__ #error +#endif #endif], [], [], [AC_MSG_ERROR([Old ABI no longer supported])]) # If the compiler enables unwind tables by default, this causes