diff options
author | 諏訪子 <suwako@076.moe> | 2024-06-18 01:40:09 +0900 |
---|---|---|
committer | 諏訪子 <suwako@076.moe> | 2024-06-18 01:40:09 +0900 |
commit | 759ca0074f7275b0bd1e58bc88ad2779035c9fb8 (patch) | |
tree | 6349a57c169242944af0080d3f70a58a4612e697 /src/host.c | |
parent | 11c97887ef28e9b073d9abf1c2da70cd01491c9e (diff) |
NetBSDでの修正
Diffstat (limited to 'src/host.c')
-rw-r--r-- | src/host.c | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -27,9 +27,13 @@ void run_command(const char *command) { } void display_host_model() { -#if defined(__OpenBSD__) || defined(__FreeBSD__) || defined(__NetBSD__) || \ - defined(__DragonFly__) || defined(__minix) +#if defined(__OpenBSD__) || defined(__FreeBSD__) || \ + defined(__DragonFly__) run_command("sysctl -n hw.vendor hw.product"); +#elif defined(__NetBSD__) + run_command("sysctl -n machdep.dmi.system-vendor && " + "echo \" \" && sysctl -n machdep.dmi.system-version && " + "echo \" \" && sysctl -n machdep.dmi.system-product"); #elif defined(__sun) run_command("prtconf -b | awk -F':' '/banner-name/ {printf $2}'"); #elif defined(__linux__) |