libc.obj: implement console output via SHELL #354

Merged
Egor00f merged 8 commits from Egor00f/kolibrios:libc.obj-add-shell-console-output into main 2026-08-04 07:10:39 +00:00
Owner

Adding console I/O via the SHELL.

Demonstration of http_tcp_demo.c:

  • output
  • multithread
    • add mutex
    • multithread tests
Adding console I/O via the `SHELL`. Demonstration of [http_tcp_demo.c](https://git.kolibrios.org/KolibriOS/kolibrios/src/branch/main/programs/develop/ktcc/libc.obj/samples/http_tcp_demo.c): <video src="attachments/847d7d19-3d67-480d-80c8-6d678af61a43" title="Запись экрана от 2026-03-07 13-55-50.mp4" controls></video> - [x] output - [x] multithread - [x] add mutex - [x] multithread tests
Sweetbread left a comment
Owner

Do not use merge commits

Do not use merge commits
Egor00f force-pushed libc.obj-add-shell-console-output from 7a2ada925a to b2e4b02806 2026-03-08 13:41:02 +00:00 Compare
Author
Owner

ok, i force history without merge

ok, i force history without merge
Egor00f requested review from Sweetbread 2026-03-08 19:05:37 +00:00
mxlgv added the Lang/C
Category
Libraries
Kind
Enhancement
Priority
Low
4
labels 2026-03-11 10:26:27 +00:00
Egor00f added a new dependency 2026-03-14 18:03:54 +00:00
Egor00f removed a dependency 2026-03-14 18:24:04 +00:00
Member

@Egor00f - Please note that the file path for ktcc was recently changed with #425. This will conflict with your changes.

@Egor00f - Please note that the file path for `ktcc` was recently changed with #425. This will conflict with your changes.
Egor00f force-pushed libc.obj-add-shell-console-output from b2e4b02806 to 8a70ca5b31 2026-04-26 09:56:02 +00:00 Compare
Egor00f force-pushed libc.obj-add-shell-console-output from 8a70ca5b31 to e3acc67244 2026-04-28 18:28:44 +00:00 Compare
Egor00f force-pushed libc.obj-add-shell-console-output from e3acc67244 to a56061a99c 2026-05-17 07:21:30 +00:00 Compare
Egor00f force-pushed libc.obj-add-shell-console-output from a56061a99c to 66c05c786a 2026-05-19 14:00:55 +00:00 Compare
Egor00f force-pushed libc.obj-add-shell-console-output from 2170ffba0d to 1a9c544d42 2026-05-20 04:51:50 +00:00 Compare
Egor00f changed title from libc.obj: shell console output support to `libc.obj`: implement console output via `SHELL` 2026-06-05 14:00:55 +00:00
Egor00f force-pushed libc.obj-add-shell-console-output from 1a9c544d42 to 57c6132411 2026-06-05 14:01:09 +00:00 Compare
Egor00f requested review from Burer 2026-06-05 14:02:11 +00:00
Egor00f requested review from Doczom 2026-06-05 14:02:12 +00:00
Egor00f requested review from dunkaist 2026-06-05 14:02:12 +00:00
Egor00f requested review from mxlgv 2026-06-05 14:02:12 +00:00
@@ -74,2 +74,4 @@
}
Owner

Why?

Why?
Author
Owner

idk

idk
Egor00f marked this conversation as resolved
Owner

It's a much needed mechanism, but unfortunately the provided solution will be exclusive for C users :(

It's a much needed mechanism, but unfortunately the provided solution will be exclusive for C users :(
Author
Owner

@hidnplayr, you can use libc stdio functions in assembler if you need it.

@hidnplayr, you can use libc stdio functions in assembler if you need it.
@@ -11,1 +13,4 @@
memcpy(&pid, __shell_shm + 1, sizeof(unsigned));
}
return pid;
Owner

Не стоит ли инициализировать переменную pid, на случай если подключения к консоли всё же не будет,

Не стоит ли инициализировать переменную pid, на случай если подключения к консоли всё же не будет,
Author
Owner

Пожалуй стоит.

Пожалуй стоит.
Doczom marked this conversation as resolved
Owner

Необходимо провести тестирование изменений при многопоточном выводе в одну консоль. То есть необходима проверка и реализация, в случае если её нет, критических секций

Необходимо провести тестирование изменений при многопоточном выводе в одну консоль. То есть необходима проверка и реализация, в случае если её нет, критических секций
Egor00f force-pushed libc.obj-add-shell-console-output from 351044ccf4 to 8369828fd0 2026-06-15 14:19:21 +00:00 Compare
Egor00f force-pushed libc.obj-add-shell-console-output from 902d073347 to cad6771223 2026-06-18 08:39:55 +00:00 Compare
Egor00f force-pushed libc.obj-add-shell-console-output from cad6771223 to bb776f1aa2 2026-06-24 17:24:41 +00:00 Compare
Egor00f force-pushed libc.obj-add-shell-console-output from bb776f1aa2 to 21bb91040f 2026-06-26 09:43:18 +00:00 Compare
Egor00f added the
Status
Blocked
label 2026-07-11 09:01:42 +00:00
Egor00f force-pushed libc.obj-add-shell-console-output from 21bb91040f to 307981f3c9 2026-08-03 11:13:41 +00:00 Compare
Egor00f removed the
Status
Blocked
label 2026-08-03 13:38:18 +00:00
Doczom approved these changes 2026-08-03 15:02:26 +00:00
Egor00f added the
PR
Ready to merge
label 2026-08-03 19:07:48 +00:00
Egor00f added 8 commits 2026-08-03 19:08:00 +00:00
make it faster
add multithread support.
Test PR / Build (es_ES) (pull_request) Successful in 2m5s
Test PR / Build (ru_RU) (pull_request) Successful in 2m8s
Test PR / Build (en_US) (pull_request) Successful in 2m11s
58bfd90b73
mutex from #338
fix `fwrite`:  use `bytes_count` instead of `size`
Egor00f force-pushed libc.obj-add-shell-console-output from 615d65d28c to 58bfd90b73 2026-08-03 19:08:00 +00:00 Compare
Leency approved these changes 2026-08-03 19:46:27 +00:00
Egor00f merged commit 76294451d2 into main 2026-08-04 07:10:39 +00:00
Egor00f deleted branch libc.obj-add-shell-console-output 2026-08-04 07:10:40 +00:00
Sign in to join this conversation.
6 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: KolibriOS/kolibrios#354