Have default foreign import system paths

This commit is contained in:
gingerBill
2024-01-17 16:32:26 +00:00
parent 12e53f2336
commit d9fafa7000
7 changed files with 27 additions and 18 deletions
+4 -3
View File
@@ -2,9 +2,10 @@ package stb_image
import c "core:c/libc"
when ODIN_OS == .Windows { foreign import stbiw "../lib/stb_image_write.lib" }
when ODIN_OS == .Linux { foreign import stbiw "../lib/stb_image_write.a" }
when ODIN_OS == .Darwin { foreign import stbiw "../lib/darwin/stb_image_write.a" }
when ODIN_OS == .Windows { foreign import stbiw "../lib/stb_image_write.lib" }
else when ODIN_OS == .Linux { foreign import stbiw "../lib/stb_image_write.a" }
else when ODIN_OS == .Darwin { foreign import stbiw "../lib/darwin/stb_image_write.a" }
else { foreign import stbi "system:stb_image_write" }
write_func :: proc "c" (ctx: rawptr, data: rawptr, size: c.int)