Make sure the TYPE variable is actually defined for nmake builds.