Created
February 19, 2020 11:59
-
-
Save YukiSakamoto/e0ccda9dbc37dedc639efa2bebf78316 to your computer and use it in GitHub Desktop.
Get CPU type of Mac
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <mach-o/arch.h> | |
#include <iostream> | |
int main(void) | |
{ | |
const NXArchInfo *pNXArchInfo = NXGetLocalArchInfo(); | |
std::cout << pNXArchInfo->name << std::endl; | |
std::cout << pNXArchInfo->description << std::endl; | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment