compat.libseat
#includelibseat 0.9.3 — session and device handover for compositors, with the seatd and builtin backends
#include <libseat.h>
mcpp add compat.libseat@0.9.3
用法
來自本倉庫自己的測試專案 —— CI 真的編譯並執行過,不是為了網站寫的。
// compat.libseat — link and entry-point test.
//
// WHAT THIS CANNOT DO, and why that is not a gap. Opening a seat needs either
// a running seatd daemon (SEATD_SOCK) or the privileges to BE the seat manager
// — a CI runner has neither, and a compositor's own failure to open a seat is
// an environment problem rather than a packaging one. So what is asserted is
// that the library is complete and its entry points resolve.
//
// `#include <libseat.h>` INSIDE `extern "C"`, and that is not boilerplate:
// upstream's header carries no `extern "C"` guard of its own (measured — zero
// occurrences in include/libseat.h). Included plainly from C++ every
// declaration gets C++ linkage and every call fails to link with a mangled
// name. Any C++ consumer has to do this; it is worth having in the test so the
// requirement is visible rather than discovered.
#ifdef __linux__
extern "C" {
#include <libseat.h>
}
#include <cstdio>
// …
tests/examples/libseat/tests/libseat.cpp · 專案 tests/examples/libseat
建置
- targets
seat (lib)- language
c++23- C standard
c11- import std
- no
- include dirs
*, */include
原始檔 (15)
*/libseat/libseat.c*/libseat/backend/noop.c*/libseat/backend/seatd.c*/common/connection.c*/common/linked_list.c*/common/log.c*/common/terminal.c*/common/evdev.c*/common/hidraw.c*/common/drm.c*/seatd/poller.c*/seatd/seat.c*/seatd/client.c*/seatd/server.c*/common/wscons.c