mirror of
https://gitlab.freedesktop.org/wayland/wayland.git
synced 2025-11-22 06:59:46 -05:00
Use automake
This commit is contained in:
parent
49291497d3
commit
f0152daad7
17 changed files with 138 additions and 190 deletions
|
|
@ -1,61 +0,0 @@
|
|||
include ../config.mk
|
||||
|
||||
libs = libwayland-server.so libwayland-client.so
|
||||
|
||||
all : $(libs) scanner
|
||||
|
||||
headers = \
|
||||
wayland-util.h \
|
||||
wayland-server-protocol.h \
|
||||
wayland-server.h \
|
||||
wayland-client-protocol.h \
|
||||
wayland-client.h \
|
||||
|
||||
libwayland-server.so : \
|
||||
wayland-protocol.o \
|
||||
wayland-server.o \
|
||||
event-loop.o \
|
||||
connection.o \
|
||||
wayland-util.o \
|
||||
wayland-hash.o
|
||||
|
||||
libwayland-client.so : \
|
||||
wayland-protocol.o \
|
||||
wayland-client.o \
|
||||
connection.o \
|
||||
wayland-util.o \
|
||||
wayland-hash.o
|
||||
|
||||
wayland-server.o : wayland-server-protocol.h
|
||||
wayland-client.o : wayland-client-protocol.h
|
||||
|
||||
wayland-protocol.c : protocol.xml scanner
|
||||
./scanner code < $< > $@
|
||||
|
||||
wayland-server-protocol.h : protocol.xml scanner
|
||||
./scanner server-header < $< > $@
|
||||
|
||||
wayland-client-protocol.h : protocol.xml scanner
|
||||
./scanner client-header < $< > $@
|
||||
|
||||
$(libs) : CFLAGS += -fPIC $(FFI_CFLAGS)
|
||||
$(libs) : LDLIBS += $(FFI_LIBS)
|
||||
$(libs) :
|
||||
gcc -shared $^ $(LDLIBS) -o $@
|
||||
|
||||
scanner : \
|
||||
scanner.o \
|
||||
wayland-util.o
|
||||
|
||||
scanner : LDLIBS += $(EXPAT_LIBS)
|
||||
|
||||
install : $(libs)
|
||||
install -d $(libdir) $(includedir) $(libdir)/pkgconfig
|
||||
install wayland-server.pc wayland-client.pc $(libdir)/pkgconfig
|
||||
install $(libs) $(libdir)
|
||||
install $(headers) $(includedir)
|
||||
|
||||
clean :
|
||||
rm -f scanner *.o *.so .*.deps
|
||||
rm -f wayland-protocol.c \
|
||||
wayland-server-protocol.h wayland-client-protocol.h
|
||||
50
wayland/Makefile.am
Normal file
50
wayland/Makefile.am
Normal file
|
|
@ -0,0 +1,50 @@
|
|||
lib_LTLIBRARIES = libwayland-server.la libwayland-client.la
|
||||
noinst_LTLIBRARIES = libwayland-util.la
|
||||
|
||||
include_HEADERS = \
|
||||
wayland-util.h \
|
||||
wayland-server-protocol.h \
|
||||
wayland-server.h \
|
||||
wayland-client-protocol.h \
|
||||
wayland-client.h
|
||||
|
||||
libwayland_util_la_SOURCES = \
|
||||
connection.c \
|
||||
connection.h \
|
||||
wayland-util.c \
|
||||
wayland-util.h \
|
||||
wayland-hash.c
|
||||
|
||||
libwayland_server_la_LIBADD = $(FFI_LIBS) libwayland-util.la
|
||||
libwayland_server_la_SOURCES = \
|
||||
wayland-protocol.c \
|
||||
wayland-server.c \
|
||||
event-loop.c
|
||||
|
||||
libwayland_client_la_LIBADD = $(FFI_LIBS) libwayland-util.la
|
||||
libwayland_client_la_SOURCES = \
|
||||
wayland-protocol.c \
|
||||
wayland-client.c
|
||||
|
||||
INCLUDES = $(FFI_CFLAGS)
|
||||
|
||||
include $(top_srcdir)/wayland/scanner.mk
|
||||
|
||||
noinst_PROGRAMS = scanner
|
||||
|
||||
scanner_SOURCES = \
|
||||
scanner.c
|
||||
|
||||
scanner_LDADD = $(EXPAT_LIBS) libwayland-util.la
|
||||
|
||||
$(BUILT_SOURCES) : scanner
|
||||
|
||||
BUILT_SOURCES = \
|
||||
wayland-server-protocol.h \
|
||||
wayland-client-protocol.h \
|
||||
wayland-protocol.c
|
||||
|
||||
CLEANFILES = $(BUILT_SOURCES)
|
||||
|
||||
foo :
|
||||
echo $(top_builddir)
|
||||
|
|
@ -1,278 +0,0 @@
|
|||
<protocol name="wayland">
|
||||
|
||||
<interface name="display" version="1">
|
||||
<request name="sync">
|
||||
<arg name="key" type="uint"/>
|
||||
</request>
|
||||
|
||||
<request name="frame">
|
||||
<arg name="key" type="uint"/>
|
||||
</request>
|
||||
|
||||
<event name="invalid_object">
|
||||
<arg name="object_id" type="uint"/>
|
||||
</event>
|
||||
|
||||
<event name="invalid_method">
|
||||
<arg name="object_id" type="uint"/>
|
||||
<arg name="opcode" type="uint"/>
|
||||
</event>
|
||||
|
||||
<event name="no_memory"/>
|
||||
|
||||
<event name="global">
|
||||
<arg name="id" type="new_id" interface="object"/>
|
||||
<arg name="name" type="string"/>
|
||||
<arg name="version" type="uint"/>
|
||||
</event>
|
||||
|
||||
<event name="range">
|
||||
<arg name="base" type="uint"/>
|
||||
</event>
|
||||
|
||||
<event name="sync">
|
||||
<arg name="key" type="uint"/>
|
||||
</event>
|
||||
|
||||
<event name="frame">
|
||||
<arg name="key" type="uint"/>
|
||||
<arg name="time" type="uint"/>
|
||||
</event>
|
||||
</interface>
|
||||
|
||||
<interface name="compositor" version="1">
|
||||
<request name="create_surface">
|
||||
<arg name="id" type="new_id" interface="surface"/>
|
||||
</request>
|
||||
</interface>
|
||||
|
||||
<interface name="drm" version="1">
|
||||
<!-- dri2 auth and create buffer -->
|
||||
<request name="authenticate">
|
||||
<arg name="id" type="uint"/>
|
||||
</request>
|
||||
|
||||
<request name="create_buffer">
|
||||
<arg name="id" type="new_id" interface="buffer"/>
|
||||
<arg name="name" type="uint"/>
|
||||
<arg name="width" type="int"/>
|
||||
<arg name="height" type="int"/>
|
||||
<arg name="stride" type="uint"/>
|
||||
<arg name="visual" type="object" interface="visual"/>
|
||||
</request>
|
||||
|
||||
<event name="device">
|
||||
<arg name="name" type="string"/>
|
||||
</event>
|
||||
|
||||
<event name="authenticated"/>
|
||||
</interface>
|
||||
|
||||
<interface name="shm" version="1">
|
||||
<request name="create_buffer">
|
||||
<arg name="id" type="new_id" interface="buffer"/>
|
||||
<arg name="fd" type="fd"/>
|
||||
<arg name="width" type="int"/>
|
||||
<arg name="height" type="int"/>
|
||||
<arg name="stride" type="uint"/>
|
||||
<arg name="visual" type="object" interface="visual"/>
|
||||
</request>
|
||||
</interface>
|
||||
|
||||
<interface name="buffer" version="1">
|
||||
<request name="destroy" type="destructor"/>
|
||||
</interface>
|
||||
|
||||
<interface name="shell" version="1">
|
||||
<request name="move">
|
||||
<arg name="surface" type="object" interface="surface"/>
|
||||
<arg name="input_device" type="object" interface="input_device"/>
|
||||
<arg name="time" type="uint"/>
|
||||
</request>
|
||||
|
||||
<request name="resize">
|
||||
<arg name="surface" type="object" interface="surface"/>
|
||||
<arg name="input_device" type="object" interface="input_device"/>
|
||||
<arg name="time" type="uint"/>
|
||||
<!-- edges is an enum, need to get the values in here -->
|
||||
<arg name="edges" type="uint"/>
|
||||
</request>
|
||||
|
||||
<request name="create_drag">
|
||||
<arg name="id" type="new_id" interface="drag"/>
|
||||
</request>
|
||||
|
||||
<event name="configure">
|
||||
<arg name="time" type="uint"/>
|
||||
<!-- Same as edges except also move (16) -->
|
||||
<arg name="type" type="uint"/>
|
||||
<arg name="surface" type="object" interface="surface"/>
|
||||
<arg name="x" type="int"/>
|
||||
<arg name="y" type="int"/>
|
||||
<arg name="width" type="int"/>
|
||||
<arg name="height" type="int"/>
|
||||
</event>
|
||||
</interface>
|
||||
|
||||
<interface name="drag" version="1">
|
||||
<!-- Add an offered mime type. Can be called several times to
|
||||
offer multiple types, but must be called before 'activate'. -->
|
||||
<request name="offer">
|
||||
<arg name="type" type="string"/>
|
||||
</request>
|
||||
|
||||
<request name="activate">
|
||||
<arg name="surface" type="object" interface="surface"/>
|
||||
<arg name="input_device" type="object" interface="input_device"/>
|
||||
<arg name="time" type="uint"/>
|
||||
</request>
|
||||
|
||||
<!-- Destroy the drag and cancel the session. -->
|
||||
<request name="destroy" type="destructor"/>
|
||||
|
||||
<!-- Sent when a target accepts pointer_focus or motion events.
|
||||
If a target does not accept any of the offered types, type is
|
||||
NULL -->
|
||||
<event name="target">
|
||||
<arg name="mime_type" type="string"/>
|
||||
</event>
|
||||
|
||||
<!-- Sent when the drag is finished. The final mime type is that
|
||||
of the last target event. If that was NULL, no drag target
|
||||
was valid when the drag finished, fd is undefined and the
|
||||
source should not send data. The event is also sent in case
|
||||
a drag source tries to activate a drag after the grab was
|
||||
released, in which case mime_type will also be NULL. -->
|
||||
<event name="finish">
|
||||
<arg name="fd" type="fd"/>
|
||||
</event>
|
||||
</interface>
|
||||
|
||||
|
||||
<interface name="drag_offer" version="1">
|
||||
<!-- Call to accept the offer of the given type -->
|
||||
<request name="accept">
|
||||
<arg name="time" type="uint"/>
|
||||
<arg name="type" type="string"/>
|
||||
</request>
|
||||
|
||||
<!-- Called to initiate the drag finish sequence. Sends the pipe
|
||||
fd to the compositor, which forwards it to the source in the
|
||||
'finish' event -->
|
||||
<request name="receive">
|
||||
<arg name="fd" type="fd"/>
|
||||
</request>
|
||||
|
||||
<!-- Sent before the pointer_focus event to announce the types
|
||||
offered. One event per offered mime type. -->
|
||||
<event name="offer">
|
||||
<arg name="type" type="string"/>
|
||||
</event>
|
||||
|
||||
<!-- Similar to device::pointer_focus. Sent to potential target
|
||||
surfaces to offer drag data. If the device leaves the
|
||||
window, the drag stops or the originator cancels the drag,
|
||||
this event is sent with the NULL surface, at which point the
|
||||
drag object may no longer be valid. -->
|
||||
<event name="pointer_focus">
|
||||
<arg name="time" type="uint"/>
|
||||
<arg name="surface" type="object" interface="surface"/>
|
||||
<arg name="x" type="int"/>
|
||||
<arg name="y" type="int"/>
|
||||
<arg name="surface_x" type="int"/>
|
||||
<arg name="surface_y" type="int"/>
|
||||
</event>
|
||||
|
||||
<!-- Similar to device::motion. Sent to potential target surfaces
|
||||
as the drag pointer moves around in the surface. -->
|
||||
<event name="motion">
|
||||
<arg name="time" type="uint"/>
|
||||
<arg name="x" type="int"/>
|
||||
<arg name="y" type="int"/>
|
||||
<arg name="surface_x" type="int"/>
|
||||
<arg name="surface_y" type="int"/>
|
||||
</event>
|
||||
|
||||
<!-- Sent to indicate that the drag is finishing. The last
|
||||
motion/pointer_focus event gives the location of the drop.
|
||||
Target must respond with the 'receive' request, which sends
|
||||
an fd to the source for writing the drag data. -->
|
||||
<event name="drop"/>
|
||||
</interface>
|
||||
|
||||
<interface name="surface" version="1">
|
||||
<request name="destroy" type="destructor"/>
|
||||
|
||||
<request name="attach">
|
||||
<arg name="buffer" type="object" interface="buffer"/>
|
||||
</request>
|
||||
|
||||
<request name="map">
|
||||
<arg name="x" type="int"/>
|
||||
<arg name="y" type="int"/>
|
||||
<arg name="width" type="int"/>
|
||||
<arg name="height" type="int"/>
|
||||
</request>
|
||||
|
||||
<request name="damage">
|
||||
<arg name="x" type="int"/>
|
||||
<arg name="y" type="int"/>
|
||||
<arg name="width" type="int"/>
|
||||
<arg name="height" type="int"/>
|
||||
</request>
|
||||
</interface>
|
||||
|
||||
<interface name="input_device" version="1">
|
||||
<request name="attach">
|
||||
<arg name="time" type="uint"/>
|
||||
<arg name="buffer" type="object" interface="buffer"/>
|
||||
<arg name="hotspot_x" type="int"/>
|
||||
<arg name="hotspot_y" type="int"/>
|
||||
</request>
|
||||
|
||||
<event name="motion">
|
||||
<arg name="time" type="uint"/>
|
||||
<arg name="x" type="int"/>
|
||||
<arg name="y" type="int"/>
|
||||
<arg name="surface_x" type="int"/>
|
||||
<arg name="surface_y" type="int"/>
|
||||
</event>
|
||||
|
||||
<event name="button">
|
||||
<arg name="time" type="uint"/>
|
||||
<arg name="button" type="uint"/>
|
||||
<arg name="state" type="uint"/>
|
||||
</event>
|
||||
|
||||
<event name="key">
|
||||
<arg name="time" type="uint"/>
|
||||
<arg name="key" type="uint"/>
|
||||
<arg name="state" type="uint"/>
|
||||
</event>
|
||||
|
||||
<event name="pointer_focus">
|
||||
<arg name="time" type="uint"/>
|
||||
<arg name="surface" type="object" interface="surface"/>
|
||||
<arg name="x" type="int"/>
|
||||
<arg name="y" type="int"/>
|
||||
<arg name="surface_x" type="int"/>
|
||||
<arg name="surface_y" type="int"/>
|
||||
</event>
|
||||
|
||||
<event name="keyboard_focus">
|
||||
<arg name="time" type="uint"/>
|
||||
<arg name="surface" type="object" interface="surface"/>
|
||||
<arg name="keys" type="array"/>
|
||||
</event>
|
||||
</interface>
|
||||
|
||||
<interface name="output" version="1">
|
||||
<event name="geometry">
|
||||
<arg name="width" type="int"/>
|
||||
<arg name="height" type="int"/>
|
||||
</event>
|
||||
</interface>
|
||||
|
||||
<interface name="visual" version="1">
|
||||
|
||||
</protocol>
|
||||
8
wayland/scanner.mk
Normal file
8
wayland/scanner.mk
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
%-protocol.c : $(top_srcdir)/protocol/%.xml
|
||||
$(top_builddir)/wayland/scanner code < $< > $@
|
||||
|
||||
%-server-protocol.h : $(top_srcdir)/protocol/%.xml
|
||||
$(top_builddir)/wayland/scanner server-header < $< > $@
|
||||
|
||||
%-client-protocol.h : $(top_srcdir)/protocol/%.xml
|
||||
$(top_builddir)/wayland/scanner client-header < $< > $@
|
||||
Loading…
Add table
Add a link
Reference in a new issue