On Wed, Aug 06, 2014 at 09:19:48PM +0200, Melvyn Sopacua wrote: > Hi Baptiste, > > On Tue, 5 Aug 2014, Baptiste Daroussin wrote: > > > On Tue, Aug 05, 2014 at 05:35:03AM +0200, Melvyn Sopacua wrote: > >> Hi, > >> > >> the issue: > >> for www/magento there is a sample data package. I'd like to make a port > >> for it, but the sample data overwrites a few files in the www/magento > >> port's installed files to match the sample theme. > >> > >> This is OK and needed. But I don't know how to tell pkg this. > >> > >> I can make the sample data an option in the magento port and keep it in > >> one port, but this would put a large burdon on maintaining the pkg-plist > >> on upgrades as sample-data is only updated when backwards incompatible > >> changes are made to the core that make the older sample data unusable. > >> So I prefer to maintain it as a separate port. > >> > > There is a problem if that is how the port works. If magento expect some > > data to > > be replaced changed etc then it should not be tracked by the package to > > avoid an > > upgrade of the package to overwrite the user special version which is why > > pkg(8) > > has a strong hold on which files belongs to which package. > > > > So I think magento should be fixed in that regard. otherwise there is the > > PERMISSIVE options for pkg(8) but this is really really not recommanded to > > use. > > The best is again to fix the magento port so it allows the normal use cases. > > It's going to be a hack either way. > Think of it as two sample files from different sources: > default.conf.sample > optimized.conf.sample > > Both are candidates for myconfig.conf, where optimized should win and > otherwise default, but they come from two different ports. This may > actually be the way to handle it, if @sample didn't assume the same > basename. > > So I guess I have to install two different .sample files and a > pkg-(de)install script that updates to the right one, keeping the actual > file out of the pkg-plist. > > That's the least hack-ish I can come up with for now, but I'm open to > suggestions. > > -- > Melvyn
There is the @sample keyword for that ;) regards, Bapt
pgp4_Bh2mWgR_.pgp
Description: PGP signature