From 4f2d7949f03e1c198bc888f2d05f421d35c57e21 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Mon, 9 Oct 2017 18:53:29 +0100 Subject: reinit the tree, so we can have metadata --- .../netkit-bootparamd/files/0.17-jumpstart.patch | 25 ++++++++++++++++++++++ .../netkit-bootparamd/files/0.17-libtirpc.patch | 15 +++++++++++++ net-misc/netkit-bootparamd/files/bootparamd.confd | 3 +++ net-misc/netkit-bootparamd/files/bootparamd.initd | 25 ++++++++++++++++++++++ 4 files changed, 68 insertions(+) create mode 100644 net-misc/netkit-bootparamd/files/0.17-jumpstart.patch create mode 100644 net-misc/netkit-bootparamd/files/0.17-libtirpc.patch create mode 100644 net-misc/netkit-bootparamd/files/bootparamd.confd create mode 100644 net-misc/netkit-bootparamd/files/bootparamd.initd (limited to 'net-misc/netkit-bootparamd/files') diff --git a/net-misc/netkit-bootparamd/files/0.17-jumpstart.patch b/net-misc/netkit-bootparamd/files/0.17-jumpstart.patch new file mode 100644 index 000000000000..41b471b5075f --- /dev/null +++ b/net-misc/netkit-bootparamd/files/0.17-jumpstart.patch @@ -0,0 +1,25 @@ +diff -urN netkit-bootparamd-0.17.old/rpc.bootparamd/rpc.bootparamd.c netkit-bootparamd-0.17/rpc.bootparamd/rpc.bootparamd.c +--- netkit-bootparamd-0.17.old/rpc.bootparamd/rpc.bootparamd.c 2000-07-22 12:23:56.000000000 -0400 ++++ netkit-bootparamd-0.17/rpc.bootparamd/rpc.bootparamd.c 2004-09-13 17:42:43.000000000 -0400 +@@ -136,11 +136,16 @@ + strncpy(path, where, sizeof(path)); + path[sizeof(path)-1] = 0; + he = gethostbyname(hostname); +- if (!he) goto failed; +- bcopy( he->h_addr, &res.server_address.bp_address_u.ip_addr, 4); +- res.server_name = hostname; +- res.server_path = path; +- res.server_address.address_type = IP_ADDR_TYPE; ++ if (!he) { /* jumpstart parameters are not valid hosts */ ++ res.server_name = hostname; ++ res.server_path = path; ++ bzero(&res.server_address.bp_address_u.ip_addr,4); ++ } else { ++ bcopy( he->h_addr, &res.server_address.bp_address_u.ip_addr, 4); ++ res.server_name = hostname; ++ res.server_path = path; ++ res.server_address.address_type = IP_ADDR_TYPE; ++ } + } + else { /* special for dump, answer with null strings */ + if (!strcmp(getfile->file_id, "dump")) { diff --git a/net-misc/netkit-bootparamd/files/0.17-libtirpc.patch b/net-misc/netkit-bootparamd/files/0.17-libtirpc.patch new file mode 100644 index 000000000000..1cdf263efb25 --- /dev/null +++ b/net-misc/netkit-bootparamd/files/0.17-libtirpc.patch @@ -0,0 +1,15 @@ +diff -ruN netkit-bootparamd-0.17.orig/rpc.bootparamd/main.c netkit-bootparamd-0.17/rpc.bootparamd/main.c +--- netkit-bootparamd-0.17.orig/rpc.bootparamd/main.c 2000-07-22 16:23:56.000000000 -0000 ++++ netkit-bootparamd-0.17/rpc.bootparamd/main.c 2017-10-04 14:17:49.887552574 -0000 +@@ -17,9 +17,11 @@ + + + #ifdef __GLIBC__ ++#ifndef _TIRPC_RPC_H + /* quick fix */ + void get_myaddress(struct sockaddr_in *); + #endif ++#endif + + int debug = 0; + int dolog = 0; diff --git a/net-misc/netkit-bootparamd/files/bootparamd.confd b/net-misc/netkit-bootparamd/files/bootparamd.confd new file mode 100644 index 000000000000..f7e233a46de3 --- /dev/null +++ b/net-misc/netkit-bootparamd/files/bootparamd.confd @@ -0,0 +1,3 @@ +# + +OPTS_RPC_BOOTPARAMD="-s" diff --git a/net-misc/netkit-bootparamd/files/bootparamd.initd b/net-misc/netkit-bootparamd/files/bootparamd.initd new file mode 100644 index 000000000000..251e8994969a --- /dev/null +++ b/net-misc/netkit-bootparamd/files/bootparamd.initd @@ -0,0 +1,25 @@ +#!/sbin/openrc-run +# Copyright 1999-2010 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +[ -e /etc/conf.d/bootparamd ] && . /etc/conf.d/bootparamd + +rpc_bin=/usr/sbin/rpc.bootparamd + +depend() { + use ypbind net + need portmap + after quota +} + +start() { + ebegin "Starting bootparamd" + ${rpc_bin} ${OPTS_RPC_BOOTPARAMD} + eend $? "make sure DNOTIFY support is enabled ..." +} + +stop() { + ebegin "Stopping bootparamd" + start-stop-daemon --stop --exec ${rpc_bin} + eend $? +} -- cgit v1.2.3