draconisplusplus/src/os/macos.cpp

19 lines
256 B
C++
Raw Normal View History

2024-05-29 06:39:39 -04:00
module;
2024-05-29 00:28:54 -04:00
#include <sys/sysctl.h>
2024-05-29 06:39:39 -04:00
export module OS;
export uint64_t get_meminfo() {
2024-05-29 00:28:54 -04:00
uint64_t mem = 0;
size_t size = sizeof(mem);
sysctlbyname("hw.memsize", &mem, &size, nullptr, 0);
return mem;
}
2024-05-29 06:39:39 -04:00
export string get_nowplaying() {
return "";
}