From patchwork Mon May 16 13:20:19 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tristan Gingold X-Patchwork-Id: 95751 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 48828B6EDF for ; Mon, 16 May 2011 23:20:44 +1000 (EST) Received: (qmail 5795 invoked by alias); 16 May 2011 13:20:39 -0000 Received: (qmail 5785 invoked by uid 22791); 16 May 2011 13:20:38 -0000 X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from mel.act-europe.fr (HELO mel.act-europe.fr) (194.98.77.210) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 16 May 2011 13:20:23 +0000 Received: from localhost (localhost [127.0.0.1]) by filtered-smtp.eu.adacore.com (Postfix) with ESMTP id 26C4ECB028D; Mon, 16 May 2011 15:20:22 +0200 (CEST) Received: from mel.act-europe.fr ([127.0.0.1]) by localhost (smtp.eu.adacore.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 6kPCKYxWzqMi; Mon, 16 May 2011 15:20:19 +0200 (CEST) Received: from ulanbator.act-europe.fr (ulanbator.act-europe.fr [10.10.1.67]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by mel.act-europe.fr (Postfix) with ESMTP id 2235FCB0245; Mon, 16 May 2011 15:20:19 +0200 (CEST) From: Tristan Gingold Subject: [Patch] fixincludes: fix solaris_complex_cxx rule syntax Date: Mon, 16 May 2011 15:20:19 +0200 Message-Id: To: "gcc-patches@gcc.gnu.org Patches" , bkorb@gnu.org Mime-Version: 1.0 (Apple Message framework v1084) X-IsSubscribed: yes 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 Hi, this rule (and only this one) uses the c function of sed. According to man, the syntax should be: [2addr]c\ text (Note the trailing back-slash). But as currently written, there is no backslash in it. As a consequence 'make check' fails at least on Darwin (BSD derived sed command). I think it would be better to stick with the common syntax, as done by this patch. Tested with 'make check'. Ok for trunk ? Tristan. fixincludes/ 2011-05-16 Tristan Gingold * inclhack.def (solaris_complex_cxx): Fix syntax. * fixincl.x: Regenerate. diff --git a/fixincludes/inclhack.def b/fixincludes/inclhack.def index ac8f795..a20ab9d 100644 --- a/fixincludes/inclhack.def +++ b/fixincludes/inclhack.def @@ -3315,9 +3315,9 @@ fix = { hackname = solaris_complex_cxx; mach = "*-*-solaris2.*"; files = complex.h; - sed = "/#if[ \t]*!defined(__cplusplus)/c" + sed = "/#if[ \t]*!defined(__cplusplus)/c\\\n" "#ifdef\t__cplusplus\\\nextern \"C\" {\\\n#endif"; - sed = "/#endif[ \t]*\\/\\* !defined(__cplusplus) \\*\\//c" + sed = "/#endif[ \t]*\\/\\* !defined(__cplusplus) \\*\\//c\\\n" "#ifdef\t__cplusplus\\\n}\\\n#endif"; test_text = "#if !defined(__cplusplus)\n" "#endif /* !defined(__cplusplus) */";