aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2023-04-05 17:39:56 +0100
committergingerBill <bill@gingerbill.org>2023-04-05 17:39:56 +0100
commiteef44425c3a39f620b18956ee33ea915ac89223e (patch)
tree20243511d0d867237d420e6efd940ef80762cbbc
parent167b320cddf0ac9adadf806a20adaaf25bf66a30 (diff)
Default zlib foreign import
-rw-r--r--vendor/zlib/zlib.odin63
1 files changed, 34 insertions, 29 deletions
diff --git a/vendor/zlib/zlib.odin b/vendor/zlib/zlib.odin
index 8a046a401..021449813 100644
--- a/vendor/zlib/zlib.odin
+++ b/vendor/zlib/zlib.odin
@@ -2,8 +2,13 @@ package vendor_zlib
import "core:c"
-when ODIN_OS == .Windows { foreign import zlib "libz.lib" }
-when ODIN_OS == .Linux { foreign import zlib "system:z" }
+when ODIN_OS == .Windows {
+ foreign import zlib "libz.lib"
+} else when ODIN_OS == .Linux {
+ foreign import zlib "system:z"
+} else {
+ foreign import zlib "system:z"
+}
VERSION :: "1.2.12"
VERNUM :: 0x12c0
@@ -41,39 +46,39 @@ gzFile_s :: struct {
gzFile :: ^gzFile_s
z_stream_s :: struct {
- next_in: ^Bytef,
- avail_in: uInt,
- total_in: uLong,
- next_out: ^Bytef,
- avail_out: uInt,
- total_out: uLong,
- msg: [^]c.char,
- state: rawptr,
- zalloc: alloc_func,
- zfree: free_func,
- opaque: voidpf,
- data_type: c.int,
- adler: uLong,
- reserved: uLong,
+ next_in: ^Bytef,
+ avail_in: uInt,
+ total_in: uLong,
+ next_out: ^Bytef,
+ avail_out: uInt,
+ total_out: uLong,
+ msg: [^]c.char,
+ state: rawptr,
+ zalloc: alloc_func,
+ zfree: free_func,
+ opaque: voidpf,
+ data_type: c.int,
+ adler: uLong,
+ reserved: uLong,
}
z_stream :: z_stream_s
z_streamp :: ^z_stream
gz_header_s :: struct {
- text: c.int,
- time: uLong,
- xflags: c.int,
- os: c.int,
- extra: [^]Bytef,
- extra_len: uInt,
- extra_max: uInt,
- name: [^]Bytef,
- name_max: uInt,
- comment: [^]Bytef,
- comm_max: uInt,
- hcrc: c.int,
- done: c.int,
+ text: c.int,
+ time: uLong,
+ xflags: c.int,
+ os: c.int,
+ extra: [^]Bytef,
+ extra_len: uInt,
+ extra_max: uInt,
+ name: [^]Bytef,
+ name_max: uInt,
+ comment: [^]Bytef,
+ comm_max: uInt,
+ hcrc: c.int,
+ done: c.int,
}
gz_header :: gz_header_s