Commit Graph

13 Commits

Author SHA1 Message Date
Jonas 'Sortie' Termansen 3c43f71084 Implement file descriptor passing.
This change refactors the Unix socket / pipe backend to have a ring buffer
containing segments, where each segment has an optional leading ancillary
buffer containing control messages followed by a normal data buffer.

The SCM_RIGHTS control message has been implemented which transfers file
descriptors to the receiving process. File descriptors are reference counted
and cycles are prevented using the following restrictions:

1) Unix sockets cannot be sent on themselves (on either end).
2) Unix sockets themselves being sent cannot be sent on.
3) Unix sockets cannot send a Unix socket being sent on.

This is a compatible ABI change.
2021-12-31 22:24:11 +01:00
Jonas 'Sortie' Termansen 5e7605fad2 Implement threading primitives that truly sleep.
The idle thread is now actually run when the system is idle because it
truly goes idle. The idle thread is made power efficient by using the hlt
instruction rather than a busy loop.

The new futex(2) system call is used to implement fast user-space mutexes,
condition variables, and semaphores. The same backend and design is used as
kutexes for truly sleeping kernel mutexes and condition variables.

The new exit_thread(2) flag EXIT_THREAD_FUTEX_WAKE wakes a futex.

Sleeping on clocks in the kernel now uses timers for true sleep.

The interrupt worker thread now truly sleeps when idle.

Kernel threads are now named.

This is a compatible ABI change.
2021-06-23 22:10:47 +02:00
Jonas 'Sortie' Termansen cb590ff205 Fix system upgrade leaking files. 2021-01-19 00:04:56 +01:00
Jonas 'Sortie' Termansen 29598b4fde Fix /tix/manifest permissions in installations. 2021-01-17 23:14:54 +01:00
Jonas 'Sortie' Termansen 5f84c38bc8 Fix sysinstall hook markers not being installed and prefix logic.
Document the compatibility hooks behavior while here.
2021-01-17 23:14:52 +01:00
Jonas 'Sortie' Termansen 7df3f9308a The man program in the mdocml port can now handle non-installed manuals. 2017-12-04 23:56:47 +01:00
Jonas 'Sortie' Termansen 723f8e964c Fix date format in manual pages. 2017-07-02 22:07:39 +02:00
Nicholas De Nova d217621649 Correct manpage spacing per roff(7) convention.
roff(7) dictates that "Each sentence should terminate at the end of an
input line." Instead of doing this, Sortix manpages (incorrectly) used
double-spaces to separate sentences.

Additionally, fix a few small typos.
2017-02-16 14:42:28 -06:00
Jonas 'Sortie' Termansen 4b2cf28bbf Add socket(2).
This removes the /dev/net socket interface.

This is an incompatible ABI change.
2017-02-14 20:43:31 +01:00
Jonas 'Sortie' Termansen 442b139cc3 Fix following-development(7) typos. 2016-12-28 23:08:29 +01:00
Jonas 'Sortie' Termansen 9bbdb791af Add split packages and cross-bootstrapping support to tix-build(8).
pkg.use-bootstrap can now be set to true to add a bootstrap phase to
cross-builds. I.e. the package is built for the native platform and
installed to a temporary location, which is in the PATH during the
actual cross-compilation. This feature is useful for some misbehaving
ports that can cross-compile, but require the exact same version of the
software installed locally. The bootstrap build is controlled with the
bootstrap.foo variables rather than the normal pkg.foo variables.

pkg.source-package can now be set to the name of another package, whose
source code is built using the current tixbuildinfo. This feature allows
providing multiple packages using the same source code package. By
default, the source code of the source package is assumed to be in
../${pkg.source-package}, but this can be overridden with the option
--source-directory.

pkg.alias-of can now be set to the name of another package to specify
that this package is an alias of the other package, creating an empty
binary package depending on the real package.

pkg.subdir support has been fixed in the clean and post-install phases.

pkg-config support has been improved and PKG_CONFIG is now set to
$HOST-pkg-config and PKG_CONFIG_FOR_BUILD is set to pkg-config.

tix-build has been refactored as needed and generally cleaned up. Error
handling, such as on allocations, have been added in a lot of cases. The
support for FOO_FOR_BUILD variables have been unified and simplified.
Appending to PATH now correctly handles the empty PATH.
2016-12-27 23:14:00 +01:00
Dennis Wölfing 1b3dcad03c Add German keyboard layout. 2016-11-14 20:35:54 +01:00
Jonas 'Sortie' Termansen 5585303365 Add following-development(7). 2016-11-05 23:39:26 +01:00