Fix build failures after moving to 3.8.

When enabling the following options:

   tools-debug tools-profile tools-benchmark tools-testapps

various build issues occur.  Fortunately they were all either simple
or already fixed upstream.   These commits allow these builds to succeed.
They have not necessarily been tested nor are all of these packages
officially supported but it would be nice to not have a build failure
since these options are documented.