From owner-cvs-all@FreeBSD.ORG Tue Oct 11 02:49:41 2005 Return-Path: X-Original-To: cvs-all@FreeBSD.org Delivered-To: cvs-all@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6D20C16A420 for ; Tue, 11 Oct 2005 02:49:41 +0000 (GMT) (envelope-from adamw@FreeBSD.org) Received: from smtp102.rog.mail.re2.yahoo.com (smtp102.rog.mail.re2.yahoo.com [206.190.36.80]) by mx1.FreeBSD.org (Postfix) with SMTP id A695043D4C for ; Tue, 11 Oct 2005 02:49:39 +0000 (GMT) (envelope-from adamw@FreeBSD.org) Received: (qmail 46846 invoked from network); 11 Oct 2005 02:49:38 -0000 Received: from unknown (HELO ?192.168.1.140?) (tacopants@rogers.com@70.28.168.125 with plain) by smtp102.rog.mail.re2.yahoo.com with SMTP; 11 Oct 2005 02:49:38 -0000 Message-ID: <434B2841.3@FreeBSD.org> Date: Mon, 10 Oct 2005 22:49:37 -0400 From: Adam Weinberger User-Agent: Thunderbird 1.4.1 (Macintosh/20051005) MIME-Version: 1.0 To: Edwin Groothuis References: <200510101133.j9ABXWg4000289@repoman.freebsd.org> <20051010125906.GA3640@FreeBSD.org> <20051010234044.GB1239@k7.mavetju> In-Reply-To: <20051010234044.GB1239@k7.mavetju> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: cvs-ports@FreeBSD.org, Alexey Dokuchaev , Jean-Marc Zucconi , cvs-all@FreeBSD.org, ports-committers@FreeBSD.org Subject: Re: cvs commit: ports/games/doom Makefile ports/games/doom/files patch-ag patch-sndserv__soundsrv.c patch-sndserv__wadread.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Oct 2005 02:49:41 -0000 Edwin Groothuis wrote: > On Mon, Oct 10, 2005 at 12:59:06PM +0000, Alexey Dokuchaev wrote: >> On Mon, Oct 10, 2005 at 11:33:31AM +0000, Jean-Marc Zucconi wrote: >>> jmz 2005-10-10 11:33:30 UTC >>> >>> FreeBSD ports repository >>> >>> Modified files: >>> games/doom Makefile >>> games/doom/files patch-ag >>> Added files: >>> games/doom/files patch-sndserv__soundsrv.c >>> patch-sndserv__wadread.c >>> Log: >> ... >> >>> Replace post-patch with real patch files. >> I've always been under impression that we try to avoid creating trivial >> patches when desired functionality can be implemented using some >> inplace-editing tools. Could you elaborate on what you've done here? > > Inplace patches used for other things besides replacing FreeBSD > specific variables (X11BASE, PREFIX etc) are a bad habbit because > they obscure what is actually being replaced: > > #include > #ifdef LINUX > /* Linux: We need malloc.h for malloc() and friends */ > #include > #endif > > Now get your s/malloc.h/stdlib.h/ over it: > > #include > #ifdef LINUX > /* Linux: We need stdlib.h for malloc() and friends */ > #include > #endif > > I admit, it doesn't matter, but when you are looking through the > code (*waves at the maintainer who has to fix a problem*) this piece > of code actually looks silly. Hello FreeBSD ports collection! > > > Second reason: Using pre-patch inplace patches and patch-files on > the same file is a recipe for disaster for the maintainer when you > do the inplace first and the patch-files next (imagine having a > line within the patches file comparing range changed) and using > post-patch inplace patches leaves you with an invalid .orig file > to compare the patched file to. > > > So don't worry about the inodes, worry about the quality. > > > Edwin But OTOH, using a REINPLACE saves you from having to regenerate patches for every single update. It might make initial patching a bit trickier, but it can prevent unexpected problem from popping up in the future. In my eyes, saying that people shouldn't use pre-patch instead of patch files to prevent difficult sequential patching is akin to saying that people shouldn't own cars because they might slam their fingers in the door ::P # Adam -- Adam Weinberger adamw@magnesium.net || adamw@FreeBSD.org adamw@vectors.cx || adamw@gnome.org http://www.vectors.cx