diff options
-rw-r--r-- | net-misc/portfwd/files/portfwd-0.29-build-system.patch | 76 | ||||
-rw-r--r-- | net-misc/portfwd/portfwd-0.29-r1.ebuild | 45 | ||||
-rw-r--r-- | net-misc/portfwd/portfwd-0.29-r2.ebuild | 33 |
3 files changed, 109 insertions, 45 deletions
diff --git a/net-misc/portfwd/files/portfwd-0.29-build-system.patch b/net-misc/portfwd/files/portfwd-0.29-build-system.patch new file mode 100644 index 000000000000..fb9649b65cd9 --- /dev/null +++ b/net-misc/portfwd/files/portfwd-0.29-build-system.patch @@ -0,0 +1,76 @@ +--- a/Makefile.am ++++ b/Makefile.am +@@ -1,4 +1,3 @@ + SUBDIRS = getopt src tools doc + +-docdir = $(prefix)/doc/portfwd + doc_DATA = COPYING README CREDITS TODO +--- a/configure.in ++++ b/configure.in +@@ -8,6 +8,7 @@ dnl Checks for programs. + AC_PROG_CC + AC_PROG_CXX + AC_PROG_YACC ++AM_PROG_AR + AM_PROG_LEX + AC_PROG_RANLIB + +@@ -45,6 +46,7 @@ dnl ) + dnl Checks for MSG_PROXY symbol + AC_TRY_RUN( + [ ++#include <stdlib.h> + #include <sys/socket.h> + int main() + { +--- a/doc/Makefile.am ++++ b/doc/Makefile.am +@@ -3,5 +3,4 @@ + man_MANS = portfwd.8 portfwd.cfg.5 + noinst_DATA = INSTALL.configure + +-docdir = $(prefix)/doc/portfwd + doc_DATA = FAQ conf.txt +--- a/getopt/Makefile.am ++++ b/getopt/Makefile.am +@@ -3,9 +3,9 @@ noinst_LIBRARIES = libgetopt.a + libgetopt_a_SOURCES = getopt.c getopt1.c + + getopt.o: getopt.c +- $(CC) -o $@ -c $< ++ $(CC) @CFLAGS@ -o $@ -c $< + cp $@ ../src + getopt1.o: getopt1.c +- $(CC) -o $@ -c $< ++ $(CC) @CFLAGS@ -o $@ -c $< + cp $@ ../src + +--- a/getopt/getopt.c ++++ b/getopt/getopt.c +@@ -91,6 +91,8 @@ + # endif + #endif + ++#include <string.h> ++ + /* This version of `getopt' appears to the caller like standard Unix `getopt' + but it behaves differently for the user, since it allows the user + to intersperse the options with the other arguments. +--- a/src/Makefile.am ++++ b/src/Makefile.am +@@ -1,5 +1,5 @@ +-CFLAGS = -Wall -ggdb -O3 -DPORTFWD_CONF=\"$(sysconfdir)/portfwd.cfg\" +-CXXFLAGS = $(CFLAGS) ++CFLAGS = @CFLAGS@ -Wall -DPORTFWD_CONF=\"$(sysconfdir)/portfwd.cfg\" ++CPPFLAGS = @CXXFLAGS@ -Wall -DPORTFWD_CONF=\"$(sysconfdir)/portfwd.cfg\" + INCLUDES = -I$(top_srcdir)/src + + sbin_PROGRAMS = portfwd +--- a/tools/Makefile.am ++++ b/tools/Makefile.am +@@ -1,4 +1,4 @@ +-CXXFLAGS = -Wall -g -O3 ++CPPFLAGS = @CXXFLAGS@ -Wall -DPORTFWD_CONF=\"$(sysconfdir)/portfwd.cfg\" + INCLUDES = -I$(top_srcdir)/src + + noinst_PROGRAMS = t_vector udp_rcv udp_snd diff --git a/net-misc/portfwd/portfwd-0.29-r1.ebuild b/net-misc/portfwd/portfwd-0.29-r1.ebuild deleted file mode 100644 index c64a3293d245..000000000000 --- a/net-misc/portfwd/portfwd-0.29-r1.ebuild +++ /dev/null @@ -1,45 +0,0 @@ -# Copyright 1999-2021 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=6 -inherit autotools systemd - -DESCRIPTION="Port Forwarding Daemon" -SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz" -HOMEPAGE="http://portfwd.sourceforge.net" -LICENSE="GPL-2" - -SLOT="0" -KEYWORDS="amd64 ~ia64 ~ppc ~sparc x86" - -src_prepare() { - default - - cd src - sed -iorig \ - -e "s:^CFLAGS =.*:CFLAGS = @CFLAGS@ -Wall -DPORTFWD_CONF=\\\\\"\$(sysconfdir)/portfwd.cfg\\\\\":" \ - -e "s:^CXXFLAGS =.*:CPPFLAGS = @CXXFLAGS@ -Wall -DPORTFWD_CONF=\\\\\"\$(sysconfdir)/portfwd.cfg\\\\\":" \ - Makefile.am || die - cd ../tools - sed -iorig \ - -e "s:^CXXFLAGS =.*:CPPFLAGS = @CXXFLAGS@ -Wall -DPORTFWD_CONF=\\\\\"\$(sysconfdir)/portfwd.cfg\\\\\":" \ - Makefile.am || die - cd ../getopt - sed -iorig -e "s:$.CC.:\$(CC) @CFLAGS@:g" Makefile.am || die - cd ../doc - sed -iorig -e "s:/doc/portfwd:/share/doc/$P:" Makefile.am || die - cd .. - sed -iorig -e "s:/doc/portfwd:/share/doc/$P:" Makefile.am || die - - eautoreconf -} - -src_install() { - default - - dodoc cfg/* - - newinitd "${FILESDIR}"/${PN}.init ${PN} - newconfd "${FILESDIR}"/${PN}.confd ${PN} - systemd_dounit "${FILESDIR}"/${PN}.service -} diff --git a/net-misc/portfwd/portfwd-0.29-r2.ebuild b/net-misc/portfwd/portfwd-0.29-r2.ebuild new file mode 100644 index 000000000000..98f201afdb05 --- /dev/null +++ b/net-misc/portfwd/portfwd-0.29-r2.ebuild @@ -0,0 +1,33 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit autotools systemd + +DESCRIPTION="Port Forwarding Daemon" +HOMEPAGE="http://portfwd.sourceforge.net" +SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 ~ia64 ~ppc ~sparc x86" + +PATCHES=( + "${FILESDIR}"/${PN}-0.29-build-system.patch +) + +src_prepare() { + default + eautoreconf +} + +src_install() { + default + + dodoc cfg/* + + newinitd "${FILESDIR}"/${PN}.init ${PN} + newconfd "${FILESDIR}"/${PN}.confd ${PN} + systemd_dounit "${FILESDIR}"/${PN}.service +} |