Commit Graph

753 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
3a13c598e2 Merge pull request #4733 from laytan/get-executable-path
os/os2: add get_executable_path and get_executable_directory
2025-01-24 13:09:10 +00:00
gingerBill
13a2a29b90 Merge pull request #4730 from laytan/os2-linux-loop-writes-and-cap-rw
os/os2: bring Linux to other impls standards by looping writes and maxing one shot RW sizes
2025-01-24 13:03:29 +00:00
Laytan Laats
d54de6704a os/os2: use proc_pidpath for executable path on darwin 2025-01-22 18:40:06 +01:00
Laytan Laats
f1b0b19710 os/os2: get_executable_path and working directory on wasi 2025-01-21 19:14:15 +01:00
Laytan Laats
b673642412 os/os2: add get_executable_path and get_executable_directory 2025-01-21 18:54:45 +01:00
gingerBill
223970671f Merge pull request #4716 from laytan/os2-wasi
os/os2: wasi target support
2025-01-21 13:08:04 +00:00
Laytan
68653081be Merge pull request #4732 from zen3ger/os2-process-incorrect-working-dir
os/os2: Properly update CWD on Linux when using _process_start()
2025-01-21 00:07:32 +01:00
Roland Kovacs
f6ead2e777 os/os2: Linux _process_start() write back error on fchdir failure 2025-01-20 23:31:13 +01:00
Roland Kovacs
ac30d36206 os/os2: Properly update CWD on Linux when using _process_start()
The `dir_fd` argument to `execveat()` is not for setting the current working
directory. It is used to resolve relative executable paths, hence explicit
`chdir/fchdir` call is required to set CWD.
2025-01-20 22:34:49 +01:00
Laytan Laats
bf58107402 os/os2: bring Linux to other impls standards by looping writes and maxing one shot RW sizes 2025-01-20 20:15:03 +01:00
jason
27998e0d21 os2/heap_linux point to runtime._heap_allocator_proc 2025-01-19 06:05:55 -05:00
Laytan Laats
e4892f1bb2 os/os2: wasi target support 2025-01-18 22:23:44 +01:00
jason
fa7ef28acf Implement _read_directory_iterator in os2.
Also, fix minor bug in linux.dirent_name.
2025-01-10 20:54:09 -05:00
Laytan
cd93e2f6f8 Merge pull request #4672 from shizeeg/master
add os.exists() to FreeBSD
2025-01-11 01:03:36 +01:00
avanspector
c686728184 Update dir_unix.odin 2025-01-10 07:15:44 +01:00
avanspector
0a985f5d02 Haiku: small fixes across core 2025-01-10 07:07:40 +01:00
sh!zeeg
509da8e632 add os.exists() to FreeBSD 2025-01-10 05:56:56 +03:00
avanspector
be7799459b Merge branch 'odin-lang:master' into master 2025-01-06 16:42:29 +04:00
gingerBill
4d63ee0794 Remove unused import 2025-01-05 12:55:35 +00:00
gingerBill
1bf33fe373 Use static global memory for std handles instead of allocating. 2025-01-05 12:53:20 +00:00
jason
074bef7baf Fix sys/linux 64 bit arguments on 32 bit systems
Reverese return values of compat64_arg_pair
Add register alignment to specific arm32 system calls
2025-01-02 14:50:45 -05:00
jason
ce1f3b34c0 Minor fixes + cleanup in os2 and sys/linux
Add NOFOLLOW to os2.remove
Change Dev from int to u64 and make relavant casts
Fix compat64_arg_pair
2025-01-02 11:03:24 -05:00
gingerBill
1cf7a56ba7 General clean up of code 2025-01-01 15:13:46 +00:00
avanspector
a20d85df1e Fix os_haiku.odin (again) 2024-12-21 17:15:53 +01:00
avanspector
5376d2a20b fix haiku 2024-12-20 17:19:04 +01:00
jason
b73275cf42 Get arm64 up to speed in os2 linux
Readded open flags for arm64 to sys/linux/bits.odin. Make process_start
name based instead of descriptor based to allow running of scripts. Fix
bug in heap_linux. Fix and simplify os2.remove.
2024-12-19 17:12:07 -05:00
Laytan Laats
6e1d028861 fix #4389 - retrieve file type by opening if other methods failed 2024-12-06 23:51:14 +01:00
Jeroen van Rijn
8581240ece Make O_RDONLY default for os.open on all platforms.
And also moved Windows file procs to `os_windows.odin`, in line with all the other platforms who didn't have a dedicated `file_<platform>.odin`
2024-11-28 15:57:48 +01:00
Laytan Laats
282d956aa7 os2: skip dir test when unsupported 2024-11-15 21:56:55 +01:00
Laytan Laats
de9d0134e4 os2: fix file type detection in dir_windows 2024-11-15 21:08:14 +01:00
Laytan Laats
b3c2f5cb12 os2: fix leak in dir_windows 2024-11-15 20:47:34 +01:00
gingerBill
aa36ae01cf Fix #4406 os2 to not close the std file handles but rather just free the memory for the ^File data. 2024-11-04 11:55:29 +00: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
Patric Dexheimer
b6599a52b5 Update process_windows.odin
Mistype
2024-10-27 23:27:18 -03: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
Laytan Laats
6bf70b60d6 os/os2: add default permissions to write_entire_file 2024-10-07 22:31:43 +02:00
Laytan Laats
4b8462aa70 os/os2: fix mkdir_all on posix with abs path 2024-10-07 22:11:16 +02:00
Laytan Laats
c21e62ddb4 reset n before stderr path too 2024-10-05 11:26:23 +02:00
flysand7
f61996fd6f Don't append to buffer if nothing was read 2024-10-05 11:06:36 +11:00
Laytan
b5f7332ffb Merge pull request #4272 from flysand7/os2-noquote
[os2/process]: Don't quote arguments unless needed
2024-10-04 23:12:07 +02:00
flysand7
dad418cf91 Remove unused things 2024-10-05 07:23:15 +11:00
Laytan
54ffd6df06 better error handling 2024-10-04 15:08:21 +02:00
Laytan
a3c3e5c822 reset err 2024-10-04 14:53:16 +02:00
Laytan
cf705d4b29 wait instead of kill 2024-10-04 14:50:26 +02:00
Laytan
861efa4e54 Revert "add some debug logs"
This reverts commit 31ee829b44.
2024-10-04 13:58:59 +02:00
Laytan
59086a24a1 add .ENOSYS == .Unsupported for posix too 2024-10-04 13:52:54 +02:00