Date: Mon, 1 Jan 2007 21:27:10 -0800 From: Jeremy Chadwick <koitsu@FreeBSD.org> To: Beech Rintoul <freebsd@alaskaparadise.com> Cc: freebsd-ports@freebsd.org Subject: Re: Port deletes .conf file on update Message-ID: <20070102052710.GA69315@icarus.home.lan> In-Reply-To: <200701011956.14607.freebsd@alaskaparadise.com> References: <200701011956.14607.freebsd@alaskaparadise.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Jan 01, 2007 at 07:56:12PM -0900, Beech Rintoul wrote: > ftp/proftpd deletes /usr/local/etc/proftpd.conf when updating. I thought I had > it fixed, but it continues to delete the config. Here's the section in the > makefile: > > post-install: > [ -f ${PREFIX}/etc/proftpd.conf ] || \ > ${CP} ${EXAMPLESDIR}/etc/proftpd.conf ${PREFIX}/etc/proftpd.conf.sample > > ... > > It creates proftpd.conf.sample properly, but then deletes proftpd.conf. BTW > proftpd.conf is not in the pkg-plist. > > How do I fix this? My guess is that the actual proftpd Makefile (not the port Makefile) is doing something during "make install" which nukes the existing proftpd.conf in PREFIX/etc. Logically your Makefile sh code looks like it should do exactly what you intend it (copy the EXAMPLESDIR configuration to etc as .sample if the test(1) returns a non-zero exit code). I assume it still breaks if you change the above sh code to the following? if [ ! -f ${PREFIX}/etc/proftpd.conf ] then ${CP} ${EXAMPLESDIR}/etc/proftpd.conf ${PREFIX}/etc/proftpd.conf.sample fi -- | Jeremy Chadwick jdc at parodius.com | | Parodius Networking http://www.parodius.com/ | | UNIX Systems Administrator Mountain View, CA, USA | | Making life hard for others since 1977. PGP: 4BD6C0CB |
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20070102052710.GA69315>