aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2023-04-10vt-switchvt-switchAnna (navi) Figueiredo Gomes
Signed-off-by: Anna (navi) Figueiredo Gomes <navi@vlhl.dev>
2023-04-01noop: Additional open flags for `open(2)`Anna (navi) Figueiredo Gomes
Matching the functionallity by the seatd open call. O_NONBLOCK is specially important for libseat, otherwise it hangs while trying to drain all events from an input device fd. Signed-off-by: Anna (navi) Figueiredo Gomes <navi@vlhl.dev>
2023-04-01noop: Return seat0 as the seat nameAnna (navi) Figueiredo Gomes
wlroots' libinput backend expects the name of the seat to either match ID_SEAT from udev, or in case ID_SEAT returns nothing, match seat0. As noop has no seat switching, always returning seat0 as the session name fixes that. Signed-off-by: Anna (navi) Figueiredo Gomes <navi@vlhl.dev>
2023-03-13meson: fix seatdpath with absolute bindirAlyssa Ross
Quoting the Meson documentation: > Note that the value returned for built-in options that end in `dir` > such as `bindir` and `libdir` is usually a path relative to (and > inside) the `prefix` but you should not rely on that, as it can also > be an absolute path [in some cases](Builtin-options.md#universal-options). > [`install_dir` arguments](Installing.md) handle that as expected > but if you need an absolute path, e.g. to use in a define etc., > you should use the path concatenation operator like this: > `get_option('prefix') / get_option('localstatedir')`. > Never manually join paths as if they were strings. The concatenation of two absolute paths caused seatd-launch in Nixpkgs to try to launch e.g. /nix/store/43wyk9s2l2z8cparnshbf24d39vm5272-seatd-0.7.0//nix/store/j9a7k4qqwc3byyfmpqwg46shmh6g82yf-seatd-0.7.0-bin/bin/seatd.
2023-01-28man: add missing arg in -n syntaxSimon Ser
2023-01-16noop: initialize initial_setupChia-I Wu
Otherwise the enable_seat callback is never called.
2022-11-30man: document SEATD_VTBOUNDSimon Ser
2022-05-23seatd-launch: Avoid argv[0] in help textKenny Levinsen
2022-03-30wscons: Fix STRLENKenny Levinsen
2022-03-29seatd: refuse to compile with missing get_peer implSimon Ser
Instead of using a stub, error out when get_peer isn't implemented for the target platform. client_create relies on it.
2022-03-29seatd: handle client_create failureSimon Ser
Failure to create the client causes a null pointer dereference.
2022-03-29drm: Make dev_is_drm local to logind backendKenny Levinsen
This function is only used for logind, which is Linux-specific, but the presence in common/drm.c suggested that it had to be portable. Move it to the logind backend for now.
2022-03-29wscons: Move to its own device typeKenny Levinsen
This reduces ifdefs and avoids overloading evdev as something it is not.
2022-03-29terminal: Revert FreeBSD behavior in set_keyboardKenny Levinsen
4ad48cb305b3f847ab7d3c2d3f59c27007519c77 introduced support for NetBSD, which modified a number of our ifdefs. In that process, FreeBSD was accidentally excluded from an important code path that controls keyboard usage on the kernel console. Revert part of that change to restore FreeBSD behavior.
2022-03-28meson: library soversion arg should be stringKenny Levinsen
muon, a meson implementation in C, is more strict with its types and revealed this discrepancy between meson behavior and documentation.
2022-03-23readme: Mention NetBSDKenny Levinsen
2022-03-16ci: Add NetBSDilliliti
2022-03-16Initial netbsd supportilliliti
2022-03-16ci: Set loglevel argument to debugKenny Levinsen
2022-03-03Bump version to 0.7.0Kenny Levinsen
2022-03-03meson: Fix meson warningsKenny Levinsen
2022-03-03builtin: Remove deathsig and log start/stopKenny Levinsen
Proper handling of client disconnect mean that we no longer need deathsig handling.
2022-03-03seatd: Shut down on client disconnect in builtinKenny Levinsen
If we're part of the libseat builtin backend, then we only have one client. Shut down the server when this client disconnects.
2022-03-03builtin: Close other end of socketpair after forkKenny Levinsen
We will not get a socket hangup if we have duplicates socket fds in the parent or child, so make sure we clean this up properly after fork.
2022-03-03meson: Only set libseat defines for libseat itselfKenny Levinsen
This allows us to distinguish between when we build seatd as part of the builtin libseat backend, or when we build seatd on its own.
2022-02-26seatd: Change default log-level to infoKenny Levinsen
2022-02-26seatd: Remove runtime socket path configurationKenny Levinsen
Configurable socket paths exist mainly to facilitate multiple parallel seatd instances. However, the only valid use-case for running multiple instances of seatd is testing during development, which can just as well be done by changing SEATD_DEFAULTPATH at compile-time for test builds. Remove the command-line argument in seatd for runtime configuration of socket path, hardcode the socket path in seatd-launch, and change seatd unlink/chmod/chown code to not run when started by seatd-launch. This means that seatd-launch will now fail to start seatd if another seatd instance is already running. The unlink code still runs when seatd is started normally to assist in system crash recovery, but this may be removed later if we deem it unnecessary.
2022-02-26seatd: Handle socket unlink errorsKenny Levinsen
This ensures early failure and better error messages.
2022-02-26seatd: Command-line argument for loglevelKenny Levinsen
SEATD_LOGLEVEL was used to set the loglevel despite already having getopt in place. Remove the environment variable and make a command-line argument for it instead.
2022-02-21seatd-launch: Minor readability improvementsKenny Levinsen
2022-02-21seatd-launch: Use snprintf for socket pathKenny Levinsen
We also reduce the size of the buffer from 256 bytes to a much more reasonable 32 bytes.
2022-02-21seatd: Fix usage renderingKenny Levinsen
2022-02-21seatd-launch: Remove socket path command line argKenny Levinsen
This should not need to be configured, so remove the argument. If downstream prefers a different folder, the location can be made compile-time configurable like for seatd itself.
2022-02-21seatd-launch: Do not unlink socket pathKenny Levinsen
seatd cleans up after itself and takes care of stale sockets when applicable, so seatd-launch should not replicate this functionality.
2022-02-21seatd: Ensure socket gets unlinked on errorKenny Levinsen
2022-02-21seatd: Remove SOCK_PATH and improve cleanupKenny Levinsen
SOCK_PATH is made redundant by the -s command-line argument added in a98e0c4ce90347d37370f2debcbed8ae9678a990. Support was originally left behind for short-term compatibility, but it should be fine to remove. Previous socket cleanup is changed to run unconditionally. The cleanup now fails if the existing file is not a socket.
2022-02-15logind: Always send ping if data is queuedKenny Levinsen
sd_bus_call_method may have read and queued our ping response, so we cannot assume that a previous ping will make the socket readable. Instead, always send a ping if read or write queues are not empty, even if a ping has already been sent.
2022-02-09libseat: Use SOCK_CLOEXEC and SOCK_NONBLOCKKenny Levinsen
This both simplifies our code and fixes an exec fd leak when using builtin or noop backends.
2021-12-16readme: add irc:// linkSimon Ser
This allows users to just click the link to join the IRC channel.
2021-12-16build: use meson.override_dependencySimon Ser
This allows downstream users to write: dependency('libseat', fallback: 'seatd') instead of having to rely on the seatd/meson.build's variable name: dependency('libseat', fallback: ['seatd', 'libseat'])
2021-11-28build: don't use sh for scdocSimon Ser
Just use the built-in feed/capture Meson options instead.
2021-11-28build: use list for logind depSimon Ser
This reduces the boilerplate a bit. Use logind.name() instead of having a separate source of truth. Requires adapting the checks a bit because the dep name has a "lib" prefix.
2021-10-28build: don't use cc.get_supported_arguments for definesSimon Ser
If the compiler errors out on some -DXXX flag, then we're in trouble. Avoid using cc.get_supported_arguments for defines we require. Only use it for detecting support for warning flags.
2021-10-24seatd: don't log errno on EVENT_ERRORSimon Ser
errno won't be set when poll returns EVENT_ERROR.
2021-10-24seatd: avoid overwriting errno in set_nonblock error handlingSimon Ser
If close fails, it'll mess up errno, and log_errorf will print a non-sensical value.
2021-10-19Bump version to 0.6.3Kenny Levinsen
2021-10-05logind: Set userdata for ping_handlerKenny Levinsen
2021-09-22ci: Add logind smoketest to archKenny Levinsen
2021-09-22logind: Improve error handling in open_seatKenny Levinsen
errno was not being set by open_seat in most cases, leading to simpletest possibly failing with "libseat_open_seat() failed: Success".
2021-09-22examples/simpletest: check for libseat_dispatch failuresSimon Ser