6213fd967db6b41aba88ce96cb2b2edaf0599abe
[AGL/meta-agl-demo.git] / recipes-kernel / sllin / sllin.bb
1 DESCRIPTION = "slLIN driver module"
2 LICENSE = "GPLv2"
3 LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6"
4
5 inherit module systemd
6
7 DEPENDS = "virtual/kernel"
8
9 SRC_URI = "git://github.com/trainman419/linux-lin.git;protocol=https"
10 SRCREV = "155d885e8ccc907a56f6c86c4b159fac27ef6fec"
11 S = "${WORKDIR}/git/sllin"
12
13 PV = "0.1+git${SRCPV}"
14
15 SRC_URI_append = " \
16         file://0001_update_makefile.patch;pnum=2 \
17         file://0002_fix_null_operation_check.patch;pnum=2 \
18         file://0003-Allow-recent-kernels-newer-4.11.x-to-build.patch;pnum=2 \
19         file://0001-Disable-sllin-driver-debug-log.patch;pnum=2 \
20         file://sllin-demo.service \
21         file://start_lin_demo.sh \
22 "
23
24 KERNEL_MODULE_AUTOLOAD_append = " sllin"
25 KERNEL_MODULE_PROBECONF_append = " sllin"
26
27 SLLINBAUDRATE ??= "9600"
28 module_conf_sllin = "options sllin baudrate=${SLLINBAUDRATE}"
29
30 SYSTEMD_SERVICE_${PN} = "sllin-demo.service"
31
32 do_install_append () {
33         install -d 644 ${D}/${bindir}
34         install -m 755 ${WORKDIR}/start_lin_demo.sh ${D}/${bindir}/start_lin_demo.sh
35         install -d ${D}${systemd_system_unitdir}
36         install -m 0644 ${WORKDIR}/sllin-demo.service ${D}${systemd_system_unitdir}/
37 }
38
39 FILES_${PN}_append = " ${bindir}/start_lin_demo.sh"