This source file includes following definitions.
- Has32BitOnlyCPU
- LocalizedObsoleteSystemString
#include "chrome/browser/mac/obsolete_system.h"
#include <sys/sysctl.h>
#include <sys/types.h>
#include "grit/chromium_strings.h"
#include "ui/base/l10n/l10n_util.h"
#if !defined(ARCH_CPU_64_BITS)
bool ObsoleteSystemMac::Has32BitOnlyCPU() {
int value;
size_t valueSize = sizeof(value);
if (sysctlbyname("hw.cpu64bit_capable", &value, &valueSize, NULL, 0) != 0) {
return true;
}
return value == 0;
}
base::string16 ObsoleteSystemMac::LocalizedObsoleteSystemString() {
return l10n_util::GetStringUTF16(
Is32BitEndOfTheLine() ? IDS_MAC_32_BIT_OBSOLETE_NOW :
IDS_MAC_32_BIT_OBSOLETE_SOON);
}
#endif