From owner-freebsd-ports@freebsd.org Wed Sep 27 07:11:28 2017 Return-Path: Delivered-To: freebsd-ports@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E09F1E2CFE1; Wed, 27 Sep 2017 07:11:28 +0000 (UTC) (envelope-from se@freebsd.org) Received: from mailout11.t-online.de (mailout11.t-online.de [194.25.134.85]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mailout00.t-online.de", Issuer "TeleSec ServerPass DE-2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id A397F66F8F; Wed, 27 Sep 2017 07:11:28 +0000 (UTC) (envelope-from se@freebsd.org) Received: from fwd16.aul.t-online.de (fwd16.aul.t-online.de [172.20.26.243]) by mailout11.t-online.de (Postfix) with SMTP id 395874268603; Wed, 27 Sep 2017 09:11:26 +0200 (CEST) Received: from Stefans-MBP-2.fritz.box (EeMNTkZUghbvTSDu6iqZTjhDDRfZMmHD5F+QLgwGQx-N2a6p4c5KsFQZbYVX0CMw0c@[84.154.105.197]) by fwd16.t-online.de with (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384 encrypted) esmtp id 1dx6V7-0iQlxA0; Wed, 27 Sep 2017 09:11:21 +0200 Subject: Re: Porters Handbook section 4.4 To: koobs@FreeBSD.org, Russell Haley Cc: doc@freebsd.org, freebsd-ports@freebsd.org References: <8a3e663a-d94f-0ef7-bbc7-8ebaa111f6dd@FreeBSD.org> <7b2f2464-5c35-e24a-2047-838c1a9e96a3@FreeBSD.org> From: Stefan Esser Message-ID: <9a7b7e17-d4c8-6a22-76ea-70aa303b6c9d@freebsd.org> Date: Wed, 27 Sep 2017 09:11:20 +0200 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 In-Reply-To: <7b2f2464-5c35-e24a-2047-838c1a9e96a3@FreeBSD.org> Content-Type: text/plain; charset=windows-1252 Content-Language: en-GB Content-Transfer-Encoding: 7bit X-ID: EeMNTkZUghbvTSDu6iqZTjhDDRfZMmHD5F+QLgwGQx-N2a6p4c5KsFQZbYVX0CMw0c X-TOI-MSGID: 95eb1013-2a0f-4b78-9d67-c49c771f2bc3 X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Sep 2017 07:11:29 -0000 Am 26.09.17 um 08:21 schrieb Kubilay Kocak: > In section: > > 4.4. Patching > > - Add new section (at/numbered 4.4.2) > - Name: Automatic Patch Generation > - Renumber sections (4.4.2 -> 4.4.3) > > Text: > > The ports framework provides a {{{makepatch}} target, which when run, > automatically creates correctly named and formatted patch files in the > correct location. The general process is as follows: > > % cd > % make patch > > Note: In the general case, {{{make patch}} is used (not just {{{make > extract}}} to extract the DISTFILES), because ports that contain > existing patches need to have the patches applied so that they are also > generated (regenerated) in the last step. > > ``` > % cd work/ (WRKSRC) > ``` > > At this point, make the source changes in WRKSRC: > > ``` > % cp .orig Do not perform this copy operation, IF the .orig file does already exist (from the earlier "make patch" step). I'd also use "cp -p" to preserve the original modification time, which will be included in the patch ... Else, your change will be against a patched file, without the patch that lead to this state being conserved. Regards, STefan