"make plist" to create the base PLIST file, and add @sample lines to create
the directories, also either "@extra (file)" or "@extraunexec rm -r
(path)/*" to cover files that night be created at runtime so that
pkg_delete -c is able to remove them.
--
Sent from a phone, apologies for poor formatting.
On 1 October 2018 03:38:58 William Leuschner <[email protected]> wrote:
I’ve gotten to the stage where I need to create the plist for netdata. (I
haven’t touched any of the plugins yet; I want to package it so I can
cleanly install/deinstall it and verify that I haven’t broken anything.)
The project’s makefile creates a few directories in /var/lib that merely
contain .keep files.
Is better to work around this with a post-install rule in the port Makefile
or to patch the software itself to create its own local state directories
if they don’t exist?
- William
On 11 Sep, 2018, at 00:22, William Leuschner <[email protected]> wrote:
On 10 Sep, 2018, at 05:50, Stuart Henderson <[email protected]> wrote:
It's not going to be the simplest first port (it will need actual code
porting, rather than just writing ports Makefile etc).
Yeah, I’ve already run into a few of these.
Many of the Linux-ish plugins use procfs which isn't very helpful -
the FreeBSD code is going to be closer but we don't have the
GETSYSCTL_BY_NAME/GETSYSCTL_SIMPLE interfaces, these need changing to
use sysctl(2).
You probably want to refer to /usr/src/usr.bin/top while looking at
this.
Thanks for these tips! I haven’t yet made it to the FreeBSD plugin, but
the source for top has offered a few hints in other places.
Upstream also seems to be quite excited to have an OpenBSD port (or really
ports to any other platform), which is great news!
https://github.com/firehol/netdata/issues/601