From owner-freebsd-questions@FreeBSD.ORG Wed May 5 05:41:27 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 246BE16A4CE for ; Wed, 5 May 2004 05:41:27 -0700 (PDT) Received: from mail03.talkactive.net (mail03.talkactive.net [81.19.252.192]) by mx1.FreeBSD.org (Postfix) with SMTP id 1FED443D2F for ; Wed, 5 May 2004 05:41:26 -0700 (PDT) (envelope-from mikkel@talkactive.net) Received: (qmail 99991 invoked from network); 5 May 2004 12:41:19 -0000 Received: from unknown (HELO ?192.168.1.120?) (81.19.252.4) by mail03.talkactive.net with SMTP; 5 May 2004 12:41:18 -0000 From: Mikkel Christensen Organization: Talk|Active To: Matthew Seaman , freebsd-questions@freebsd.org Date: Wed, 5 May 2004 12:41:24 +0000 User-Agent: KMail/1.6.1 References: <200405051211.22184.mikkel@talkactive.net> <20040505122932.GA12413@happy-idiot-talk.infracaninophile.co.uk> In-Reply-To: <20040505122932.GA12413@happy-idiot-talk.infracaninophile.co.uk> MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <200405051241.24655.mikkel@talkactive.net> Subject: Re: Patching ports 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: Wed, 05 May 2004 12:41:27 -0000 On Wednesday 05 May 2004 12:29, Matthew Seaman wrote: > On Wed, May 05, 2004 at 12:11:22PM +0000, Mikkel Christensen wrote: > > > How do I add a patch to a certain port? > > Usually I would use the "patch" program to add the patch to the source code. > > But when using ports the system begins compiling right after rewtrieving the source. Thus not giving me a change to apply the patch. > > I've seen a folder named "files" in which patches part of the port seem to be located. But just adding the patchfile here apperently wont do much good. > > I've tried using the "PATCHFILES" variable in the Makefile but then the system complains the my patchfile does not have a matching MD5 hash. > > Does anyone know how to handle this issue? > > When building a port you can type: > > # make extract > > which will download any sources, check the size and checksums, unpack > the sources into the work directory and apply any patches that come > with the port. And then stop. At this point you can make whatever > modifications you wish to yourself, and then finish off the build by > > # make > > So long as your patch doesn't add or delete files from the expected > packing list then just doing a: > > # make install > > will work. > > It is also possible to put your patch file into the port's files > directory and have it automatically applied, but you need to take care > to account for the order that patch files get applied. > Thank you both for a quick and explaning reply. The last par of your answer brings up a short question though. Will patch-files automatically be run if they are placed in the "files" folder? It did not seem that way when I tried but I might have done something wrong:) - Mikkel