String CompilationEnvironment::obj_suffix( bool dyn ) { String res; if ( get_dbg_level() > 0 ) res << ".g" << get_dbg_level(); if ( get_opt_level() > 0 ) res << ".O" << get_opt_level(); res << "." << get_os_type(); res << "." << get_cpu_type(); res << ( dyn ? ".os" : ".o" ); return res; }
SelfDescribingJson Utils::get_desktop_context() { if (!m_desktop_context) { json data; data[SNOWPLOW_DESKTOP_OS_TYPE] = get_os_type(); data[SNOWPLOW_DESKTOP_OS_VERSION] = get_os_version(); data[SNOWPLOW_DESKTOP_OS_SERVICE_PACK] = get_os_service_pack(); data[SNOWPLOW_DESKTOP_OS_IS_64_BIT] = get_os_is_64bit(); data[SNOWPLOW_DESKTOP_DEVICE_MANU] = get_device_manufacturer(); data[SNOWPLOW_DESKTOP_DEVICE_MODEL] = get_device_model(); data[SNOWPLOW_DESKTOP_DEVICE_PROC_COUNT] = get_device_processor_count(); m_desktop_context = new SelfDescribingJson(SNOWPLOW_SCHEMA_DESKTOP_CONTEXT, data); } SelfDescribingJson copy = *m_desktop_context; return copy; }