From owner-freebsd-doc@FreeBSD.ORG Sun Sep 1 07:30:01 2013 Return-Path: Delivered-To: freebsd-doc@smarthost.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 47E881A1 for ; Sun, 1 Sep 2013 07:30:01 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 36C0D2B5A for ; Sun, 1 Sep 2013 07:30:01 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.7/8.14.7) with ESMTP id r817U19j060905 for ; Sun, 1 Sep 2013 07:30:01 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.7/8.14.7/Submit) id r817U0bN060904; Sun, 1 Sep 2013 07:30:00 GMT (envelope-from gnats) Date: Sun, 1 Sep 2013 07:30:00 GMT Message-Id: <201309010730.r817U0bN060904@freefall.freebsd.org> To: freebsd-doc@FreeBSD.org Cc: From: Frederic Culot Subject: Re: docs/181080: porters-handbook: mention PLIST_DIRSTRY X-BeenThere: freebsd-doc@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: Frederic Culot List-Id: Documentation project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Sep 2013 07:30:01 -0000 The following reply was made to PR docs/181080; it has been noted by GNATS. From: Frederic Culot To: bug-followup@FreeBSD.org Cc: Subject: Re: docs/181080: porters-handbook: mention PLIST_DIRSTRY Date: Sun, 1 Sep 2013 07:22:08 +0000 --d6Gm4EdcadzBjdND Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Following an off-list feedback from Warren (wblock@) I submit this updated patch which adds a note explaining into a bit more detail what PLIST_DIRSTRY is used for. This note is added right after the first PLIST_DIRS appearence and gives a link to the section where the @dirrm and @dirrmtry macros are explained, so I believe the reader is now able to grasp the meaning of PLIST_DIRSTRY more easily. However, adding an example of the PLIST_DISTRY usage was not deemed necessary as it is pretty straightforward to extrapolate the already existing PLIST_DIRS example for PLIST_DIRSTRY. Feel free to ping me in case you have any comments related to this updated patch, and thanks again Warren for your feedback. Cheers, Frederic --d6Gm4EdcadzBjdND Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="porters-handbook.diff" Index: book.xml =================================================================== --- book.xml (revision 42606) +++ book.xml (working copy) @@ -278,6 +278,20 @@ Of course, PLIST_DIRS should be left unset if a port installs no directories of its own. + + It is possible that several ports share a common + directory. In that case + PLIST_DIRS should be replaced by + PLIST_DIRSTRY so that the directory + is removed only if empty, otherwise it is silently + ignored. PLIST_DIRS and + PLIST_DIRSTRY are equivalent to + using @dirrm and + @dirrmtry in + pkg-plist, which are described in + . + + The price for this way of listing port's files and directories is that you cannot use command sequences described in &man.pkg.create.1;. Therefore, it is suitable @@ -9918,20 +9932,25 @@ TMPPLIST. Another possibility to modify port's packing list is based - on setting the variables PLIST_FILES and - PLIST_DIRS. The value of each variable is + on setting the variables PLIST_FILES, + PLIST_DIRS, and + PLIST_DIRSTRY. The value of each variable is regarded as a list of pathnames to write to TMPPLIST along with PLIST contents. Names - listed in PLIST_FILES and - PLIST_DIRS are subject to + listed in PLIST_FILES, + PLIST_DIRS, and + PLIST_DIRSTRY are subject to %%VAR%% substitution, as described above. Except for that, names from PLIST_FILES will appear in the final - packing list unchanged, while @dirrm will - be prepended to names from PLIST_DIRS. To - take effect, PLIST_FILES and - PLIST_DIRS must be set before + packing list unchanged, while @dirrm and + @dirrmtry will + be prepended to names from PLIST_DIRS + and PLIST_DIRSTRY, respectively. To + take effect, PLIST_FILES, + PLIST_DIRS, and + PLIST_DIRSTRY must be set before TMPPLIST is written, i.e., in pre-install or earlier. @@ -10059,8 +10078,9 @@ pkg-plist file (with or without variable substitution), or embedded into the Makefile via - PLIST_FILES and - PLIST_DIRS. Even if the contents are + PLIST_FILES, + PLIST_DIRS, and + PLIST_DIRSTRY. Even if the contents are auto-generated by a tool or a target in the Makefile before the inclusion into the Ports Collection by a committer, this is still considered a static --d6Gm4EdcadzBjdND--