From patchwork Tue Dec 7 14:44:45 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joseph Myers X-Patchwork-Id: 74554 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 9D189B70A3 for ; Wed, 8 Dec 2010 01:44:57 +1100 (EST) Received: (qmail 30083 invoked by alias); 7 Dec 2010 14:44:54 -0000 Received: (qmail 30064 invoked by uid 22791); 7 Dec 2010 14:44:53 -0000 X-SWARE-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL, BAYES_00, TW_XG, T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mail.codesourcery.com (HELO mail.codesourcery.com) (38.113.113.100) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 07 Dec 2010 14:44:48 +0000 Received: (qmail 25826 invoked from network); 7 Dec 2010 14:44:46 -0000 Received: from unknown (HELO digraph.polyomino.org.uk) (joseph@127.0.0.2) by mail.codesourcery.com with ESMTPA; 7 Dec 2010 14:44:46 -0000 Received: from jsm28 (helo=localhost) by digraph.polyomino.org.uk with local-esmtp (Exim 4.72) (envelope-from ) id 1PPymb-0003Zw-D8; Tue, 07 Dec 2010 14:44:45 +0000 Date: Tue, 7 Dec 2010 14:44:45 +0000 (UTC) From: "Joseph S. Myers" To: gcc-patches@gcc.gnu.org cc: hp@axis.com Subject: svr4.h avoidance: cris Message-ID: MIME-Version: 1.0 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org This patch in the series removing svr4.h from the headers used by particular targets in GCC stops cris*-*-linux* from using svr4.h, defining the two macros used from that header in cris/linux.h instead. Tested building cc1 and xgcc for a cross to cris-linux-gnu. OK to commit? 2010-12-07 Joseph Myers * config/cris/linux.h (SIZE_TYPE, PTRDIFF_TYPE): Define. * config.gcc (crisv32-*-linux* | cris-*-linux*): Don't use svr4.h. diff -rupN --exclude=.svn gcc-mainline-3/gcc/config/cris/linux.h gcc-mainline/gcc/config/cris/linux.h --- gcc-mainline-3/gcc/config/cris/linux.h 2010-12-02 09:39:19.000000000 -0800 +++ gcc-mainline/gcc/config/cris/linux.h 2010-12-07 06:36:17.000000000 -0800 @@ -132,7 +132,14 @@ along with GCC; see the file COPYING3. builtin_define ("__NO_UNDERSCORES__"); \ } \ while (0) + +/* Node: Type Layout */ +#undef SIZE_TYPE +#define SIZE_TYPE "unsigned int" + +#undef PTRDIFF_TYPE +#define PTRDIFF_TYPE "int" /* Node: Sections */ diff -rupN --exclude=.svn gcc-mainline-3/gcc/config.gcc gcc-mainline/gcc/config.gcc --- gcc-mainline-3/gcc/config.gcc 2010-12-06 03:31:49.000000000 -0800 +++ gcc-mainline/gcc/config.gcc 2010-12-07 06:33:08.000000000 -0800 @@ -942,7 +942,7 @@ cris-*-elf | cris-*-none) use_gcc_stdint=wrap ;; crisv32-*-linux* | cris-*-linux*) - tm_file="dbxelf.h elfos.h svr4.h ${tm_file} linux.h glibc-stdint.h cris/linux.h" + tm_file="dbxelf.h elfos.h ${tm_file} linux.h glibc-stdint.h cris/linux.h" # We need to avoid using t-linux, so override default tmake_file tmake_file="cris/t-cris t-slibgcc-elf-ver cris/t-linux" extra_options="${extra_options} cris/linux.opt"