mirror of
https://gitlab.freedesktop.org/wlroots/wlr-protocols.git
synced 2025-12-20 16:10:05 +01:00
Add Makefile and pkg-config entry
This commit is contained in:
parent
77ee60a6e9
commit
723f9c03a2
3 changed files with 48 additions and 4 deletions
38
Makefile
Normal file
38
Makefile
Normal file
|
|
@ -0,0 +1,38 @@
|
||||||
|
PREFIX=/usr
|
||||||
|
DATADIR=$${datarootdir}
|
||||||
|
DATAROOTDIR=$${prefix}/share
|
||||||
|
|
||||||
|
unstable_protocols = \
|
||||||
|
unstable/wlr-export-dmabuf-unstable-v1.xml \
|
||||||
|
unstable/wlr-gamma-control-unstable-v1.xml \
|
||||||
|
unstable/wlr-input-inhibitor-unstable-v1.xml \
|
||||||
|
unstable/wlr-layer-shell-unstable-v1.xml \
|
||||||
|
unstable/wlr-screencopy-unstable-v1.xml
|
||||||
|
|
||||||
|
check:
|
||||||
|
./check.sh
|
||||||
|
|
||||||
|
clean:
|
||||||
|
rm -f wlr-protocols.pc
|
||||||
|
|
||||||
|
wlr-protocols.pc: wlr-protocols.pc.in
|
||||||
|
sed \
|
||||||
|
-e 's:@prefix@:$(PREFIX):g' \
|
||||||
|
-e 's:@datadir@:$(DATADIR):g' \
|
||||||
|
-e 's:@datarootdir@:$(DATAROOTDIR):g' \
|
||||||
|
<$< >$@
|
||||||
|
|
||||||
|
install-unstable: $(unstable_protocols)
|
||||||
|
mkdir -p $(DESTDIR)$(PREFIX)/share/wlr-protocols/unstable
|
||||||
|
for protocol in $^ ; \
|
||||||
|
do \
|
||||||
|
install -Dm644 $$protocol \
|
||||||
|
$(DESTDIR)$(PREFIX)/share/wlr-protocols/$$protocol ; \
|
||||||
|
done
|
||||||
|
|
||||||
|
install-pc: wlr-protocols.pc
|
||||||
|
mkdir -p $(DESTDIR)$(PREFIX)/share/pkgconfig/
|
||||||
|
install -Dm644 wlr-protocols.pc \
|
||||||
|
$(DESTDIR)$(PREFIX)/share/pkgconfig/wlr-protocols.pc
|
||||||
|
|
||||||
|
install: install-unstable install-pc
|
||||||
7
check.sh
7
check.sh
|
|
@ -1,8 +1,7 @@
|
||||||
#!/bin/sh
|
#!/bin/sh -eux
|
||||||
|
|
||||||
set -e
|
for f in $(echo unstable/*.xml)
|
||||||
|
do
|
||||||
for f in $(echo unstable/*.xml); do
|
|
||||||
wayland-scanner -s client-header "$f" /dev/null
|
wayland-scanner -s client-header "$f" /dev/null
|
||||||
wayland-scanner -s server-header "$f" /dev/null
|
wayland-scanner -s server-header "$f" /dev/null
|
||||||
wayland-scanner -s public-code "$f" /dev/null
|
wayland-scanner -s public-code "$f" /dev/null
|
||||||
|
|
|
||||||
7
wlr-protocols.pc.in
Normal file
7
wlr-protocols.pc.in
Normal file
|
|
@ -0,0 +1,7 @@
|
||||||
|
prefix=@prefix@
|
||||||
|
datarootdir=@datarootdir@
|
||||||
|
pkgdatadir=${pc_sysrootdir}@datadir@/wlr-protocols
|
||||||
|
|
||||||
|
Name: wlroots Wayland protocols
|
||||||
|
Description: Wayland protocol files
|
||||||
|
Version: 1.0
|
||||||
Loading…
Add table
Reference in a new issue