From owner-freebsd-ports Sat Nov 23 5:25:55 2002 Delivered-To: freebsd-ports@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0B16637B404 for ; Sat, 23 Nov 2002 05:25:54 -0800 (PST) Received: from topaz.mdcc.cx (topaz.mdcc.cx [212.204.230.141]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8006A43E4A for ; Sat, 23 Nov 2002 05:25:53 -0800 (PST) (envelope-from edwin@mavetju.org) Received: from k7.mavetju (topaz.mdcc.cx [212.204.230.141]) by topaz.mdcc.cx (Postfix) with ESMTP id 411FC2B67D; Sat, 23 Nov 2002 14:25:37 +0100 (CET) Received: by k7.mavetju (Postfix, from userid 1001) id 662FA6A712B; Sun, 24 Nov 2002 00:25:30 +1100 (EST) Date: Sun, 24 Nov 2002 00:25:30 +1100 From: Edwin Groothuis To: Roman Shterenzon Cc: ports@freebsd.org Subject: Re: sed-in-place vs perl-in-place Message-ID: <20021123132530.GK50581@k7.mavetju> References: <20021123151528.H79952-100000@alchemy.oven.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20021123151528.H79952-100000@alchemy.oven.org> User-Agent: Mutt/1.4i Sender: owner-freebsd-ports@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Sat, Nov 23, 2002 at 03:18:47PM +0200, Roman Shterenzon wrote: > I'm working on Monkey's Audio (lossless audio compression) port. > The source is for windows, thus it has \r (carriage return) all over it. > The simplest thing to do is ${PERL5} -pi -e 's/\r//g' , but since it's > deprecated, one should use sed. > I tried several ways of removing \r's with sed, but failed. > Could someone enlighten me ? From a previous post: ====================== Date: Tue, 5 Nov 2002 11:32:10 +1100 From: Edwin Groothuis To: ports@freebsd.org Subject: funny REINPLACE_CMD failure for \r Greetings, It seems that REINPLACE_CMD doesn't know how to handle \r's in the expression, "-e 's!\r!!'" fails all the time for me (no matter how much \'s I add to it :-). Right now I just replace these by "${TR} -d '\015' < file > file.new; {$MV} file.new file" but I was wondering if somebody has a better solution for it. ====================== Somebody suggested we should add a DOS2UNIX= processor in the bsd.ports.mk! Edwin -- Edwin Groothuis | Personal website: http://www.MavEtJu.org edwin@mavetju.org | Weblog: http://www.mavetju.org/weblog/weblog.php bash$ :(){ :|:&};: | Interested in MUDs? http://www.FatalDimensions.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message