docs/166541: [patch] Clarification for configuration file handling
Mel Flynn
rflynn at acsalaska.net
Sat Mar 31 20:10:13 UTC 2012
>Number: 166541
>Category: docs
>Synopsis: [patch] Clarification for configuration file handling
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-doc
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Sat Mar 31 20:10:10 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator: Mel Flynn
>Release: FreeBSD 8.2-STABLE amd64
>Organization:
>Environment:
System: FreeBSD datakitty.lan.rachie.is-a-geek.net 8.2-STABLE FreeBSD 8.2-STABLE #6 r230977: Sun Feb 5 06:20:11 AKST 2012 mel at datakitty.lan.rachie.is-a-geek.net:/data/obj/data/RELENG_8/src/sys/GENERIC amd64
>Description:
Section in the porter's handbook could use a bit more clarification
and most importantly what the common mistakes are and how to handle them.
>How-To-Repeat:
D.N.A.
>Fix:
--- configfiles-clarification.patch begins here ---
Index: en_US.ISO8859-1/books/porters-handbook/book.sgml
===================================================================
RCS file: /home/ncvs/doc/en_US.ISO8859-1/books/porters-handbook/book.sgml,v
retrieving revision 1.1173
diff -u -r1.1173 book.sgml
--- en_US.ISO8859-1/books/porters-handbook/book.sgml 22 Mar 2012 04:09:20 -0000 1.1173
+++ en_US.ISO8859-1/books/porters-handbook/book.sgml 31 Mar 2012 19:49:36 -0000
@@ -9378,14 +9378,19 @@
${CP} -p ${PREFIX}/etc/orbit.conf.sample ${PREFIX}/etc/orbit.conf ; \
fi</programlisting>
- <para>Example of the <filename>pkg-plist</filename> part:</para>
+ <para>For each configuration file create the following tuple in
+ <filename>pkg-plist</filename>:</para>
<programlisting>@unexec if cmp -s %D/etc/orbit.conf.sample %D/etc/orbit.conf; then rm -f %D/etc/orbit.conf; fi
etc/orbit.conf.sample
@exec if [ ! -f %D/etc/orbit.conf ] ; then cp -p %D/%F %B/orbit.conf; fi</programlisting>
- <para>For information on the above variables see
- &man.pkg.create.1;</para>
+ <para>The ordering is important, since the sample file still has
+ to exist in order to be compared upon deinstallation. Upon
+ installation, the sample file has to be extracted before it can be
+ copied. To debug any issues, temporarily remove the -s flag to
+ &man.cmp.1;. For information on the above variables see
+ &man.pkg.create.1;</para>
<para>If there is a very good reason not to install a working
configuration file by default, use a <link
--- configfiles-clarification.patch ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-doc
mailing list