Cmake build type update

Fixes problem where ERT was built with -O2 on Linux, even if BUILD_TYPE was set to Debug making debugging through gdb difficult.

-O2, -g and -O3 are set according to CMAKE_BUILD_TYPE. Default build type is RelWithDebInfo which matches the -g -O2 flags used previously.