mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-11-02 09:01:38 -05:00
This gets wlroots to build, but the transitive closure of files depending on wlr_surface.c is actually pretty large. As more interfaces are changed to use the new compositor design, their build definitions will be uncommented. This also includes a very basic test client/server, but this will be removed later.
29 lines
594 B
C
29 lines
594 B
C
#include <signal.h>
|
|
#include <wayland-server.h>
|
|
|
|
#include <wlr/types/wlr_compositor.h>
|
|
#include <wlr/types/wlr_subcompositor.h>
|
|
|
|
struct wl_display *display;
|
|
|
|
static void sigint(int signo)
|
|
{
|
|
wl_display_terminate(display);
|
|
}
|
|
|
|
int main(void)
|
|
{
|
|
display = wl_display_create();
|
|
wl_display_add_socket(display, "test");
|
|
|
|
signal(SIGINT, sigint);
|
|
|
|
struct wlr_compositor *comp = wlr_compositor_create(display, NULL);
|
|
struct wlr_subcompositor *subcomp = wlr_subcompositor_create(comp);
|
|
|
|
(void)subcomp;
|
|
wl_display_run(display);
|
|
|
|
wl_display_destroy_clients(display);
|
|
wl_display_destroy(display);
|
|
}
|