Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 1 | SUMMARY = "Advanced TFTP server and client" |
| 2 | SECTION = "net" |
| 3 | HOMEPAGE = "http://packages.debian.org/atftp" |
| 4 | LICENSE = "GPLv2" |
| 5 | LIC_FILES_CHKSUM = "file://LICENSE;md5=94d55d512a9ba36caa9b7df079bae19f" |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 6 | |
Andrew Geissler | ac970dd | 2021-02-12 15:32:45 -0600 | [diff] [blame] | 7 | SRCREV = "e56e8845f1070e89a4a6e509396b681688d03793" |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 8 | |
| 9 | SRC_URI = "git://git.code.sf.net/p/atftp/code \ |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 10 | file://atftpd.init \ |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 11 | file://atftpd.service \ |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 12 | " |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 13 | |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 14 | S = "${WORKDIR}/git" |
| 15 | |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 16 | inherit autotools update-rc.d systemd |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 17 | |
| 18 | PACKAGECONFIG ??= "tcp-wrappers" |
| 19 | PACKAGECONFIG[pcre] = "--enable-libpcre,--disable-libpcre,libpcre" |
| 20 | PACKAGECONFIG[tcp-wrappers] = "--enable-libwrap,--disable-libwrap,tcp-wrappers" |
| 21 | PACKAGECONFIG[readline] = "--enable-libreadline,--disable-libreadline,readline" |
| 22 | |
| 23 | INITSCRIPT_PACKAGES = "${PN}d" |
| 24 | INITSCRIPT_NAME_${PN}d = "atftpd" |
| 25 | INITSCRIPT_PARAMS_${PN}d = "defaults 80" |
| 26 | |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 27 | |
| 28 | EXTRA_OEMAKE = "CFLAGS='${CFLAGS} -std=gnu89'" |
| 29 | |
| 30 | do_install_append() { |
| 31 | install -d ${D}${sysconfdir}/init.d |
| 32 | install -m 0755 ${WORKDIR}/atftpd.init ${D}${sysconfdir}/init.d/atftpd |
| 33 | |
| 34 | install -d ${D}/srv/tftp |
| 35 | |
| 36 | rm ${D}${sbindir}/in.tftpd |
Patrick Williams | ddad1a1 | 2017-02-23 20:36:32 -0600 | [diff] [blame] | 37 | |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 38 | install -d ${D}${systemd_unitdir}/system |
| 39 | install -m 0644 ${WORKDIR}/atftpd.service ${D}${systemd_unitdir}/system |
| 40 | } |
| 41 | |
| 42 | PACKAGES =+ "${PN}d" |
| 43 | |
| 44 | FILES_${PN} = "${bindir}/*" |
| 45 | |
| 46 | FILES_${PN}d = "${sbindir}/* \ |
| 47 | ${sysconfdir} \ |
| 48 | /srv/tftp \ |
| 49 | ${systemd_unitdir}/system/atftpd.service \ |
| 50 | " |
| 51 | |
| 52 | SYSTEMD_PACKAGES = "${PN}d" |
| 53 | SYSTEMD_SERVICE_${PN}d = "atftpd.service" |
| 54 | RPROVIDES_${PN}d += "${PN}d-systemd" |
| 55 | RREPLACES_${PN}d += "${PN}d-systemd" |
| 56 | RCONFLICTS_${PN}d += "${PN}d-systemd" |