aboutsummaryrefslogtreecommitdiffstats
path: root/meta-networking/recipes-daemons/tftp-hpa
diff options
context:
space:
mode:
Diffstat (limited to 'meta-networking/recipes-daemons/tftp-hpa')
-rw-r--r--meta-networking/recipes-daemons/tftp-hpa/files/0001-__progname-is-provided-by-libc.patch2
-rw-r--r--meta-networking/recipes-daemons/tftp-hpa/files/0001-tftp-Mark-toplevel-definition-as-external.patch30
-rw-r--r--meta-networking/recipes-daemons/tftp-hpa/files/0001-tftp-Remove-double-inclusion-of-signal.h.patch39
-rw-r--r--meta-networking/recipes-daemons/tftp-hpa/files/add-error-check-for-disk-filled-up.patch2
-rw-r--r--meta-networking/recipes-daemons/tftp-hpa/files/fix-writing-emtpy-file.patch2
-rw-r--r--meta-networking/recipes-daemons/tftp-hpa/files/tftp-hpa-bug-fix-on-separated-CR-and-LF.patch2
-rw-r--r--meta-networking/recipes-daemons/tftp-hpa/tftp-hpa_5.2.bb23
7 files changed, 89 insertions, 11 deletions
diff --git a/meta-networking/recipes-daemons/tftp-hpa/files/0001-__progname-is-provided-by-libc.patch b/meta-networking/recipes-daemons/tftp-hpa/files/0001-__progname-is-provided-by-libc.patch
index cead977e28..66c15b5f8b 100644
--- a/meta-networking/recipes-daemons/tftp-hpa/files/0001-__progname-is-provided-by-libc.patch
+++ b/meta-networking/recipes-daemons/tftp-hpa/files/0001-__progname-is-provided-by-libc.patch
@@ -12,6 +12,8 @@ global symbols and work around Debian bug #519006 (Closes: #564052).
Signed-off-by: Ron Lee <ron@debian.org>
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
---
+Upstream-Status: Pending
+
tftpd/tftpd.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/meta-networking/recipes-daemons/tftp-hpa/files/0001-tftp-Mark-toplevel-definition-as-external.patch b/meta-networking/recipes-daemons/tftp-hpa/files/0001-tftp-Mark-toplevel-definition-as-external.patch
new file mode 100644
index 0000000000..646757c783
--- /dev/null
+++ b/meta-networking/recipes-daemons/tftp-hpa/files/0001-tftp-Mark-toplevel-definition-as-external.patch
@@ -0,0 +1,30 @@
+From 2a12174a5059e84d4ff6fad8f983a4d0f2127e73 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 12 Aug 2020 12:17:31 -0700
+Subject: [PATCH] tftp: Mark toplevel definition as external
+
+Fixes
+multiple definition of `toplevel'; tftp.o:/usr/src/debug/tftp-hpa/5.2-r0/tftp-hpa-5.2/tftp/tftp.c:51: first defined here
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ tftp/tftp.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/tftp/tftp.c b/tftp/tftp.c
+index 9d15022..109848c 100644
+--- a/tftp/tftp.c
++++ b/tftp/tftp.c
+@@ -48,7 +48,7 @@ extern int maxtimeout;
+ #define PKTSIZE SEGSIZE+4
+ char ackbuf[PKTSIZE];
+ int timeout;
+-sigjmp_buf toplevel;
++extern sigjmp_buf toplevel;
+ sigjmp_buf timeoutbuf;
+
+ static void nak(int, const char *);
+--
+2.28.0
+
diff --git a/meta-networking/recipes-daemons/tftp-hpa/files/0001-tftp-Remove-double-inclusion-of-signal.h.patch b/meta-networking/recipes-daemons/tftp-hpa/files/0001-tftp-Remove-double-inclusion-of-signal.h.patch
new file mode 100644
index 0000000000..84658d667b
--- /dev/null
+++ b/meta-networking/recipes-daemons/tftp-hpa/files/0001-tftp-Remove-double-inclusion-of-signal.h.patch
@@ -0,0 +1,39 @@
+From e9ed48d91642d384ce07cbb9bec788f07fc6354c Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 6 Sep 2022 14:51:42 -0700
+Subject: [PATCH] tftp: Remove double inclusion of signal.h
+
+Undefine __USE_XOPEN2K8 so we can get bsd_signal definition from system
+headers
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ config.h | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/config.h b/config.h
+index 3ff2915..ae1a14b 100644
+--- a/config.h
++++ b/config.h
+@@ -93,7 +93,6 @@
+ #endif
+
+ #include <errno.h>
+-#include <signal.h>
+
+ #ifdef HAVE_SYS_SOCKET_H
+ #include <sys/socket.h>
+@@ -296,6 +295,9 @@ char *xstrdup(const char *);
+
+ #ifndef HAVE_BSD_SIGNAL
+ void (*bsd_signal(int, void (*)(int))) (int);
++#else
++#undef __USE_XOPEN2K8
++#include <signal.h>
+ #endif
+ #ifndef HAVE_DUP2
+ int dup2(int, int);
+--
+2.37.3
+
diff --git a/meta-networking/recipes-daemons/tftp-hpa/files/add-error-check-for-disk-filled-up.patch b/meta-networking/recipes-daemons/tftp-hpa/files/add-error-check-for-disk-filled-up.patch
index d01c20d385..e4acd099ab 100644
--- a/meta-networking/recipes-daemons/tftp-hpa/files/add-error-check-for-disk-filled-up.patch
+++ b/meta-networking/recipes-daemons/tftp-hpa/files/add-error-check-for-disk-filled-up.patch
@@ -3,7 +3,7 @@ From: "Roy.Li" <rongqing.li@windriver.com>
Date: Thu, 22 Aug 2013 08:56:09 +0800
Subject: [PATCH] tftp-hpa: add error check for disk filled up
-Upstream-status: Pending [Sent to http://www.syslinux.org/archives/2013-August/020765.html]
+Upstream-Status: Pending [Sent to http://www.syslinux.org/archives/2013-August/020765.html]
Add error check when the write-buffer is finally flushed to the file,
the caller can detect if the disk filled up (or had an i/o error) and
diff --git a/meta-networking/recipes-daemons/tftp-hpa/files/fix-writing-emtpy-file.patch b/meta-networking/recipes-daemons/tftp-hpa/files/fix-writing-emtpy-file.patch
index 452aa05f81..4f3dcd7767 100644
--- a/meta-networking/recipes-daemons/tftp-hpa/files/fix-writing-emtpy-file.patch
+++ b/meta-networking/recipes-daemons/tftp-hpa/files/fix-writing-emtpy-file.patch
@@ -1,6 +1,6 @@
[PATCH] fix the empty file writting
-Upstream-Status: pending
+Upstream-Status: Pending
With the feature that checking the disk filled up, the return
value of function write_behind was checked and used to detect
diff --git a/meta-networking/recipes-daemons/tftp-hpa/files/tftp-hpa-bug-fix-on-separated-CR-and-LF.patch b/meta-networking/recipes-daemons/tftp-hpa/files/tftp-hpa-bug-fix-on-separated-CR-and-LF.patch
index 3e220ec385..e994f28402 100644
--- a/meta-networking/recipes-daemons/tftp-hpa/files/tftp-hpa-bug-fix-on-separated-CR-and-LF.patch
+++ b/meta-networking/recipes-daemons/tftp-hpa/files/tftp-hpa-bug-fix-on-separated-CR-and-LF.patch
@@ -7,7 +7,7 @@ In ascii mode, if the CR and LF was separated into different transfer
blocks, LF will be just dropped instead of replacing the previous CR.
Add a checking on the first character to fix it.
-Upstream-Status: pending
+Upstream-Status: Pending
Signed-off-by: Zhang Xiao <xiao.zhang@windriver.com>
---
diff --git a/meta-networking/recipes-daemons/tftp-hpa/tftp-hpa_5.2.bb b/meta-networking/recipes-daemons/tftp-hpa/tftp-hpa_5.2.bb
index 132972b331..565f493ce2 100644
--- a/meta-networking/recipes-daemons/tftp-hpa/tftp-hpa_5.2.bb
+++ b/meta-networking/recipes-daemons/tftp-hpa/tftp-hpa_5.2.bb
@@ -28,6 +28,8 @@ SRC_URI = "http://kernel.org/pub/software/network/tftp/tftp-hpa/tftp-hpa-${PV}.t
file://tftp-hpa-bug-fix-on-separated-CR-and-LF.patch \
file://fix-writing-emtpy-file.patch \
file://0001-__progname-is-provided-by-libc.patch \
+ file://0001-tftp-Mark-toplevel-definition-as-external.patch \
+ file://0001-tftp-Remove-double-inclusion-of-signal.h.patch \
file://tftpd-hpa.socket \
file://tftpd-hpa.service \
"
@@ -71,21 +73,26 @@ do_install() {
sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/tftpd-hpa.service
}
-FILES_${PN} = "${bindir}"
+FILES:${PN} = "${bindir}"
PACKAGES += "tftp-hpa-server"
-SUMMARY_tftp-hpa-server = "Server for the Trivial File Transfer Protocol"
-FILES_tftp-hpa-server = "${sbindir} ${sysconfdir} ${localstatedir}"
-CONFFILES_tftp-hpa-server = "${sysconfdir}/default/tftpd-hpa"
+SUMMARY:tftp-hpa-server = "Server for the Trivial File Transfer Protocol"
+FILES:tftp-hpa-server = "${sbindir} ${sysconfdir} ${localstatedir}"
+CONFFILES:tftp-hpa-server = "${sysconfdir}/default/tftpd-hpa"
INITSCRIPT_PACKAGES = "tftp-hpa-server"
INITSCRIPT_NAME = "tftpd-hpa"
INITSCRIPT_PARAMS = "start 20 2 3 4 5 . stop 20 1 ."
-ALTERNATIVE_${PN} = "tftp"
+ALTERNATIVE:${PN}-doc = "tftpd.8 tftp.1"
+ALTERNATIVE_LINK_NAME[tftpd.8] = "${mandir}/man8/tftpd.8"
+ALTERNATIVE_LINK_NAME[tftp.1] = "${mandir}/man1/tftp.1"
+
+ALTERNATIVE:${PN} = "tftp"
ALTERNATIVE_TARGET[tftp] = "${bindir}/tftp-hpa"
-ALTERNATIVE_PRIORITY = "60"
+ALTERNATIVE_PRIORITY = "100"
+
SYSTEMD_PACKAGES = "tftp-hpa-server"
-SYSTEMD_SERVICE_tftp-hpa-server = "tftpd-hpa.socket tftpd-hpa.service"
-SYSTEMD_AUTO_ENABLE_tftp-hpa-server = "enable"
+SYSTEMD_SERVICE:tftp-hpa-server = "tftpd-hpa.socket tftpd-hpa.service"
+SYSTEMD_AUTO_ENABLE:tftp-hpa-server = "enable"