summaryrefslogtreecommitdiff
path: root/net-vpn/pptpd
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2023-04-28 23:13:34 +0100
committerV3n3RiX <venerix@koprulu.sector>2023-04-28 23:13:34 +0100
commitb8395ecde09583851e86d0512adec19f7308d791 (patch)
tree80f0b26997037858eca514eecb197b37300ba4bb /net-vpn/pptpd
parent670fe3b64a21a723fda1e52fe61cad2327f81f67 (diff)
gentoo auto-resync : 28:04:2023 - 23:13:34
Diffstat (limited to 'net-vpn/pptpd')
-rw-r--r--net-vpn/pptpd/Manifest3
-rw-r--r--net-vpn/pptpd/files/pptpd-1.4.0-ppp-2.5.0.patch83
-rw-r--r--net-vpn/pptpd/pptpd-1.4.0-r3.ebuild29
3 files changed, 99 insertions, 16 deletions
diff --git a/net-vpn/pptpd/Manifest b/net-vpn/pptpd/Manifest
index 7c99576c3f89..2f208acb61bd 100644
--- a/net-vpn/pptpd/Manifest
+++ b/net-vpn/pptpd/Manifest
@@ -2,9 +2,10 @@ AUX pptpd-1.4.0-gentoo.patch 2360 BLAKE2B ca5ac7babf0ee6752305659ca50ce4c7972c43
AUX pptpd-1.4.0-libdir.patch 1205 BLAKE2B 4b0d269b4de78346ffe577379824510dfb330e84606ff1b56abda08a4296935c947a0c61188475007c565cb5d5ba987beca61020e20a8cf050c82ff2f9335502 SHA512 927254c2527eada485d7d86940858835712d272fea818e17a6dd81878843b1a58dd6f1230fdc1b5e5ac0cd0fd726956d816655884ac7b8f6ee3c2e6b20e6beb4
AUX pptpd-1.4.0-musl.patch 381 BLAKE2B b3094ada7db21fcf5e249512d0f3aabb4782562e82dcda1fedfc8d78f70f59a062751e2cc6c03789871cc8b2f79bece8b6f125a7849eefbfca566e0b083d3194 SHA512 ac48f18aea8ce89c55bb102705912391fa4d0f3da237261110dfc3ec04b7c461cd4676419bffeabc52afddb78c8f7a2494df6a60bbd507f306f01be592b9e2b3
AUX pptpd-1.4.0-pidfile.patch 1348 BLAKE2B 7b19d05f5a8b18069c05e110963cf032dc68c7558a970c00126162d7f7d71a702d4b64f40105a36b5da879b8a6bbd6b16785560ecb1b3214bd91aeac20f00378 SHA512 0d0e4df9cc1827345001ebfb88ec87bdce818792aa2243e92127643ffbf64a2c7d62cb5cd26930085d7533ae32135cbcc36da755adce3297bcad4abf764b3b6e
+AUX pptpd-1.4.0-ppp-2.5.0.patch 2351 BLAKE2B a1c0946549769de653a2b637b983096a4be173b04ceccce8e6f51933db5e79617a5951835a767b98756869b94dcb402057c33f043a90cc4bacbbb5bc4d65c43f SHA512 5968185fe4529543d68f9eb8dee436419ec5ad0643078c286adf9e2cfbc88fc7c2f1a2837a08d53ea73f17576bb9e9cb5ef3b22b9ca22ee5d4b6d855dac3efd6
AUX pptpd-1.4.0-sandbox-fix.patch 528 BLAKE2B 1b784cbf9eb1699a5c8e31a6ebb64035e9656a175b81ca4df778e9799b22fdb283c851d66e3ba0b9c056cf099011be049bd71d1b47d9839786538d1d436ac0f9 SHA512 7f80c66185207f4d14fd6163e41fed3acc7ffdeea91d3f62e000ab1fcbe6abd8f3bb6a1ea927a9fa29ef1b38b2c0ffe364625e155474c4145126de674cd7f2bb
AUX pptpd-confd 131 BLAKE2B b1cf43035bb96859e3f69ad2ba8d161fd5e7c98370f407767a74ec9e87fd3187ec127155171bebf3e0655d076d2edb640993ec4445672abb40a9d87fb5a6b008 SHA512 59f118715cf6c36442687a58f46a54519fb5125383e85c4fa352a4c97f8a4e19f46c9715330550755eb9691e8174b70cdfab48fbd14c2707364e8083d6baa488
AUX pptpd-init-r2 325 BLAKE2B 492d4a17910fd45475337376570e23b2193f0b5471e82a575465eb139a9cf0f9296388962e3dc2584784a4be6aac17edf4da67410ca422498a2f3c39c9baba43 SHA512 5eb0839310b6897aeb5ef067f3bbccc3f302f9d5375fea9c2cf405a6e823560a776a96fa0189b4c9adf1744651a35a41d4fcafc3f9e1ebf5ddeb5d88bece9678
DIST pptpd-1.4.0.tar.gz 252167 BLAKE2B c7fa9397c0a1b7c1ae5f22f9d7f85ba1bb60966984506f7b7c7b4f5dce69efa717f41e8d9a717e4c6f482d2d3e4052611709e0b825a2fcc63fabf19a53a550f0 SHA512 cfb4caef3025c0721e7fabf8b7bf595739f2d3048555b30616cdadc37e70ba9e1c50561c25091dd617b5448da2816aeaf83aea0fc2ef6b0dd5e3fe35d9591484
-EBUILD pptpd-1.4.0-r3.ebuild 2026 BLAKE2B 8f27575b7dc2a91ecf17c50f1e1a6bd1c7e1a58b32f58148e1dc40435ba97cb4b3a34744f0e9f80ce6f971958a640e15aaa87ebe03e1419e8c3995a015b8b4d0 SHA512 c836a57bd3ad17901e8d6d59320fe1826593a1801b871875a7649089dacb0997814670bfb28607cdcf5f3adfe3719efad7ffef2a95ae7fd4b51fc28d39a68e58
+EBUILD pptpd-1.4.0-r3.ebuild 1833 BLAKE2B 0645f465ba89b60bf67e461b643aaff77637e2e5e042935e8fc8ed2b06fb83b3d20db13e36110364601e00c339b656a3a492c46c0b1fb253a49d36c49a4644ae SHA512 d6abfa2baf4fd811cee7450a74f35dccb515bb2cea780d4c94495a12f8f8c610c4785973998a1e4476c4fd3bba9fbebfa0aa6a4a0438a548011b66ad886065d0
MISC metadata.xml 469 BLAKE2B e1c0396ab4a78ed9b1b20dab4a3c81fc4058adacdb87d9f287e0ba9dfdb050ee64727ef95433e249fc1054ad1849ef543fbd0ff35cfd4a2c3f08f3d5ec51965c SHA512 d1d9a5a96795964d88f79aaf93b67948f7298d1410e5ec5bf4a0b98eb11f5157eeb71633209ee6491d1ba02e77454ec641c36ad217c7eb084dc3015a9f8b854b
diff --git a/net-vpn/pptpd/files/pptpd-1.4.0-ppp-2.5.0.patch b/net-vpn/pptpd/files/pptpd-1.4.0-ppp-2.5.0.patch
new file mode 100644
index 000000000000..b3525052a873
--- /dev/null
+++ b/net-vpn/pptpd/files/pptpd-1.4.0-ppp-2.5.0.patch
@@ -0,0 +1,83 @@
+https://bugs.gentoo.org/904877
+
+From ea207b89c61e3a201155b973307ee45413f0d058 Mon Sep 17 00:00:00 2001
+From: Mike Gilbert <floppym@gentoo.org>
+Date: Fri, 28 Apr 2023 16:37:44 -0400
+Subject: [PATCH] pptp-logwtmp: update for ppp-2.5.0
+
+Signed-off-by: Mike Gilbert <floppym@gentoo.org>
+---
+ plugins/pptpd-logwtmp.c | 25 +++++++++++++++----------
+ 1 file changed, 15 insertions(+), 10 deletions(-)
+
+diff --git a/plugins/pptpd-logwtmp.c b/plugins/pptpd-logwtmp.c
+index ac5ecc2..457bbce 100644
+--- a/plugins/pptpd-logwtmp.c
++++ b/plugins/pptpd-logwtmp.c
+@@ -12,14 +12,16 @@
+ #include <unistd.h>
+ #include <utmp.h>
+ #include <string.h>
++#include <limits.h>
+ #include <pppd/pppd.h>
++#include <pppd/options.h>
+
+-char pppd_version[] = VERSION;
++char pppd_version[] = PPPD_VERSION;
+
+ static char pptpd_original_ip[PATH_MAX+1];
+ static bool pptpd_logwtmp_strip_domain = 0;
+
+-static option_t options[] = {
++static struct option options[] = {
+ { "pptpd-original-ip", o_string, pptpd_original_ip,
+ "Original IP address of the PPTP connection",
+ OPT_STATIC, NULL, PATH_MAX },
+@@ -28,7 +30,7 @@ static option_t options[] = {
+ { NULL }
+ };
+
+-static char *reduce(char *user)
++static const char *reduce(const char *user)
+ {
+ char *sep;
+ if (!pptpd_logwtmp_strip_domain) return user;
+@@ -42,8 +44,10 @@ static char *reduce(char *user)
+
+ static void ip_up(void *opaque, int arg)
+ {
+- char *user = reduce(peer_authname);
+- if (debug)
++ const char *peer_authname = ppp_peer_authname(NULL, 0);
++ const char *user = reduce(peer_authname);
++ const char *ifname = ppp_ifname();
++ if (debug_on())
+ notice("pptpd-logwtmp.so ip-up %s %s %s", ifname, user,
+ pptpd_original_ip);
+ logwtmp(ifname, user, pptpd_original_ip);
+@@ -51,16 +55,17 @@ static void ip_up(void *opaque, int arg)
+
+ static void ip_down(void *opaque, int arg)
+ {
+- if (debug)
++ const char *ifname = ppp_ifname();
++ if (debug_on())
+ notice("pptpd-logwtmp.so ip-down %s", ifname);
+ logwtmp(ifname, "", "");
+ }
+
+ void plugin_init(void)
+ {
+- add_options(options);
+- add_notifier(&ip_up_notifier, ip_up, NULL);
+- add_notifier(&ip_down_notifier, ip_down, NULL);
+- if (debug)
++ ppp_add_options(options);
++ ppp_add_notify(NF_IP_UP, ip_up, NULL);
++ ppp_add_notify(NF_IP_DOWN, ip_down, NULL);
++ if (debug_on())
+ notice("pptpd-logwtmp: $Version$");
+ }
+--
+2.40.1
+
diff --git a/net-vpn/pptpd/pptpd-1.4.0-r3.ebuild b/net-vpn/pptpd/pptpd-1.4.0-r3.ebuild
index 3a01c176e448..3a013c769e13 100644
--- a/net-vpn/pptpd/pptpd-1.4.0-r3.ebuild
+++ b/net-vpn/pptpd/pptpd-1.4.0-r3.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2022 Gentoo Authors
+# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@@ -21,21 +21,7 @@ DEPEND="${RDEPEND}
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
@@ -48,6 +34,19 @@ src_prepare() {
# respect compiler, bug #461722
tc-export CC
+ local PATCHES=(
+ "${FILESDIR}/${P}-gentoo.patch"
+ "${FILESDIR}/${P}-sandbox-fix.patch"
+ "${FILESDIR}/${P}-pidfile.patch"
+ "${FILESDIR}/${P}-libdir.patch"
+ "${FILESDIR}/${P}-musl.patch"
+ )
+
+ if has_version -d ">=net-dialup/ppp-2.5.0"; then
+ # https://bugs.gentoo.org/904877
+ PATCHES+=( "${FILESDIR}/${P}-ppp-2.5.0.patch" )
+ fi
+
# Call to default src_prepare to apply patches
default