diff --git a/vlib/v/gen/cgen.v b/vlib/v/gen/cgen.v index c1df697216..ca6a4b31b5 100644 --- a/vlib/v/gen/cgen.v +++ b/vlib/v/gen/cgen.v @@ -3219,6 +3219,21 @@ fn (mut g Gen) comp_if_to_ifdef(name string, is_comptime_optional bool) string { 'macos' { return '__APPLE__' } + 'mach' { + return '__MACH__' + } + 'darwin' { + return '__DARWIN__' + } + 'hpux' { + return '__HPUX__' + } + 'gnu' { + return '__GNU__' + } + 'qnx' { + return '__QNX__' + } 'linux' { return '__linux__' } @@ -3231,6 +3246,9 @@ fn (mut g Gen) comp_if_to_ifdef(name string, is_comptime_optional bool) string { 'netbsd' { return '__NetBSD__' } + 'bsd' { + return '__BSD__' + } 'dragonfly' { return '__DragonFly__' }