Add a confdir implementation for Darwin and Linux