From: "Sergey Popov" <pinkbyte@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: net-vpn/pptpd/files/, net-vpn/pptpd/
Date: Wed, 8 Jul 2020 09:45:50 +0000 (UTC) [thread overview]
Message-ID: <1594201418.79eb49c4b63ab163c6633247610596195f237bda.pinkbyte@gentoo> (raw)
commit: 79eb49c4b63ab163c6633247610596195f237bda
Author: Sergey Popov <pinkbyte <AT> gentoo <DOT> org>
AuthorDate: Wed Jul 8 09:30:29 2020 +0000
Commit: Sergey Popov <pinkbyte <AT> gentoo <DOT> org>
CommitDate: Wed Jul 8 09:43:38 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=79eb49c4
net-vpn/pptpd: revision bump
Fix library path for plugins
Fix building with Musl
Closes: https://bugs.gentoo.org/716210
Closes: https://bugs.gentoo.org/730068
Package-Manager: Portage-2.3.99, Repoman-2.3.22
Signed-off-by: Sergey Popov <pinkbyte <AT> gentoo.org>
net-vpn/pptpd/files/pptpd-1.4.0-libdir.patch | 24 +++++++++
net-vpn/pptpd/files/pptpd-1.4.0-musl.patch | 16 ++++++
net-vpn/pptpd/pptpd-1.4.0-r3.ebuild | 81 ++++++++++++++++++++++++++++
3 files changed, 121 insertions(+)
diff --git a/net-vpn/pptpd/files/pptpd-1.4.0-libdir.patch b/net-vpn/pptpd/files/pptpd-1.4.0-libdir.patch
new file mode 100644
index 00000000000..898c3aea89d
--- /dev/null
+++ b/net-vpn/pptpd/files/pptpd-1.4.0-libdir.patch
@@ -0,0 +1,24 @@
+diff -r -U 3 pptpd-1.4.0.orig/Makefile.am pptpd-1.4.0/Makefile.am
+--- pptpd-1.4.0.orig/Makefile.am 2020-06-29 00:24:23.301857353 +0300
++++ pptpd-1.4.0/Makefile.am 2020-06-29 00:25:16.072686760 +0300
+@@ -11,7 +11,7 @@
+ ## warning with -Wmissing-prototypes).
+ ## -Wmissing-prototypes removed (eg, Linux 2.2.6 headers
+ ## aren't up to it).
+-CFLAGS += -fno-builtin -Wall -DSBINDIR='"$(sbindir)"'
++CFLAGS += -fno-builtin -Wall -DSBINDIR='"$(sbindir)"' -DLIBDIR='"$(libdir)"'
+ #CFLAGS = -O2 -fno-builtin -Wall -ansi -DSBINDIR='"$(sbindir)"'
+ #CFLAGS = -O2 -fno-builtin -Wall -ansi -pedantic -Wmissing-prototypes -Werror -DSBINDIR='"$(sbindir)"'
+
+diff -r -U 3 pptpd-1.4.0.orig/pptpctrl.c pptpd-1.4.0/pptpctrl.c
+--- pptpd-1.4.0.orig/pptpctrl.c 2013-10-23 08:53:19.000000000 +0400
++++ pptpd-1.4.0/pptpctrl.c 2020-06-29 00:25:23.356525131 +0300
+@@ -786,7 +786,7 @@
+
+ if (pptp_logwtmp) {
+ pppd_argv[an++] = "plugin";
+- pppd_argv[an++] = "/usr/lib/pptpd/pptpd-logwtmp.so";
++ pppd_argv[an++] = LIBDIR "/pptpd/pptpd-logwtmp.so";
+ pppd_argv[an++] = "pptpd-original-ip";
+ pppd_argv[an++] = inet_ntoa(inetaddrs[1]);
+ }
diff --git a/net-vpn/pptpd/files/pptpd-1.4.0-musl.patch b/net-vpn/pptpd/files/pptpd-1.4.0-musl.patch
new file mode 100644
index 00000000000..998a07acf7e
--- /dev/null
+++ b/net-vpn/pptpd/files/pptpd-1.4.0-musl.patch
@@ -0,0 +1,16 @@
+Modified patch from Alpine Linux
+https://git.alpinelinux.org/aports/plain/main/pptpd/fix_MSG_TRYHARD.patch
+
+--- a/bcrelay.c
++++ b/bcrelay.c
+@@ -103,6 +103,10 @@
+ #include "our_syslog.h"
+ #include "our_getopt.h"
+
++#ifndef MSG_TRYHARD
++ #define MSG_TRYHARD MSG_DONTROUTE
++#endif
++
+ //#define VERSION "1.0"
+
+ /* uncomment if you compile this without poptop's configure script */
diff --git a/net-vpn/pptpd/pptpd-1.4.0-r3.ebuild b/net-vpn/pptpd/pptpd-1.4.0-r3.ebuild
new file mode 100644
index 00000000000..17768c52b76
--- /dev/null
+++ b/net-vpn/pptpd/pptpd-1.4.0-r3.ebuild
@@ -0,0 +1,81 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit autotools eutils flag-o-matic toolchain-funcs
+
+DESCRIPTION="Linux Point-to-Point Tunnelling Protocol Server"
+HOMEPAGE="http://poptop.sourceforge.net/"
+SRC_URI="mirror://sourceforge/poptop/${P}.tar.gz"
+
+SLOT="0"
+LICENSE="GPL-2"
+KEYWORDS="~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86"
+IUSE="gre-extreme-debug tcpd"
+
+DEPEND="net-dialup/ppp:=
+ tcpd? ( sys-apps/tcp-wrappers )"
+RDEPEND="${DEPEND}"
+
+DOCS=( AUTHORS ChangeLog NEWS README TODO )
+
+PATCHES=(
+ "${FILESDIR}/${P}-gentoo.patch"
+ "${FILESDIR}/${P}-sandbox-fix.patch"
+ "${FILESDIR}/${P}-pidfile.patch"
+ "${FILESDIR}/${P}-libdir.patch"
+ "${FILESDIR}/${P}-musl.patch"
+)
+
+src_prepare() {
+ # Match pptpd-logwtmp.so's version with pppd's version (#89895)
+ local PPPD_VER=`best_version net-dialup/ppp`
+ PPPD_VER=${PPPD_VER#*/*-} #reduce it to ${PV}-${PR}
+ PPPD_VER=${PPPD_VER%%[_-]*} # main version without beta/pre/patch/revision
+ sed -i -e "s:\\(#define[ \\t]*VERSION[ \\t]*\\)\".*\":\\1\"${PPPD_VER}\":" plugins/patchlevel.h || die
+
+ # configure.in is actually configure.ac
+ mv configure.in configure.ac || die
+
+ # Automake 1.13 compatibility, bug #469476
+ sed -i -e 's/AM_CONFIG_HEADER/AC_CONFIG_HEADER/' configure.ac || die 'sed on configure.ac failed'
+
+ # remove 'missing' script to prevent warnings
+ rm missing || die 'remove missing script failed'
+
+ # respect compiler, bug #461722
+ tc-export CC
+
+ # Call to default src_prepare to apply patches
+ default
+
+ eautoreconf
+}
+
+src_configure() {
+ use gre-extreme-debug && append-cppflags "-DLOG_DEBUG_GRE_ACCEPTING_PACKET"
+ econf \
+ --enable-bcrelay \
+ $(use tcpd && echo "--with-libwrap")
+}
+
+src_compile() {
+ emake COPTS="${CFLAGS}"
+}
+
+src_install() {
+ default
+
+ insinto /etc
+ doins samples/pptpd.conf
+
+ insinto /etc/ppp
+ doins samples/options.pptpd
+
+ newinitd "${FILESDIR}/pptpd-init-r2" pptpd
+ newconfd "${FILESDIR}/pptpd-confd" pptpd
+
+ dodoc README.*
+ dodoc -r samples
+}
next reply other threads:[~2020-07-08 9:45 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-08 9:45 Sergey Popov [this message]
-- strict thread matches above, loose matches on Subject: below --
2023-04-28 20:52 [gentoo-commits] repo/gentoo:master commit in: net-vpn/pptpd/files/, net-vpn/pptpd/ Mike Gilbert
2024-04-27 1:11 Sam James
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1594201418.79eb49c4b63ab163c6633247610596195f237bda.pinkbyte@gentoo \
--to=pinkbyte@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox