feat(FDLGEN): Add controls on FDLGEN class generation (refs #4930)

Prevents generating an incorrect class file when the parent family is not
found due to inconsistencies between the docread and doc tables.

Also:
- Check for PHP syntax errors before generating FDLGEN's files.
- FDLGEN's files were generated with an incorrect filesystem right that
  allowed local users to alter their's contents.
- Add checks for missing/spurious documents between the docread and doc
  tables in the supervisor page.
- Add checks for inconsistencies in families' logical names in the
  supervisor page.
Merge pull request #1297 from eguaj/3.2-A4930

feat(FDLGEN): Add controls on FDLGEN class generation (closes #4930)