From 56bd759df1d0c750a065b8c845e93d5dfa6b549d Mon Sep 17 00:00:00 2001 From: "Robin H. Johnson" Date: Sat, 8 Aug 2015 13:49:04 -0700 Subject: proj/gentoo: Initial commit MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson X-Thanks: Alec Warner - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring - wrote much python to improve cvs2svn X-Thanks: Rich Freeman - validation scripts X-Thanks: Patrick Lauer - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed --- .../files/softflowd-0.9.9-_GNU_SOURCE.patch | 13 ++++++ .../softflowd/files/softflowd-0.9.9-no-strip.patch | 12 +++++ net-analyzer/softflowd/files/softflowd.confd | 9 ++++ net-analyzer/softflowd/files/softflowd.initd | 54 ++++++++++++++++++++++ 4 files changed, 88 insertions(+) create mode 100644 net-analyzer/softflowd/files/softflowd-0.9.9-_GNU_SOURCE.patch create mode 100644 net-analyzer/softflowd/files/softflowd-0.9.9-no-strip.patch create mode 100644 net-analyzer/softflowd/files/softflowd.confd create mode 100644 net-analyzer/softflowd/files/softflowd.initd (limited to 'net-analyzer/softflowd/files') diff --git a/net-analyzer/softflowd/files/softflowd-0.9.9-_GNU_SOURCE.patch b/net-analyzer/softflowd/files/softflowd-0.9.9-_GNU_SOURCE.patch new file mode 100644 index 00000000000..cb4844803e0 --- /dev/null +++ b/net-analyzer/softflowd/files/softflowd-0.9.9-_GNU_SOURCE.patch @@ -0,0 +1,13 @@ +setresuid and setresgid need _GNU_SOURCE which clashes with _BSD_SOURCE + +--- a/configure.ac ++++ b/configure.ac +@@ -87,7 +87,7 @@ + AC_SEARCH_LIBS(socket, socket) + AC_CHECK_LIB(pcap, pcap_open_live) + +-AC_CHECK_FUNCS(closefrom daemon setresuid setreuid setresgid setgid strlcpy strlcat) ++AC_CHECK_FUNCS(closefrom daemon setreuid setgid strlcpy strlcat) + + AC_CHECK_TYPES([u_int64_t, int64_t, uint64_t, u_int32_t, int32_t, uint32_t]) + AC_CHECK_TYPES([u_int16_t, int16_t, uint16_t, u_int8_t, int8_t, uint8_t]) diff --git a/net-analyzer/softflowd/files/softflowd-0.9.9-no-strip.patch b/net-analyzer/softflowd/files/softflowd-0.9.9-no-strip.patch new file mode 100644 index 00000000000..c48603a7f49 --- /dev/null +++ b/net-analyzer/softflowd/files/softflowd-0.9.9-no-strip.patch @@ -0,0 +1,12 @@ +--- a/Makefile.in ++++ b/Makefile.in +@@ -52,7 +52,7 @@ + $(srcdir)/mkinstalldirs $(DESTDIR)$(sbindir) + [ -d $(DESTDIR)$(mandir)/man8 ] || \ + $(srcdir)/mkinstalldirs $(DESTDIR)$(mandir)/man8 +- $(INSTALL) -m 0755 -s softflowd $(DESTDIR)$(sbindir)/softflowd +- $(INSTALL) -m 0755 -s softflowctl $(DESTDIR)$(sbindir)/softflowctl ++ $(INSTALL) -m 0755 softflowd $(DESTDIR)$(sbindir)/softflowd ++ $(INSTALL) -m 0755 softflowctl $(DESTDIR)$(sbindir)/softflowctl + $(INSTALL) -m 0644 softflowd.8 $(DESTDIR)$(mandir)/man8/softflowd.8 + $(INSTALL) -m 0644 softflowctl.8 $(DESTDIR)$(mandir)/man8/softflowctl.8 diff --git a/net-analyzer/softflowd/files/softflowd.confd b/net-analyzer/softflowd/files/softflowd.confd new file mode 100644 index 00000000000..dc1a36c874c --- /dev/null +++ b/net-analyzer/softflowd/files/softflowd.confd @@ -0,0 +1,9 @@ +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# Copy conf file to softflowd.interface + +# SOFTFLOWD_COLLECTOR=host:port +# SOFTFLOWD_TIMEOUTS="maxlife=600" +# SOFTFLOWD_MAXFLOWS=17000 +# SOFTFLOWD_EXTRA= +# SOFTFLOWD_INTERFACE_IDX= diff --git a/net-analyzer/softflowd/files/softflowd.initd b/net-analyzer/softflowd/files/softflowd.initd new file mode 100644 index 00000000000..b29d3eaaf66 --- /dev/null +++ b/net-analyzer/softflowd/files/softflowd.initd @@ -0,0 +1,54 @@ +#!/sbin/runscript +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +depend() { + need net +} + +softflowd_checkconfig() { + SOFTFLOWD_INTERFACE=${SVCNAME#*.} + if [ ${SOFTFLOWD_INTERFACE} = ${SVCNAME} ]; then + eerror "You have to create an init script for each interface:" + eerror "ln -s softflowd /etc/init.d/softflowd.eth0" + return 1 + fi + + if [ -z "${SOFTFLOWD_COLLECTOR}" ]; then + eerror "Specify the host and port that the accounting datagrams are to be" + eerror "sent to in /etc/conf.d/${SVCNAME}." + eerror "Example: SOFTFLOWD_COLLECTOR=collector.example.com:9995" + return 1 + fi + SOFTFLOWD_PIDFILE="/var/run/softflowd.${SOFTFLOWD_INTERFACE}.pid" + SOFTFLOWD_CTLFILE="/var/run/softflowd.${SOFTFLOWD_INTERFACE}.ctl" +} + + +start() { + softflowd_checkconfig || return 1 + + ebegin "Starting softflowd on interface ${SOFTFLOWD_INTERFACE}" + iface_arg=${SOFTFLOWD_INTERFACE} + [ -n "${SOFTFLOWD_INTERFACE_IDX}" ] && iface_arg="${SOFTFLOWD_INTERFACE_IDX}:${iface_arg}" + start-stop-daemon --start \ + --exec /usr/sbin/softflowd \ + -- -i "${iface_arg}" \ + -n "${SOFTFLOWD_COLLECTOR}" \ + -p "${SOFTFLOWD_PIDFILE}" \ + -c "${SOFTFLOWD_CTLFILE}" \ + -t "${SOFTFLOWD_TIMEOUTS-maxlife=600}" \ + -m "${SOFTFLOWD_MAXFLOWS-17000}" \ + ${SOFTFLOWD_EXTRA} + eend $? +} + +stop() { + softflowd_checkconfig || return 1 + + ebegin "Stopping softflowd on interface ${SOFTFLOWD_INTERFACE}" + # use softflowd's own way to shut it down + /usr/sbin/softflowctl -c ${SOFTFLOWD_CTLFILE} shutdown + eend $? +} -- cgit v1.2.1