WL#5016: Fix header file include guards

Affects: Server-5.5   —   Status: Complete   —   Priority: Medium

This worklog is an implementation worklog to implement the following:

   - Add header file include guards to all header files that require it.

   - Change any header file include guards that start with _, since that either
     violates the C/C++ standard or is dangerously close to that.

   - Introduce any other changes that are necessary for the system to build

   - Other include file guards will be left alone.

No architecture review is needed since this is part of WL#4877.

The patch for this worklog is a re-committed version of a patch already
committed and reviewed for WL#4877.
The format of the include header guards are of the form:


Where <package> is the name of the package in uppercase letters, and <basename>
is the name of the header file (in uppercase letters) with the extension
removed. However, since the files in the sql/ directory are not yet in a package
and will eventually be moved to a package, we will not use a package name at
this time and just use the form: