ZoneMinder/ZoneMinder — pull request #327 by lingfish (2014-02-09 04:46:08+00:00)
Title: Make zmpkg.pl check for more required directories other than just @ZM_TMPDIR@

Prefaces:
* This may not be all that clean, but it's close and avoids repitition.
* My Perl fu may be bad; apologies, but I'm normally allergic to perl anyway ;)

I believe `zmpkg.pl` should do more thorough checking of vital directories, after I decided to move `ZM_PATH_SOCKS` and `ZM_PATH_SWAP` to Debian's `/run` (effectively making those `tmpfs`-based.) It tends to currently assume that all configurable paths will be user-configured under a build-time macro -- that being `@ZM_TMPDIR@`.

I did find patches to distro-based scripts, like 11d0428a206d9173dedd3c2ad9bfbf21df29cf58, but I believe this is the wrong place to assure directories that are configurable within ZoneMinder actually exist. I've also noticed that ZM leaves sockets and stuff from `ZM_PATH_SWAP` behind too upon shutdown, but that's for another day, maybe.