startupitems arcanery

markd at markd at
Thu Mar 29 09:04:31 PDT 2007

I am trying to understand the startupitems in the dhcp port because I want
to do somewthing similar in another port.  Can someone explain what the
escapes, brackets, "-x", and "-r" do?  And what interprets the "-x" and
"-r"?  The shell?

startupitem.create      yes        dhcpd
startupitem.init        "PID=/var/run/"
startupitem.start       "\[ -x ${prefix}/sbin/dhcpd \] &&
${prefix}/sbin/dhcpd -cf ${prefix}/etc/dhcp/dhcpd.conf -lf
startupitem.stop        "\[ -r \${PID} \] && kill \$(cat \${PID})"


More information about the macports-dev mailing list