Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 22 Dec 2003 09:36:10 -0600
From:      Pete Fritchman <petef@absolutbsd.org>
To:        Tillman Hodgson <tillman@seekingfire.com>
Cc:        FreeBSD-Ports <freebsd-ports@freebsd.org>
Subject:   Re: What's the appropriate Makefile-fu to change someport.conf to someport.conf.sample? 
Message-ID:  <20031222153610.771B817743@sirius.firepipe.net>
In-Reply-To: Message from Tillman Hodgson <tillman@seekingfire.com>  <20031222150423.GJ42615@seekingfire.com> 

next in thread | previous in thread | raw e-mail | index | archive | help
* Mon, 22 Dec 2003 09:04:23 CST - Tillman Hodgson:
| pre-install:
|         cp ${WRKSRC}/latd.conf ${WRKSRC}/latd.conf.sample

That will make a file named .sample, but not actually install it.  If
you're using the upstream Makefile for installing (as opposed to a
do-install target), you'll probably need to patch that to know about
installing latd.conf.sample (and not installing latd.conf over top of
an existing latd.conf!).

| and then putting latd.conf.sample into pkg-plist. It creates
| latd.conf.sample in WRKSRC, but still installs latd.conf ... I assume
| that's because it decides to do based on somethign other than pkg-plist.

Right; pkg-plist is a FreeBSD ports thing, the upstream Makefiles for
software doesn't look at it.

| Is there a canonical way to handle this situation in a ports Makefile so
| that config files don't clobber?

There are examples all over the tree.  Checkout the editors/joe-devel
port for an example (specifically files/patch-Makefile.in and pkg-plist).

--pete



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20031222153610.771B817743>