Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 1 | SUMMARY = "tftp - Trivial file transfer protocol client" |
| 2 | SECTION = "net" |
| 3 | LICENSE = "BSD-4-Clause" |
| 4 | DEPENDS = "tcp-wrappers" |
| 5 | |
| 6 | LIC_FILES_CHKSUM = "file://tftp/tftp.c;beginline=2;endline=3;md5=84d2cfe1e60863a7d82648734ba4d30c" |
| 7 | |
| 8 | SRC_URI = "${DEBIAN_MIRROR}/main/n/${BPN}/${BPN}_${PV}.orig.tar.gz;name=archive \ |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 9 | ${DEBIAN_MIRROR}/main/n/${BPN}/${BPN}_${PV}-18.diff.gz;name=patch18 \ |
| 10 | file://tftp.conf \ |
| 11 | file://0001-tftp-Include-missing-fcntl.h.patch \ |
| 12 | " |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 13 | |
| 14 | SRC_URI[archive.md5sum] = "b7262c798e2ff50e29c2ff50dfd8d6a8" |
| 15 | SRC_URI[archive.sha256sum] = "3a43c0010d4e61f412563fd83769d4667d8b8e82903526d21cb9205fe55ad14d" |
| 16 | SRC_URI[patch18.md5sum] = "cb29e7a33dd85105ba6e6ec4f971e42c" |
| 17 | SRC_URI[patch18.sha256sum] = "092437d27b4fa88c044ef6290372fee5ce06d223607f0e22a6e527065c8930e7" |
| 18 | |
Andrew Geissler | d688a01 | 2020-09-18 13:36:00 -0500 | [diff] [blame] | 19 | inherit autotools-brokensep update-alternatives |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 20 | |
| 21 | do_configure () { |
| 22 | ./configure --prefix=${prefix} |
| 23 | echo "CFLAGS=${CFLAGS}" > MCONFIG |
| 24 | } |
| 25 | |
| 26 | do_compile () { |
| 27 | oe_runmake 'CC=${CC}' 'LD=${LD}' 'LDFLAGS=${LDFLAGS}' 'CFLAGS=${CFLAGS}' |
| 28 | } |
| 29 | |
| 30 | do_install () { |
| 31 | install -d ${D}${bindir} |
| 32 | install -d ${D}${sbindir} |
| 33 | install -d ${D}${mandir}/man1 |
| 34 | install -d ${D}${mandir}/man8 |
| 35 | install -d ${D}${sysconfdir}/xinetd.d |
| 36 | |
| 37 | sed -i 's/install -s/install/' tftp/Makefile |
| 38 | sed -i 's/install -s/install/' tftpd/Makefile |
| 39 | |
| 40 | oe_runmake 'INSTALLROOT=${D}' 'BINMODE=0755' \ |
| 41 | 'DAEMONMODE=0755' 'MANMODE=0644' \ |
| 42 | 'BINDIR=${bindir}' 'SBINDIR=${sbindir}' \ |
| 43 | 'MANDIR=${mandir}' install |
| 44 | |
| 45 | install ${WORKDIR}/tftp.conf ${D}/${sysconfdir}/xinetd.d/tftp |
| 46 | } |
| 47 | |
| 48 | PACKAGES = "${PN}-client ${PN}-server ${PN}-doc ${BPN}-dbg" |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 49 | FILES:${PN}-client = "${bindir}/*" |
| 50 | FILES:${PN}-server = "${sbindir}/* ${sysconfdir}/xinetd.d/*" |
| 51 | FILES:${PN}-doc = "${mandir}" |
| 52 | FILES:${PN}-dbg = "${prefix}/src/debug \ |
Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 53 | ${bindir}/.debug ${sbindir}/.debug" |
| 54 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 55 | RDEPENDS:${PN}-server = "tcp-wrappers xinetd" |
Andrew Geissler | d688a01 | 2020-09-18 13:36:00 -0500 | [diff] [blame] | 56 | |
| 57 | ALTERNATIVE_PRIORITY = "100" |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 58 | ALTERNATIVE:${PN}-client = "tftp" |
Andrew Geissler | d688a01 | 2020-09-18 13:36:00 -0500 | [diff] [blame] | 59 | ALTERNATIVE_LINK_NAME[tftp] = "${bindir}/tftp" |