diff options
Diffstat (limited to 'import-layers/meta-openembedded/meta-networking/recipes-netkit')
12 files changed, 318 insertions, 16 deletions
diff --git a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-ftp/netkit-ftp/0001-ftp-include-sys-types.h-for-u_long.patch b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-ftp/netkit-ftp/0001-ftp-include-sys-types.h-for-u_long.patch new file mode 100644 index 000000000..8376603ea --- /dev/null +++ b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-ftp/netkit-ftp/0001-ftp-include-sys-types.h-for-u_long.patch @@ -0,0 +1,30 @@ +From 2ee0c51d81a0a08d64b64ab624074e5f7cd9615a Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Sat, 15 Jul 2017 00:07:32 -0700 +Subject: [PATCH] ftp: include sys/types.h for u_long + +fixes +ftp.c:1091:2: error: unknown type name 'u_long'; did you mean 'long'? + u_long a1,a2,a3,a4,p1,p2; + ^~~~~~ + +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + ftp/ftp.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/ftp/ftp.c b/ftp/ftp.c +index 7a56af6..5dcb513 100644 +--- a/ftp/ftp.c ++++ b/ftp/ftp.c +@@ -43,6 +43,7 @@ char ftp_rcsid[] = + #include <sys/socket.h> + #include <sys/time.h> + #include <sys/file.h> ++#include <sys/types.h> + + #include <netinet/in.h> + #include <netinet/ip.h> +-- +2.13.3 + diff --git a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-ftp/netkit-ftp_0.17.bb b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-ftp/netkit-ftp_0.17.bb index 37f5bc725..394a69e62 100644 --- a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-ftp/netkit-ftp_0.17.bb +++ b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-ftp/netkit-ftp_0.17.bb @@ -6,9 +6,10 @@ LICENSE = "BSD" LIC_FILES_CHKSUM = "file://ftp/ftp.c;beginline=2;endline=3;md5=2d40a75a50d83b8f6317b3f53db72bfa" SRC_URI = "${DEBIAN_MIRROR}/main/n/netkit-ftp/netkit-ftp_${PV}.orig.tar.gz;name=archive \ - ${DEBIAN_MIRROR}/main/n/netkit-ftp/netkit-ftp_${PV}-31.debian.tar.xz;name=patch31 \ - file://Add_ARG_MAX_define.patch \ -" + ${DEBIAN_MIRROR}/main/n/netkit-ftp/netkit-ftp_${PV}-31.debian.tar.xz;name=patch31 \ + file://Add_ARG_MAX_define.patch \ + file://0001-ftp-include-sys-types.h-for-u_long.patch \ + " SRC_URI[archive.md5sum] = "94441610c9b86ef45c4c6ec609444060" SRC_URI[archive.sha256sum] = "61c913299b81a4671ff089aac821329f7db9bc111aa812993dd585798b700349" diff --git a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rpc/netkit-rpc/0001-rpcgen-Fix-printf-formats.patch b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rpc/netkit-rpc/0001-rpcgen-Fix-printf-formats.patch new file mode 100644 index 000000000..8bd77d2e4 --- /dev/null +++ b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rpc/netkit-rpc/0001-rpcgen-Fix-printf-formats.patch @@ -0,0 +1,51 @@ +From 439e3e35f7fcbff1abb782de4b19b31e43ae3449 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Tue, 27 Jun 2017 09:59:19 -0700 +Subject: [PATCH] rpcgen: Fix printf formats + +Fixes build with hardening flags + +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + rpcgen/rpc_hout.c | 2 +- + rpcgen/rpc_tblout.c | 4 ++-- + 2 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/rpcgen/rpc_hout.c b/rpcgen/rpc_hout.c +index 0ef52df..09a7b57 100644 +--- a/rpcgen/rpc_hout.c ++++ b/rpcgen/rpc_hout.c +@@ -474,7 +474,7 @@ pdeclaration(const char *name, declaration *dec, int tab, + break; + } + } +- f_print(fout, separator ); ++ f_print(fout, "%s", separator ); + } + + static int +diff --git a/rpcgen/rpc_tblout.c b/rpcgen/rpc_tblout.c +index d64bfde..fd62a52 100644 +--- a/rpcgen/rpc_tblout.c ++++ b/rpcgen/rpc_tblout.c +@@ -99,7 +99,7 @@ write_table(const definition *def) + } + else { + expected = 1; +- f_print(fout, null_entry); ++ f_print(fout, "%s", null_entry); + } + for (proc = vp->procs; proc != NULL; proc = proc->next) { + current = atoi(proc->proc_num); +@@ -139,7 +139,7 @@ write_table(const definition *def) + } + + /* print the table trailer */ +- f_print(fout, tbl_end); ++ f_print(fout, "%s", tbl_end); + f_print(fout, tbl_nproc, progvers, progvers, progvers); + } + } +-- +2.13.2 + diff --git a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rpc/netkit-rpc_0.17.bb b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rpc/netkit-rpc_0.17.bb index abc9d88cb..9487fdc2c 100644 --- a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rpc/netkit-rpc_0.17.bb +++ b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rpc/netkit-rpc_0.17.bb @@ -4,10 +4,15 @@ SECTION = "net" LICENSE = "SPL-1.0" LIC_FILES_CHKSUM = "file://rpcinfo/rpcinfo.c;beginline=2;endline=3;md5=3e6339e3ce266e1122c5ba293e04bc89" +DEPENDS_append_libc-musl = " libtirpc" SRC_URI = "http://sources.openembedded.org/${BPN}-${PV}.tar.gz \ - file://gcc4.patch" + file://gcc4.patch \ + file://0001-rpcgen-Fix-printf-formats.patch \ + " SRC_URI[md5sum] = "67212720482ea1aea9182a98653a9642" SRC_URI[sha256sum] = "421d63b414162237a72867061f1bd3e3752a0d962cd5d30b5e933ddad8a14d3b" +CFLAGS_append_libc-musl = " -I${STAGING_INCDIR}/tirpc" +LIBS_append_libc-musl = " -ltirpc" do_configure () { ./configure --prefix=${prefix} @@ -16,6 +21,7 @@ do_configure () { echo "LD=${LD}" >> MCONFIG echo "CFLAGS=${CFLAGS}" >> MCONFIG echo "LDFLAGS=${LDFLAGS}" >> MCONFIG + echo "LIBS=${LIBS}" >> MCONFIG } do_compile () { diff --git a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rsh/netkit-rsh_0.17.bb b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rsh/netkit-rsh_0.17.bb index 8f08acf30..d61636ee8 100644 --- a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rsh/netkit-rsh_0.17.bb +++ b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rsh/netkit-rsh_0.17.bb @@ -36,14 +36,14 @@ CFLAGS += " -D_GNU_SOURCE -Wno-deprecated-declarations" LDFLAGS += " -L${STAGING_LIBDIR} -lutil -lcrypt" PACKAGECONFIG ??= "" -PACKAGECONFIG += " ${@bb.utils.contains("DISTRO_FEATURES", "pam", "pam", "", d)}" +PACKAGECONFIG += "${@bb.utils.filter('DISTRO_FEATURES', 'pam', d)}" PACKAGECONFIG[pam] = " , --without-pam, libpam, libpam" do_configure () { ./configure --prefix=${prefix} --exec-prefix=${exec_prefix} echo "INSTALLROOT=${D}" > MCONFIG - if [ "${@bb.utils.contains('PACKAGECONFIG', 'pam', 'pam', '', d)}" != "" ]; then + if [ "${@bb.utils.filter('PACKAGECONFIG', 'pam', d)}" ]; then echo "USE_PAM=1" >> MCONFIG fi @@ -65,7 +65,7 @@ do_install () { 'BINDIR=${bindir}' 'SBINDIR=${sbindir}' \ 'MANDIR=${mandir}' install - if [ "${@bb.utils.contains('PACKAGECONFIG', 'pam', 'pam', '', d)}" != "" ]; then + if [ "${@bb.utils.filter('PACKAGECONFIG', 'pam', d)}" ]; then install -d ${D}${sysconfdir}/pam.d install -m 0644 debian/hosts.equiv ${D}/${sysconfdir} install -m 0644 ${WORKDIR}/rexec.pam ${D}/${sysconfdir}/pam.d/rexec diff --git a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rwho/netkit-rwho/0001-Add-missing-include-path-to-I-options.patch b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rwho/netkit-rwho/0001-Add-missing-include-path-to-I-options.patch new file mode 100644 index 000000000..b1325b317 --- /dev/null +++ b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rwho/netkit-rwho/0001-Add-missing-include-path-to-I-options.patch @@ -0,0 +1,46 @@ +From 55ab6f1389261edff5f4c942bc3b0d8e695856d7 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Wed, 30 Aug 2017 18:11:33 -0700 +Subject: [PATCH 1/2] Add missing include path to -I options + +Fixes errors like +| rwho.c:52:10: fatal error: 'protocols/rwhod.h' file not found +| #include <protocols/rwhod.h> +| ^~~~~~~~~~~~~~~~~~~ + +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- +Upstream-Status: Pending + + rwho/Makefile | 1 + + rwhod/Makefile | 2 ++ + 2 files changed, 3 insertions(+) + +diff --git a/rwho/Makefile b/rwho/Makefile +index 6f86388..67b28d4 100644 +--- a/rwho/Makefile ++++ b/rwho/Makefile +@@ -6,6 +6,7 @@ include ../MRULES + rwho: rwho.o + $(CC) $(LDFLAGS) $^ $(LIBS) -o $@ + ++CFLAGS += -I../include + rwho.o: ../version.h + + install: rwho +diff --git a/rwhod/Makefile b/rwhod/Makefile +index 772b641..9034218 100644 +--- a/rwhod/Makefile ++++ b/rwhod/Makefile +@@ -7,6 +7,8 @@ ifneq ($(USE_GLIBC),1) + CFLAGS += -D_GNU_SOURCE + endif + ++CFLAGS += -I../include ++ + OBJS = rwhod.o + + rwhod: $(OBJS) +-- +2.14.1 + diff --git a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rwho/netkit-rwho/0002-Fix-build-issues-found-with-musl.patch b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rwho/netkit-rwho/0002-Fix-build-issues-found-with-musl.patch new file mode 100644 index 000000000..717b4d73f --- /dev/null +++ b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rwho/netkit-rwho/0002-Fix-build-issues-found-with-musl.patch @@ -0,0 +1,71 @@ +From 2108213242638fa355f662382f55495d91301858 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Wed, 30 Aug 2017 18:13:17 -0700 +Subject: [PATCH 2/2] Fix build issues found with musl + +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- +Upstream-Status: Pending + + ruptime/ruptime.c | 1 + + rwho/rwho.c | 1 + + rwhod/rwhod.c | 5 +++-- + 3 files changed, 5 insertions(+), 2 deletions(-) + +diff --git a/ruptime/ruptime.c b/ruptime/ruptime.c +index 1d4f7b6..f1f043c 100644 +--- a/ruptime/ruptime.c ++++ b/ruptime/ruptime.c +@@ -53,6 +53,7 @@ char ruptime_rcsid[] = + #include <string.h> + #include <errno.h> + #include <time.h> ++#include <fcntl.h> + + struct hs { + char hs_hostname[MAXHOSTNAMELEN]; +diff --git a/rwho/rwho.c b/rwho/rwho.c +index 63919ac..71aec9e 100644 +--- a/rwho/rwho.c ++++ b/rwho/rwho.c +@@ -49,6 +49,7 @@ char rcsid[] = "$Id: rwho.c,v 1.7 1999/08/01 20:44:18 dholland Exp $"; + #include <assert.h> + #include <stdio.h> + #include <time.h> ++#include <fcntl.h> + #include <protocols/rwhod.h> + + #include "../version.h" +diff --git a/rwhod/rwhod.c b/rwhod/rwhod.c +index 54498d0..40cabcf 100644 +--- a/rwhod/rwhod.c ++++ b/rwhod/rwhod.c +@@ -76,6 +76,7 @@ char rcsid[] = + #include <grp.h> + #include <time.h> + #include <stdint.h> ++#include <fcntl.h> + + #include "../version.h" + +@@ -102,7 +103,7 @@ struct nlist nl[] = { + static void broadcaster(void); + static int configure(int s); + static int verify(const char *name); +-#if __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 2) ++#if defined(__GLIBC__) && (__GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 2)) + static int getloadavg(double ptr[3], int n); + #endif + +@@ -549,7 +550,7 @@ sendpacket(struct whod *wd) + } + } + +-#if __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 2) ++#if defined(__GLIBC__) && (__GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 2)) + /* + * Taken from: + * +-- +2.14.1 + diff --git a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rwho/netkit-rwho_0.17.bb b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rwho/netkit-rwho_0.17.bb index 04baa4286..5685f03d6 100644 --- a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rwho/netkit-rwho_0.17.bb +++ b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-rwho/netkit-rwho_0.17.bb @@ -8,7 +8,9 @@ SRC_URI = "${DEBIAN_MIRROR}/main/n/netkit-rwho/netkit-rwho_${PV}.orig.tar.gz;nam ${DEBIAN_MIRROR}/main/n/netkit-rwho/netkit-rwho_${PV}-13.debian.tar.gz;name=patch13 \ file://rwhod \ file://rwhod.default \ -" + file://0001-Add-missing-include-path-to-I-options.patch \ + file://0002-Fix-build-issues-found-with-musl.patch \ + " SRC_URI[archive.md5sum] = "0f71620d45d472f89134ba0d74242e75" SRC_URI[archive.sha256sum] = "0409e2ce4bfdb2dacb2c193d0fedfc49bb975cb057c5c6b0ffcca603a1188da7" SRC_URI[patch13.md5sum] = "82ed5a3c6b0bbf00b36508b9787963b9" diff --git a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-telnet/files/0001-telnet-telnetd-Fix-print-format-strings.patch b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-telnet/files/0001-telnet-telnetd-Fix-print-format-strings.patch new file mode 100644 index 000000000..f2f1b12e2 --- /dev/null +++ b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-telnet/files/0001-telnet-telnetd-Fix-print-format-strings.patch @@ -0,0 +1,66 @@ +From 7a3095d1e9b7c73f9dca56250f433bcfc7cb660e Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Tue, 27 Jun 2017 10:15:34 -0700 +Subject: [PATCH] telnet/telnetd: Fix print format strings + +Fixes build with hardening flags + +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + telnet/utilities.cc | 6 +++--- + telnetd/utility.c | 6 +++--- + 2 files changed, 6 insertions(+), 6 deletions(-) + +diff --git a/telnet/utilities.cc b/telnet/utilities.cc +index 66839ab..36f0731 100644 +--- a/telnet/utilities.cc ++++ b/telnet/utilities.cc +@@ -583,17 +583,17 @@ void printsub(int direction, unsigned char *pointer, int length) { + case ENV_VAR: + if (pointer[1] == TELQUAL_SEND) + goto def_case; +- fprintf(NetTrace, "\" VAR " + noquote); ++ fprintf(NetTrace, "%s", "\" VAR " + noquote); + noquote = 2; + break; + + case ENV_VALUE: +- fprintf(NetTrace, "\" VALUE " + noquote); ++ fprintf(NetTrace, "%s", "\" VALUE " + noquote); + noquote = 2; + break; + + case ENV_ESC: +- fprintf(NetTrace, "\" ESC " + noquote); ++ fprintf(NetTrace, "%s", "\" ESC " + noquote); + noquote = 2; + break; + +diff --git a/telnetd/utility.c b/telnetd/utility.c +index 29b7da1..75314cb 100644 +--- a/telnetd/utility.c ++++ b/telnetd/utility.c +@@ -909,17 +909,17 @@ printsub(char direction, unsigned char *pointer, int length) + case ENV_VAR: + if (pointer[1] == TELQUAL_SEND) + goto def_case; +- netoprintf("\" VAR " + noquote); ++ netoprintf("%s", "\" VAR " + noquote); + noquote = 2; + break; + + case ENV_VALUE: +- netoprintf("\" VALUE " + noquote); ++ netoprintf("%s", "\" VALUE " + noquote); + noquote = 2; + break; + + case ENV_ESC: +- netoprintf("\" ESC " + noquote); ++ netoprintf("%s", "\" ESC " + noquote); + noquote = 2; + break; + +-- +2.13.2 + diff --git a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-telnet/netkit-telnet_0.17.bb b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-telnet/netkit-telnet_0.17.bb index 9438adc0f..54a58c8a1 100644 --- a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-telnet/netkit-telnet_0.17.bb +++ b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-telnet/netkit-telnet_0.17.bb @@ -5,11 +5,12 @@ LICENSE = "BSD" LIC_FILES_CHKSUM = "file://telnet/telnet.cc;beginline=2;endline=3;md5=780868e7b566313e70cb701560ca95ef" SRC_URI = "ftp://ftp.uk.linux.org/pub/linux/Networking/netkit/${BP}.tar.gz \ - file://To-aviod-buffer-overflow-in-telnet.patch \ - file://Warning-fix-in-the-step-of-install.patch \ - file://telnet-xinetd \ - file://cross-compile.patch \ -" + file://To-aviod-buffer-overflow-in-telnet.patch \ + file://Warning-fix-in-the-step-of-install.patch \ + file://telnet-xinetd \ + file://cross-compile.patch \ + file://0001-telnet-telnetd-Fix-print-format-strings.patch \ + " EXTRA_OEMAKE = "INSTALLROOT=${D} SBINDIR=${sbindir} DAEMONMODE=755 \ MANMODE=644 MANDIR=${mandir}" diff --git a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-tftp/netkit-tftp/0001-tftp-Include-missing-fcntl.h.patch b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-tftp/netkit-tftp/0001-tftp-Include-missing-fcntl.h.patch new file mode 100644 index 000000000..78936907f --- /dev/null +++ b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-tftp/netkit-tftp/0001-tftp-Include-missing-fcntl.h.patch @@ -0,0 +1,27 @@ +From fa57e161fc953264a75d50a787cb83983e60acc7 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Wed, 30 Aug 2017 18:30:02 -0700 +Subject: [PATCH] tftp: Include missing fcntl.h + +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- +Upstream-Status: Pending + + tftp/main.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/tftp/main.c b/tftp/main.c +index 8c54843..5c9b698 100644 +--- a/tftp/main.c ++++ b/tftp/main.c +@@ -63,6 +63,7 @@ char main_rcsid[] = + #include <ctype.h> + #include <netdb.h> + #include <unistd.h> ++#include <fcntl.h> + + #include "tftpsubs.h" /* for mysignal() */ + +-- +2.14.1 + diff --git a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-tftp/netkit-tftp_0.17.bb b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-tftp/netkit-tftp_0.17.bb index 67a541d25..92c13e850 100644 --- a/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-tftp/netkit-tftp_0.17.bb +++ b/import-layers/meta-openembedded/meta-networking/recipes-netkit/netkit-tftp/netkit-tftp_0.17.bb @@ -6,9 +6,10 @@ DEPENDS = "tcp-wrappers" LIC_FILES_CHKSUM = "file://tftp/tftp.c;beginline=2;endline=3;md5=84d2cfe1e60863a7d82648734ba4d30c" SRC_URI = "${DEBIAN_MIRROR}/main/n/${BPN}/${BPN}_${PV}.orig.tar.gz;name=archive \ - ${DEBIAN_MIRROR}/main/n/${BPN}/${BPN}_${PV}-18.diff.gz;name=patch18 \ - file://tftp.conf \ -" + ${DEBIAN_MIRROR}/main/n/${BPN}/${BPN}_${PV}-18.diff.gz;name=patch18 \ + file://tftp.conf \ + file://0001-tftp-Include-missing-fcntl.h.patch \ + " SRC_URI[archive.md5sum] = "b7262c798e2ff50e29c2ff50dfd8d6a8" SRC_URI[archive.sha256sum] = "3a43c0010d4e61f412563fd83769d4667d8b8e82903526d21cb9205fe55ad14d" |