summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJakov Smolic <jakov.smolic@sartura.hr>2020-11-29 00:09:21 +0100
committerDavid Seifert <soap@gentoo.org>2020-11-29 00:09:21 +0100
commit4b9142d25d28c969e823177916b5319a8f808a7b (patch)
tree74014af41c64aaa5a332770c4607375a8e0c4927 /www-servers
parentsys-fabric/infinipath-psm: fix build with gcc-10 (diff)
downloadgentoo-4b9142d25d28c969e823177916b5319a8f808a7b.tar.gz
gentoo-4b9142d25d28c969e823177916b5319a8f808a7b.tar.bz2
gentoo-4b9142d25d28c969e823177916b5319a8f808a7b.zip
www-servers/sniproxy: fix build with gcc-10, port to GLEP 81
Closes: https://bugs.gentoo.org/707530 Package-Manager: Portage-3.0.9, Repoman-3.0.1 Signed-off-by: Jakov Smolic <jakov.smolic@sartura.hr> Signed-off-by: David Seifert <soap@gentoo.org>
Diffstat (limited to 'www-servers')
-rw-r--r--www-servers/sniproxy/files/sniproxy-0.6.0-fno-common.patch24
-rw-r--r--www-servers/sniproxy/sniproxy-0.6.0-r1.ebuild (renamed from www-servers/sniproxy/sniproxy-0.6.0.ebuild)36
2 files changed, 39 insertions, 21 deletions
diff --git a/www-servers/sniproxy/files/sniproxy-0.6.0-fno-common.patch b/www-servers/sniproxy/files/sniproxy-0.6.0-fno-common.patch
new file mode 100644
index 000000000000..f718bfca736c
--- /dev/null
+++ b/www-servers/sniproxy/files/sniproxy-0.6.0-fno-common.patch
@@ -0,0 +1,24 @@
+Taken from: https://github.com/dlundquist/sniproxy/commit/822bb80df9b7b345cc9eba55df74a07b498819ba
+Author: Pierre-Olivier Mercier <nemunaire@nemunai.re>
+
+--- a/src/http.h
++++ b/src/http.h
+@@ -29,6 +29,6 @@
+ #include <stdio.h>
+ #include "protocol.h"
+
+-const struct Protocol *const http_protocol;
++extern const struct Protocol *const http_protocol;
+
+ #endif
+--- a/src/tls.h
++++ b/src/tls.h
+@@ -28,6 +28,6 @@
+
+ #include "protocol.h"
+
+-const struct Protocol *const tls_protocol;
++extern const struct Protocol *const tls_protocol;
+
+ #endif
+
diff --git a/www-servers/sniproxy/sniproxy-0.6.0.ebuild b/www-servers/sniproxy/sniproxy-0.6.0-r1.ebuild
index 458f1e8ac793..9dc8e5a03ef1 100644
--- a/www-servers/sniproxy/sniproxy-0.6.0.ebuild
+++ b/www-servers/sniproxy/sniproxy-0.6.0-r1.ebuild
@@ -1,15 +1,14 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
-inherit autotools user
+inherit autotools
-if [[ ${PV} == 9999* ]]; then
+if [[ ${PV} == *9999 ]]; then
EGIT_REPO_URI="https://github.com/dlundquist/sniproxy.git"
EGIT_BRANCH="master"
inherit git-r3
- KEYWORDS=""
else
SRC_URI="https://github.com/dlundquist/sniproxy/archive/${PV}.tar.gz -> ${P}.tar.gz"
KEYWORDS="~amd64 ~x86"
@@ -24,18 +23,18 @@ IUSE="+dns +largefile rfc3339 test"
RESTRICT="!test? ( test )"
RDEPEND="
+ acct-group/sniproxy
+ acct-user/sniproxy
dev-libs/libev
>=dev-libs/libpcre-3
- dns? ( net-libs/udns )
-"
+ dns? ( net-libs/udns )"
+DEPEND="${RDEPEND}
+ test? ( net-misc/curl )"
BDEPEND="
- ${RDEPEND}
sys-devel/gettext
- virtual/pkgconfig
-"
-DEPEND="
- test? ( net-misc/curl )
-"
+ virtual/pkgconfig"
+
+PATCHES=( "${FILESDIR}"/${P}-fno-common.patch )
src_prepare() {
default
@@ -55,6 +54,10 @@ src_configure() {
econf "${my_conf[@]}"
}
+src_test() {
+ emake -j1 check
+}
+
src_install() {
default
@@ -72,12 +75,3 @@ src_install() {
doman man/sniproxy.8
doman man/sniproxy.conf.5
}
-
-src_test() {
- emake -j1 check
-}
-
-pkg_postinst() {
- enewgroup "${PN}"
- enewuser "${PN}" -1 -1 /var/lib/sniproxy "${PN}"
-}