Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 1 | SUMMARY = "A mode switching tool for controlling 'flip flop' (multiple device) USB gear" |
Andrew Geissler | 9aee500 | 2022-03-30 16:27:02 +0000 | [diff] [blame] | 2 | LICENSE = "GPL-2.0-only" |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 3 | LIC_FILES_CHKSUM = "file://COPYING;md5=091556bd6d0154cd4c2d17a1bfc7380a" |
| 4 | |
| 5 | DEPENDS = "libusb1" |
| 6 | |
| 7 | SRC_URI = "http://www.draisberghof.de/usb_modeswitch/${BP}.tar.bz2" |
Andrew Geissler | 6aa7eec | 2023-03-03 12:41:14 -0600 | [diff] [blame] | 8 | SRC_URI[sha256sum] = "5195d9e136e52f658f19e9f93e4f982b1b67bffac197d0a455cd8c2cd245fa34" |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 9 | |
| 10 | inherit pkgconfig systemd |
| 11 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 12 | SYSTEMD_SERVICE:${PN} = "usb_modeswitch@.service" |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 13 | |
| 14 | EXTRA_OEMAKE = "TCL=${bindir}/tclsh" |
| 15 | |
Andrew Geissler | 6aa7eec | 2023-03-03 12:41:14 -0600 | [diff] [blame] | 16 | FILES:${PN} = " \ |
| 17 | ${bindir} \ |
| 18 | ${sysconfdir} \ |
| 19 | ${nonarch_base_libdir}/udev/usb_modeswitch \ |
| 20 | ${sbindir} ${localstatedir}/lib/usb_modeswitch \ |
| 21 | " |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 22 | RDEPENDS:${PN} = "tcl" |
| 23 | RRECOMMENDS:${PN} = "usb-modeswitch-data" |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 24 | |
| 25 | do_install() { |
Andrew Geissler | bbbd5f4 | 2020-10-30 15:42:48 -0500 | [diff] [blame] | 26 | oe_runmake DESTDIR=${D} UDEVDIR=${D}/${nonarch_base_libdir}/udev install |
Andrew Geissler | 82c905d | 2020-04-13 13:39:40 -0500 | [diff] [blame] | 27 | if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then |
| 28 | install -d ${D}/${systemd_unitdir}/system |
| 29 | install -m 644 ${S}/usb_modeswitch@.service ${D}/${systemd_unitdir}/system |
| 30 | fi |
| 31 | } |