net-misc/sstp-client: add 1.0.18

Closes: https://bugs.gentoo.org/870865
Closes: https://bugs.gentoo.org/854858
Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
Sam James
2023-01-23 02:31:01 +00:00
parent a60d56a963
commit 9ca397b84c
3 changed files with 108 additions and 0 deletions

View File

@@ -1 +1,2 @@
DIST sstp-client-1.0.17.tar.gz 482831 BLAKE2B d19c752b3f061401f89eb46bd52091e3ab0a3c931c6646a55c1ee0e6dd7e9c501fba14b7c870a2514cb72fb0fd1d8bc89538562d4d99b9d58a081e0917734f5d SHA512 eff18eb894b2c96d46315b5ac7530fe50e8dd6e6c29ea946cd0e7c05c56416e85088fc65650fb77c05e3a747cb0b4e3575af5457515d240161027910abae9775
DIST sstp-client-1.0.18.tar.gz 477886 BLAKE2B 3a2929a5245a703c36b9bf6c17b7f65d911446a8a44b95894fd990ccf5ad01a98e4b5e843681e4643ff4b28a57de359a98ef42f9bb378d52c6829297970399b6 SHA512 e0dd0fe57b65c2001737222159e58b11177a8f1cb64564e520fad2199c0581d0550a00f49c921be74039dec59062233b4716f8b624a0e4cb48bdf8df9272f93c

View File

@@ -0,0 +1,42 @@
https://gitlab.com/eivnaes/sstp-client/-/merge_requests/4
From 1d822cca1c4e5b4db91bcbabe29bf43c05449af7 Mon Sep 17 00:00:00 2001
From: Sam James <sam@gentoo.org>
Date: Mon, 23 Jan 2023 02:26:28 +0000
Subject: [PATCH 1/2] libsstp-log: add missing <time.h> include
Needed for time_t. Fixes build w/ GCC 12 on musl.
Bug: https://bugs.gentoo.org/854858
--- a/src/libsstp-log/sstp-log-private.h
+++ b/src/libsstp-log/sstp-log-private.h
@@ -24,6 +24,7 @@
#ifndef __SSTP_LOG_PRIVATE_H__
#define __SSTP_LOG_PRIVATE_H__
+#include <time.h>
/*! Keep attributes aligned to a 32-bit boundary */
#define LOG_ALIGN32(n) \
From 835c6226aaccb4c39a8c50dec5d3afd87315fddd Mon Sep 17 00:00:00 2001
From: Sam James <sam@gentoo.org>
Date: Mon, 23 Jan 2023 02:28:18 +0000
Subject: [PATCH 2/2] pppd-plugin: workaround broken pppd.h header for memcpy
ppp's pppd.h defines a BCOPY macro which expands to memcpy but doesn't
include <string.h> which provides it. Include it in pppd-plugin instead
to workaround it, as it'll be a while before we can assume the system ppp
is fixed.
Bug: https://bugs.gentoo.org/870865
--- a/src/pppd-plugin/sstp-mppe.c
+++ b/src/pppd-plugin/sstp-mppe.c
@@ -24,6 +24,7 @@
#include <config.h>
+#include <string.h>
#include <pppd/pppd.h>
#include <sstp-mppe.h>

View File

@@ -0,0 +1,65 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit autotools linux-info
DESCRIPTION="A client implementation of Secure Socket Tunneling Protocol (SSTP)"
HOMEPAGE="http://sstp-client.sourceforge.net/"
SRC_URI="mirror://sourceforge/sstp-client/${P}.tar.gz"
LICENSE="GPL-2+-with-openssl-exception"
SLOT="0"
KEYWORDS="~amd64 ~arm ~arm64 ~x86"
IUSE="static"
DEPEND="dev-libs/libevent:=
dev-libs/openssl:=
net-dialup/ppp:="
RDEPEND="${DEPEND}
acct-group/sstpc
acct-user/sstpc"
BDEPEND="virtual/pkgconfig"
CONFIG_CHECK="~NETFILTER_NETLINK"
PATCHES=(
"${FILESDIR}/${PN}-1.0.12-remove-network-test.patch"
"${FILESDIR}/${PN}-1.0.12-fix-example.patch"
"${FILESDIR}/${PN}-1.0.18-includes.patch"
)
DOCS=( AUTHORS ChangeLog DEVELOPERS NEWS README TODO USING )
src_prepare() {
default
eautoreconf
}
src_configure() {
local PPPD_VER="$(best_version net-dialup/ppp)"
# Reduce it to ${PV}-${PR}
PPPD_VER=${PPPD_VER#*/*-}
# Main version without beta/pre/patch/revision
PPPD_VER=${PPPD_VER%%[_-]*}
local myeconfargs=(
--enable-ppp-plugin
--enable-group=sstpc
--enable-user=sstpc
--with-pppd-plugin-dir="/usr/$(get_libdir)/pppd/${PPPD_VER}"
--with-runtime-dir="/run/sstpc"
$(use_enable static)
)
econf "${myeconfargs[@]}"
}
src_install() {
default
find "${ED}" -name '*.la' -delete || die
}