blob: 26a356dc81b52d056653fe9241d00b0ede7b6b8d [file] [log] [blame]
Thang Q. Nguyenfa1aa4d2021-08-07 05:09:50 +00001FILESEXTRAPATHS:append := "${THISDIR}/${PN}:"
2RDEPENDS:${PN} += "bash"
Tung Nguyen189431e2020-12-16 08:11:51 +00003
Chau Ly0a0f3482023-04-13 05:06:28 +00004# Declare port spcific config files
5OBMC_CONSOLE_TTYS = "ttyS0 ttyS1 ttyS2 ttyS3"
6CONSOLE_CLIENT = "2200 2201 2202 2203"
Tung Nguyen189431e2020-12-16 08:11:51 +00007
Chau Ly0a0f3482023-04-13 05:06:28 +00008CONSOLE_SERVER_CONF_FMT = "file://server.{0}.conf"
9CONSOLE_CLIENT_CONF_FMT = "file://client.{0}.conf"
Chau Lybcc46612023-05-10 05:52:40 +000010CONSOLE_CLIENT_SERVICE_FMT = "obmc-console-ssh@{0}.service"
Tung Nguyen189431e2020-12-16 08:11:51 +000011
Chau Lybcc46612023-05-10 05:52:40 +000012SRC_URI += " \
13 ${@compose_list(d, 'CONSOLE_SERVER_CONF_FMT', 'OBMC_CONSOLE_TTYS')} \
Chau Ly0a0f3482023-04-13 05:06:28 +000014 ${@compose_list(d, 'CONSOLE_CLIENT_CONF_FMT', 'CONSOLE_CLIENT')} \
15 "
Tung Nguyen189431e2020-12-16 08:11:51 +000016
Chau Lybcc46612023-05-10 05:52:40 +000017SYSTEMD_SERVICE:${PN}:append = " \
18 ${@compose_list(d, 'CONSOLE_CLIENT_SERVICE_FMT', 'CONSOLE_CLIENT')} \
19 "
Chau Ly0a0f3482023-04-13 05:06:28 +000020SYSTEMD_SERVICE:${PN}:remove = "obmc-console-ssh.socket"
Tung Nguyen189431e2020-12-16 08:11:51 +000021
Chau Ly0a0f3482023-04-13 05:06:28 +000022FILES:${PN}:remove = "${systemd_system_unitdir}/obmc-console-ssh@.service.d/use-socket.conf"
23
Andrew Jeffery08413f22023-04-21 11:45:51 +093024PACKAGECONFIG:append = " concurrent-servers"
Chau Ly0a0f3482023-04-13 05:06:28 +000025
Thang Q. Nguyenfa1aa4d2021-08-07 05:09:50 +000026do_install:append() {
Chau Ly0a0f3482023-04-13 05:06:28 +000027 # Install the console client configurations
28 install -m 0644 ${WORKDIR}/client.*.conf ${D}${sysconfdir}/${BPN}/
Tung Nguyen189431e2020-12-16 08:11:51 +000029}