From owner-freebsd-questions@FreeBSD.ORG Thu May 20 13:03:35 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A8E1516A4CE for ; Thu, 20 May 2004 13:03:35 -0700 (PDT) Received: from rwcrmhc12.comcast.net (rwcrmhc12.comcast.net [216.148.227.85]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7073F43D1D for ; Thu, 20 May 2004 13:03:35 -0700 (PDT) (envelope-from freebsd-questions-local@be-well.ilk.org) Received: from be-well.no-ip.com ([66.30.196.44]) by comcast.net (rwcrmhc12) with ESMTP id <2004052020033201400jbffce>; Thu, 20 May 2004 20:03:32 +0000 Received: by be-well.no-ip.com (Postfix, from userid 1147) id E779555; Thu, 20 May 2004 16:03:31 -0400 (EDT) Sender: lowell@be-well.ilk.org To: freebsd-questions@freebsd.org References: <200405201900.i4KJ0h5P046853@whoweb.com> From: Lowell Gilbert Date: 20 May 2004 16:03:31 -0400 In-Reply-To: <200405201900.i4KJ0h5P046853@whoweb.com> Message-ID: <44vfiqvpbg.fsf@be-well.ilk.org> Lines: 29 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Subject: Re: c compiler X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 May 2004 20:03:35 -0000 Jon writes: > I'm looking for some quick help with the 5.2.1 C compiler. In FBSD 4.x > I could write multi-line printf() statements with embedded new-lines > such as: > > printf(" > hello, > this > is > a > test"); > > > In 5.2.1, the newlines have to be preceeded with a "\" character. Since > I have some large programs with lots of printf() statements that include > embedded new-lines, I'm not looking forward to going through thousands > of lines of code to add "\" characters. Is there any command line > option > option to "cc" (didn't find one in the manpage) or other way to compile > my old code the way it is? I don't think so. It is (and, I believe, always was) illegal according to the C standard, and it had been been deprecated in gcc for several years (with appropriate warnings in the 3.x GCC releases). You'll need to convert your code to be valid C or take it up with the GCC developers. Time for an awk script, I think.