forked from sizeofvoid/libinput
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
71 lines (53 loc) · 1.62 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
# $OpenBSD$
INSTALL_DATA= /usr/bin/install -c -m 644
PACKAGE_VERSION= 1.21.0
NOPROFILE=
LIB= input
PREFIX= /usr/local
INCSDIR= ${PREFIX}/include
LIBDIR= ${PREFIX}/lib
CPPFLAGS+= -I${.CURDIR} \
-I${.CURDIR}/include \
-I${.CURDIR}/include/linux
CFLAGS= -fvisibility=hidden -O0 -g
INCS= libinput.h
SRCS= libinput.c libinput-util.c wscons.c wskbdmap.c
PKGCONFIG= libinput.pc
LINUX_INCS= input.h \
input-event-codes.h \
freebsd/input.h
includes: _SUBDIRUSE
cd ${.CURDIR}; for i in ${INCS}; do \
j="cmp -s $$i ${DESTDIR}${INCSDIR}/$$i || \
${INSTALL_DATA} $$i ${DESTDIR}${INCSDIR}/"; \
echo "\tinstalling $$i"; \
eval "$$j"; \
done
@test -d ${DESTDIR}${INCSDIR}/linux || \
mkdir ${DESTDIR}${INCSDIR}/linux
cd ${.CURDIR}/include/linux; for i in ${LINUX_INCS}; do \
j="cmp -s $$i ${DESTDIR}${INCSDIR}/linux/$$i || \
${INSTALL_DATA} $$i ${DESTDIR}${INCSDIR}/linux/"; \
echo "\tinstalling $$i"; \
eval "$$j"; \
done
# pkgconfig
PKGCONFIG = libinput.pc
all: ${PKGCONFIG}
CLEANFILES += ${PKGCONFIG}
${PKGCONFIG}: ${PKGCONFIG}.in Makefile
@echo "Creating ${PKGCONFIG}"
@sed -e 's#@prefix@#${PREFIX}#g' \
-e 's#@datarootdir@#$${prefix}/share#g' \
-e 's#@datadir@#$${datarootdir}#g' \
-e 's#@exec_prefix@#$${prefix}#g' \
-e 's#@libdir@#$${exec_prefix}/lib#g' \
-e 's#@includedir@#$${prefix}/include#g' \
-e 's#@PACKAGE_VERSION@#'${PACKAGE_VERSION}'#g' \
${EXTRA_PKGCONFIG_SUBST} \
< ${.CURDIR}/${PKGCONFIG}.in > $@
install-pc: ${PKGCONFIG}
${INSTALL_DATA} ${PKGCONFIG} ${DESTDIR}${LIBDIR}/pkgconfig
realinstall: install-pc
.include <bsd.obj.mk>
.include <bsd.lib.mk>