replaced ODIN_OS string values with enums

This commit is contained in:
pvance
2022-07-28 04:19:28 -04:00
committed by GitHub
parent a315e7c962
commit 4aad835a66
+13 -10
View File
@@ -3,22 +3,25 @@ package glfw_bindings
import "core:c"
import vk "vendor:vulkan"
when ODIN_OS == "linux" { foreign import glfw "system:glfw" } // TODO: Add the billion-or-so static libs to link to in linux
when ODIN_OS == "darwin" {
foreign import glfw {
"../lib/darwin/libglfw3.a",
"system:Cocoa.framework",
"system:IOKit.framework",
"system:OpenGL.framework",
}
}
when ODIN_OS == "windows" {
when ODIN_OS == .Windows {
foreign import glfw {
"../lib/glfw3_mt.lib",
"system:user32.lib",
"system:gdi32.lib",
"system:shell32.lib",
}
} else when ODIN_OS == .Linux {
// TODO: Add the billion-or-so static libs to link to in linux
foreign import glfw "system:glfw"
} else when ODIN_OS == .Darwin {
foreign import glfw {
"../lib/darwin/libglfw3.a",
"system:Cocoa.framework",
"system:IOKit.framework",
"system:OpenGL.framework",
}
} else {
foreign import glfw "system:glfw"
}
#assert(size_of(c.int) == size_of(b32))