Add check for working CXX compiler before Ice header check.

This prevents getting a missing Ice.h error when the problem is actually a non working CXX compiler
Don't override CXX if the os env for CXX is empty string
Add separate check for ice lib so we get better errors
Merge branch 'cpp-build-fixes' into cpp-test/addMoreTests