Changed preprocessor conditionals to properly check the platform variables passed by CMake.