Commit Graph

121 Commits

Author SHA1 Message Date
Samuel Elgozi 61f02d9f49 pass flags down from os.send in darwin and linux 2025-01-26 14:03:45 +02:00
gingerBill ee76acd665 Merge pull request #4427 from laytan/posix-additions
Finish sys/posix with Linux and partial Windows support & clean up other packages as a result
2024-10-30 11:43:47 +00:00
Laytan Laats 1cebc025b0 sys/posix: impl rest of linux, impl some of Windows 2024-10-28 18:59:06 +01:00
Jeroen van Rijn 00ec862b63 Merge pull request #4335 from colrdavidson/datetime_tz
Add Timezone Support to Odin
2024-10-22 10:18:38 +02:00
Laytan 0157ff1541 Merge pull request #4118 from andradei/posix-linux
Linux POSIX support
2024-10-13 20:05:03 +02:00
Colin Davidson 4c8e355444 tweaks per laytan suggestions 2024-10-10 09:14:29 -07:00
Yuriy Grynevych cbf0471c72 Update core/os/os_linux.odin
Co-authored-by: Laytan <laytanlaats@hotmail.com>
2024-09-19 00:11:06 +03:00
Yuriy Grynevych 4ff836609c [core/os] get_current_directory: Add allocator arg to targets where its missing 2024-09-18 21:03:48 +03:00
Isaac Andrade 4577d541ec Add contants RTLD contants on os_linux and posix (dlfcn). 2024-08-28 22:15:11 -06:00
Isaac Andrade f0e631cfa3 Use native types on linux POSIX structs. 2024-08-28 19:08:48 -06:00
Feoramund 6aedb2695a Report Invalid_Whence on some os platforms
- Move `Seek`-related checks into OS-specific files for granularity.

Platforms:
- Darwin
- FreeBSD
- Haiku
- Linux
- NetBSD
- OpenBSD
2024-08-28 19:53:20 +02:00
Feoramund 0243647e15 Add missing flush functionality to os platforms
Platforms:
- FreeBSD
- Haiku
- Linux
- NetBSD
- OpenBSD
2024-08-28 19:53:20 +02:00
Isaac Andrade 45322023e3 Merge branch 'master' of github.com:odin-lang/Odin into posix-linux 2024-08-27 18:51:58 -06:00
gingerBill eb799393d5 Fix -vet-tabs issues 2024-08-24 13:56:41 +01:00
Isaac Andrade 90aa7dff04 Add POSIX dirent struct for Linux. 2024-08-23 19:56:45 -06:00
Laytan c0125f3192 correct the riscv64 stat structs 2024-08-21 14:41:23 +02:00
Laytan ca6ef95b03 add support for linux_riscv64 and freestanding_riscv64 2024-08-20 14:06:40 +02:00
Laytan Laats efe68c2e24 posix: add package 2024-08-14 01:44:35 +02:00
Laytan Laats a4ac3cc6e8 fix os.read_dir closing the given file descriptor 2024-08-12 18:51:27 +02:00
Jeroen van Rijn fa6f343261 Remove unused import. 2024-08-09 19:06:50 +02:00
gingerBill c078b2dd1b Add @(require_results) 2024-08-04 15:24:26 +01:00
gingerBill bf948ab8ae Add stubs for flush on platforms that didn't have it 2024-08-04 15:07:24 +01:00
gingerBill bdbbbf5c95 Fix typo; remove unneeded casts 2024-08-04 12:39:21 +01:00
gingerBill 97c499dbb4 Begin mapping os.Error in the rest of the codebase 2024-08-04 11:58:04 +01:00
gingerBill 160048eaee Errno -> Error 2024-08-04 11:46:42 +01:00
gingerBill def2e2e271 Try to map to General_Error where possible 2024-08-04 11:44:45 +01:00
gingerBill 28666414bc More clean ups of ERROR_NONE and != nil usage 2024-08-04 11:37:49 +01:00
gingerBill 29b6eebcd5 Clean up error handling 2024-08-04 11:21:09 +01:00
gingerBill 9f9abb8fb3 Use union #shared_nil for os.Error 2024-08-04 11:05:30 +01:00
gingerBill e60951a902 Begin converting os.Errno to be a nil-able type as a transition period 2024-08-04 10:51:08 +01:00
gingerBill 4b71c47fd5 Check for unneeded transmute with -vet-cast 2024-06-29 12:02:31 +01:00
gingerBill dd7c65a89c Merge pull request #2998 from laytan/os-improvements
OS improvements
2024-02-03 12:29:39 +00:00
gingerBill 038086d1d9 Alias heap calls from base:runtime is core:os 2024-01-28 22:47:55 +00:00
gingerBill 3e7e779abf Replace core:* to base:* where appropriate 2024-01-28 22:18:51 +00:00
Laytan Laats 9a1c4dc56d implement a max read/write at a time for non-windows (windows already has this) 2023-12-14 18:05:06 +01:00
Laytan Laats d278c852cc clean up field names 2023-12-08 23:43:30 +01:00
Laytan Laats a6aca5d6d1 fix struct stat layout linux arm64 2023-12-06 17:17:45 +01:00
flysand7 4d65b1ab9c Implement new sys/unix package 2023-10-27 10:51:21 +11:00
gingerBill 35857d3103 Fix wrong type 2023-09-12 23:01:49 +01:00
Rickard Andersson f048ad13b5 fix(set_env): use clone_to_cstring instead of unsafe_to_cstring 2023-06-27 21:48:53 +03:00
Rickard Andersson d03d5d8f03 style: use tabs
:[
2023-06-27 21:46:00 +03:00
Rickard Andersson 6ff0ce15e7 cleanup: remove leftover line 2023-06-27 21:42:20 +03:00
Rickard Andersson 330b393e16 fix(os): use setenv instead of putenv
`setenv` doesn't copy the value that is put, which means that the
previous code had a bug where we free'd the temporary memory and the
environment was accidentally cleared right after the function finished.
2023-06-27 21:37:10 +03:00
Rickard Andersson 37469dc9c2 fix(poll): make interface more odinary
We take `fds` as a normal slice and get the length from it instead of
bothering with a second parameter.
2023-06-15 16:10:00 +03:00
Rickard Andersson a5ed5883c7 cleanup: more tabs 2023-06-14 23:59:09 +03:00
Rickard Andersson d6540d9077 fix(os_linux): call ppoll instead on arm64 2023-06-14 23:26:43 +03:00
Rickard Andersson 091c515fea cleanup(os_linux): remove select 2023-06-14 22:34:57 +03:00
Rickard Andersson 4f2b9835f5 feat(unix): add poll 2023-06-14 22:13:36 +03:00
James Duran fed0c2ea26 Fix Timeval for darwin and linux 2023-06-07 21:55:08 -07:00
Jon Lipstate bbafc3fbd6 harmonize to use null for c-string endings 2023-03-28 11:57:12 -07:00