fix(wcontrol_check_pgversion): Use version_compare() for Pg's version check (refs #5018)

Use PHP's version_compare() to perform Pg's version checks instead of
using custom comparison which does not handle versions like "9.4beta2".
Merge pull request #110 from eguaj/1.5-A5018

fix(wcontrol_check_pgversion): Use version_compare() for Pg's version check (closes #5018)
Merge pull request #111 from eguaj/1.5-A5054

feat(Module): Validate `info.xml` from module's packages (closes #5054)
fix(XML): Improve XML loading/parsing performance (refs #4881)

- Cache DOMDocuments from XML files for reuse.
- Prevent corruption of XML files (e.g. when in low disk space
  conditions) by safely writing them with a transaction.
fix(net): Improve network requests performance (refs #4881)

- Reduce network bandwidth usage by using "Accept-Encoding" headers for
  compressed responses.
- Reduce number of HTTP requests by caching the responses' files.
- Move all net/www related code into distinct WWW\UserAgent class.
refactor(lock): Reworked CLI locking mechanism (refs #4504)

A lock is acquired by the CLI for data modification operations. If the
CLI cannot acquire the lock, then it exits immediatly (with exit code
100) and does not waits for the lock to be released.
Merge pull request #113 from eguaj/1.5-A4881-rebase

fix(perf): Performance and locking improvements (closes #4881)(closes #4504)
feat(log): Improve error logging (refs #5080)

HTTP responses' errors are now logged with syslog.

Syslog messages are sent with identity/tag "dynacase-control", facility
LOG_USER and varying priorities (LOG_ERR, LOG_INFO, etc.).

Additionally, if the "Local log" is activated in the Web UI, then
errors are also logged in a `$WIFF_ROOT/log/wiff.log` file. A set of
"View" and "Clear" buttons are available for respectively viewing the
file (as plain text) and clearing it's content.

Also, some system() calls have been rewritten with exec() in order to
capture a more complete output of the commands' errors.
feat(CLI): Detailed message for unmet dependencies (refs #4816)
Merge pull request #116 from eguaj/1.5-A5080-A4816

feat(log): Improve error logging (closes #5080)(closes 4816)
fix(UI): Set "Server Warnings" minwidth to 600px (refs #5054)
fix(CLI): Missing break in case 'crontab' (refs #5157)
feat(CLI): Added commands to CLI (refs #4593)

Commands added to CLI:
- Create context
- Manage global repositories' list
- Manage dynacase-control's registration
- Change context's 'url' and 'description'
- Change context's repositories
- Manage context's registration

Also:
- Correctly handle special chars (e.g. '%', ':' and '@') in eec-username
  and eec-password by urlencoding them.
feat(log): Log WIFF's Web UI activity (refs #5160)
Merge pull request #118 from eguaj/1.5-A5157-A4593

feat(CLI): Added commands to CLI (closes #4593)(closes #5160)(closes #5157)(closes #5054)
feat(context): Run module's pre-delete phase when deleting a context (refs #4588)

The <pre-delete/> processes of the context's module are now executed
when deleting a context.

This allows a module to perform additional cleanup on the database for
exemple.

The modules are processed by reverse order of theirs dependencies.  So,
the least dependant modules are executed first, and dynacase-core is
treated last.

`xsd` subdir has been updated with support for the `<pre-delete/>` tag.
Merge pull request #119 from eguaj/1.5-A4588

feat(context): Run module's pre-delete phase when deleting a context (closes #4588)
feat(log): Better support for multi-line messages (refs #5080)

Separately log each lines from a multi-line message and manually write
to logfile to override limit in line's length.
fix(Module): Properly display module's name in getValidDOMDocumentInfoXml() (refs #5054)
fix(Module): Use an external entity loader for schema validation (refs #5054)

Setting the catalog file with the XML_CATALOG_FILES env var at runtime
is not supported on Ubuntu 14.10 as the libxml initialization seems to
be done earlier, before our putenv() is executed.

So, to workaround this, we manually parse the catalog.xml file and setup
a custom external entity loader to resolve URNs to local XSD files.

Also:
- Add requirement for PHP >= 5.4 (for libxml_set_external_entity_loader)