1*edff4923SAndrew GeisslerSUMMARY = "An abstraction layer for touchscreen panel events"
2*edff4923SAndrew GeisslerDESCRIPTION = "Tslib is an abstraction layer for touchscreen panel \
3*edff4923SAndrew Geisslerevents, as well as a filter stack for the manipulation of those events. \
4*edff4923SAndrew GeisslerTslib is generally used on embedded devices to provide a common user \
5*edff4923SAndrew Geisslerspace interface to touchscreen functionality."
6*edff4923SAndrew GeisslerHOMEPAGE = "http://tslib.org/"
7*edff4923SAndrew Geissler
8*edff4923SAndrew GeisslerSECTION = "base"
9*edff4923SAndrew GeisslerLICENSE = "LGPL-2.0-or-later & GPL-2.0-or-later"
10*edff4923SAndrew GeisslerLIC_FILES_CHKSUM = "\
11*edff4923SAndrew Geissler    file://COPYING;md5=fc178bcd425090939a8b634d1d6a9594 \
12*edff4923SAndrew Geissler    file://tests/COPYING;md5=a23a74b3f4caf9616230789d94217acb \
13*edff4923SAndrew Geissler"
14*edff4923SAndrew Geissler
15*edff4923SAndrew GeisslerSRC_URI = "https://github.com/kergoth/tslib/releases/download/${PV}/tslib-${PV}.tar.xz;downloadfilename=tslib-${PV}.tar.xz \
16*edff4923SAndrew Geissler           file://ts.conf \
17*edff4923SAndrew Geissler           file://tslib.sh \
18*edff4923SAndrew Geissler           "
19*edff4923SAndrew GeisslerSRC_URI[sha256sum] = "9b489a54d48006201f2fe955a88c3f857535ac93b6cf8e5a16c7b166c8991dac"
20*edff4923SAndrew Geissler
21*edff4923SAndrew GeisslerUPSTREAM_CHECK_URI = "https://github.com/kergoth/tslib/releases"
22*edff4923SAndrew Geissler
23*edff4923SAndrew Geisslerinherit autotools pkgconfig
24*edff4923SAndrew Geissler
25*edff4923SAndrew GeisslerPACKAGECONFIG ??= "debounce dejitter evthres iir linear median pthres skip lowpass invert variance input touchkit waveshare"
26*edff4923SAndrew GeisslerPACKAGECONFIG[debounce] = "--enable-debounce,--disable-debounce"
27*edff4923SAndrew GeisslerPACKAGECONFIG[dejitter] = "--enable-dejitter,--disable-dejitter"
28*edff4923SAndrew GeisslerPACKAGECONFIG[evthres] = "--enable-evthres,--disable-evthres"
29*edff4923SAndrew GeisslerPACKAGECONFIG[iir] = "--enable-iir,--disable-iir"
30*edff4923SAndrew GeisslerPACKAGECONFIG[linear] = "--enable-linear,--disable-linear"
31*edff4923SAndrew GeisslerPACKAGECONFIG[median] = "--enable-median,--disable-median"
32*edff4923SAndrew GeisslerPACKAGECONFIG[pthres] = "--enable-pthres,--disable-pthres"
33*edff4923SAndrew GeisslerPACKAGECONFIG[skip] = "--enable-skip,--disable-skip"
34*edff4923SAndrew GeisslerPACKAGECONFIG[lowpass] = "--enable-lowpass,--disable-lowpass"
35*edff4923SAndrew GeisslerPACKAGECONFIG[invert] = "--enable-invert,--disable-invert"
36*edff4923SAndrew GeisslerPACKAGECONFIG[variance] = "--enable-variance,--disable-variance"
37*edff4923SAndrew GeisslerPACKAGECONFIG[input] = "--enable-input,--disable-input"
38*edff4923SAndrew GeisslerPACKAGECONFIG[tatung] = "--enable-tatung,--disable-tatung"
39*edff4923SAndrew GeisslerPACKAGECONFIG[touchkit] = "--enable-touchkit,--disable-touchkit"
40*edff4923SAndrew GeisslerPACKAGECONFIG[waveshare] = "--enable-waveshare,--disable-waveshare"
41*edff4923SAndrew GeisslerPACKAGECONFIG[ucb1x00] = "--enable-ucb1x00,--disable-ucb1x00"
42*edff4923SAndrew GeisslerPACKAGECONFIG[mk712] = "--enable-mk712,--disable-mk712"
43*edff4923SAndrew GeisslerPACKAGECONFIG[h3600] = "--enable-h3600,--disable-h3600"
44*edff4923SAndrew GeisslerPACKAGECONFIG[dmc] = "--enable-dmc,--disable-dmc"
45*edff4923SAndrew GeisslerPACKAGECONFIG[linear-h2200] = "--enable-linear-h2200,--disable-linear-h2200"
46*edff4923SAndrew GeisslerPACKAGECONFIG[corgi] = "--enable-corgi,--disable-corgi"
47*edff4923SAndrew GeisslerPACKAGECONFIG[collie] = "--enable-collie,--disable-collie"
48*edff4923SAndrew GeisslerPACKAGECONFIG[arctic2] = "--enable-arctic2,--disable-arctic2"
49*edff4923SAndrew GeisslerPACKAGECONFIG[dmc_dus3000] = "--enable-dmc_dus3000,--disable-dmc_dus3000"
50*edff4923SAndrew GeisslerPACKAGECONFIG[cy8mrln-palmpre] = "--enable-cy8mrln-palmpre,--disable-cy8mrln-palmpre"
51*edff4923SAndrew GeisslerPACKAGECONFIG[galax] = "--enable-galax,--disable-galax"
52*edff4923SAndrew GeisslerPACKAGECONFIG[one-wire-ts-input] = "--enable-one-wire-ts-input,--disable-one-wire-ts-input"
53*edff4923SAndrew GeisslerPACKAGECONFIG[debug] = "--enable-debug,--disable-debug"
54*edff4923SAndrew Geissler
55*edff4923SAndrew Geisslerdo_install:prepend() {
56*edff4923SAndrew Geissler    install -m 0644 ${UNPACKDIR}/ts.conf ${S}/etc/ts.conf
57*edff4923SAndrew Geissler}
58*edff4923SAndrew Geissler
59*edff4923SAndrew Geisslerdo_install:append() {
60*edff4923SAndrew Geissler    install -d ${D}${sysconfdir}/profile.d/
61*edff4923SAndrew Geissler    install -m 0755 ${UNPACKDIR}/tslib.sh ${D}${sysconfdir}/profile.d/
62*edff4923SAndrew Geissler}
63*edff4923SAndrew Geissler
64*edff4923SAndrew GeisslerRPROVIDES:tslib-conf = "libts-0.0-conf"
65*edff4923SAndrew Geissler
66*edff4923SAndrew GeisslerPACKAGES =+ "tslib-conf tslib-tests tslib-calibrate tslib-uinput"
67*edff4923SAndrew GeisslerDEBIAN_NOAUTONAME:tslib-conf = "1"
68*edff4923SAndrew GeisslerDEBIAN_NOAUTONAME:tslib-tests = "1"
69*edff4923SAndrew GeisslerDEBIAN_NOAUTONAME:tslib-calibrate = "1"
70*edff4923SAndrew GeisslerDEBIAN_NOAUTONAME:tslib-uinput = "1"
71*edff4923SAndrew Geissler
72*edff4923SAndrew GeisslerRDEPENDS:${PN} = "tslib-conf"
73*edff4923SAndrew GeisslerRRECOMMENDS:${PN} = "pointercal"
74*edff4923SAndrew Geissler
75*edff4923SAndrew GeisslerFILES:${PN}-dev += "${libdir}/ts/*.la"
76*edff4923SAndrew GeisslerFILES:tslib-conf = "${sysconfdir}/ts.conf ${sysconfdir}/profile.d/tslib.sh ${datadir}/tslib"
77*edff4923SAndrew GeisslerFILES:${PN} = "${libdir}/*.so.* ${libdir}/ts/*.so*"
78*edff4923SAndrew GeisslerFILES:tslib-calibrate += "${bindir}/ts_calibrate"
79*edff4923SAndrew GeisslerFILES:tslib-uinput += "${bindir}/ts_uinput"
80*edff4923SAndrew Geissler
81*edff4923SAndrew GeisslerFILES:tslib-tests = "${bindir}/ts_harvest ${bindir}/ts_print ${bindir}/ts_print_raw ${bindir}/ts_print_mt \
82*edff4923SAndrew Geissler                     ${bindir}/ts_test ${bindir}/ts_test_mt ${bindir}/ts_verify ${bindir}/ts_finddev ${bindir}/ts_conf"
83*edff4923SAndrew Geissler
84*edff4923SAndrew GeisslerBBCLASSEXTEND = "native nativesdk"
85