Gentoo Archives: gentoo-commits

From: Andrew Savchenko <bircoph@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] dev/bircoph:master commit in: net-libs/libupnp/, net-libs/libupnp/files/
Date: Sat, 04 Jun 2016 15:37:10
Message-Id: 1465054604.fee618cafc9d888ca1f13ff35ec7e098fd91c184.bircoph@gentoo
1 commit: fee618cafc9d888ca1f13ff35ec7e098fd91c184
2 Author: Andrew Savchenko <bircoph <AT> gentoo <DOT> org>
3 AuthorDate: Sat Jun 4 15:36:44 2016 +0000
4 Commit: Andrew Savchenko <bircoph <AT> gentoo <DOT> org>
5 CommitDate: Sat Jun 4 15:36:44 2016 +0000
6 URL: https://gitweb.gentoo.org/dev/bircoph.git/commit/?id=fee618ca
7
8 net-libs/libupnp: fix bug 556604
9
10 Package-Manager: portage-2.3.0_rc1
11 Signed-off-by: Andrew Savchenko <bircoph <AT> gentoo.org>
12
13 net-libs/libupnp/Manifest | 1 +
14 .../files/libupnp-1.6.19-docs-install.patch | 13 ++
15 net-libs/libupnp/files/libupnp-1.6.19-suse.patch | 132 +++++++++++++++++++++
16 net-libs/libupnp/libupnp-1.6.19.ebuild | 53 +++++++++
17 net-libs/libupnp/metadata.xml | 19 +++
18 5 files changed, 218 insertions(+)
19
20 diff --git a/net-libs/libupnp/Manifest b/net-libs/libupnp/Manifest
21 new file mode 100644
22 index 0000000..e86b7dc
23 --- /dev/null
24 +++ b/net-libs/libupnp/Manifest
25 @@ -0,0 +1 @@
26 +DIST libupnp-1.6.19.tar.bz2 1213439 SHA256 b3142b39601243b50532eec90f4a27dba85eb86f58d4b849ac94edeb29d9b22a SHA512 97af62a7483cc19cfe80157cbc3383c1b4b7c9c39b848f4ed063784b74df0b9b0527f7b467e01451e0a44dbf9e8a9eab510619146a6ee1e3dce46f3e4af6e661 WHIRLPOOL fe3ed0115c76872b45eb3f16909e23c61b004f028b745be17346b94dffd7c90108420cf71f50f73aa4ef241403b65b9d1c72926af3044ffacdae11f9649dad68
27
28 diff --git a/net-libs/libupnp/files/libupnp-1.6.19-docs-install.patch b/net-libs/libupnp/files/libupnp-1.6.19-docs-install.patch
29 new file mode 100644
30 index 0000000..622f58a
31 --- /dev/null
32 +++ b/net-libs/libupnp/files/libupnp-1.6.19-docs-install.patch
33 @@ -0,0 +1,13 @@
34 +--- libupnp-1.6.19/upnp/sample/Makefile.am.orig 2013-11-15 19:50:02.000000000 +0400
35 ++++ libupnp-1.6.19/upnp/sample/Makefile.am 2016-06-03 20:30:43.545081667 +0300
36 +@@ -65,8 +65,8 @@
37 + if WITH_DOCUMENTATION
38 + examplesdir = $(docdir)/examples
39 + examples_DATA = \
40 +- $(tv_ctrlpt_SOURCES) \
41 +- $(tv_device_SOURCES)
42 ++ $(sort $(tv_ctrlpt_SOURCES) \
43 ++ $(tv_device_SOURCES) )
44 + endif
45 +
46 + EXTRA_DIST = \
47
48 diff --git a/net-libs/libupnp/files/libupnp-1.6.19-suse.patch b/net-libs/libupnp/files/libupnp-1.6.19-suse.patch
49 new file mode 100644
50 index 0000000..75a7f0d
51 --- /dev/null
52 +++ b/net-libs/libupnp/files/libupnp-1.6.19-suse.patch
53 @@ -0,0 +1,132 @@
54 +--- configure.ac 2013-01-29 16:39:56.000000000 +0100
55 ++++ configure.ac 2013-02-17 10:40:53.680021913 +0100
56 +@@ -7,9 +7,9 @@
57 + # (C) Copyright 2005-2007 Rémi Turboult <r3mi@×××××××××××××××××.net>
58 + #
59 +
60 +-AC_PREREQ(2.60)
61 ++AC_PREREQ([2.60])
62 +
63 +-AC_INIT([libupnp], [1.6.19], [mroberto@×××××××××××××××××.net])
64 ++AC_INIT([libupnp],[1.6.19],[mroberto@×××××××××××××××××.net])
65 + dnl ############################################################################
66 + dnl # *Independently* of the above libupnp package version, the libtool version
67 + dnl # of the 3 libraries need to be updated whenever there is a change released:
68 +@@ -366,7 +366,6 @@
69 + # installed libraries.
70 + #
71 + AC_CONFIG_HEADERS([autoconfig.h upnp/inc/upnpconfig.h])
72 +-#AC_SYS_LARGEFILE_SENSITIVE
73 +
74 + AC_REVISION([$Revision: 1.1 $])
75 +
76 +@@ -519,10 +519,12 @@
77 + #
78 + # Checks for programs
79 + #
80 +-AC_PROG_CC
81 ++AC_PROG_CC_STDC
82 ++AC_USE_SYSTEM_EXTENSIONS
83 ++AC_SYS_LARGEFILE
84 + AM_PROG_CC_C_O
85 + m4_ifdef([AM_PROG_AR], [AM_PROG_AR])
86 +-AC_PROG_LIBTOOL
87 ++LT_INIT
88 + AC_PROG_INSTALL
89 + AC_PROG_MAKE_SET
90 + AC_PROG_EGREP
91 +@@ -532,9 +534,7 @@
92 + #:
93 + # Use -O0 in debug so that variables do not get optimized out
94 + AX_CFLAGS_GCC_OPTION([-O0, -g])
95 +- else
96 +- # add optimise for size
97 +- AX_CFLAGS_GCC_OPTION([-Os])
98 ++
99 + fi
100 + ;;
101 + esac
102 +@@ -548,8 +548,7 @@
103 + #
104 + AC_TYPE_SIZE_T
105 + AC_TYPE_OFF_T
106 +-AC_DEFINE([_LARGE_FILE_SOURCE], [], [Large files support])
107 +-AC_DEFINE([_FILE_OFFSET_BITS], [64], [File Offset size])
108 ++
109 +
110 +
111 + #
112 +--- ixml/Makefile.am.orig
113 ++++ ixml/Makefile.am
114 +@@ -7,7 +7,7 @@
115 +
116 + SUBDIRS = doc
117 +
118 +-AM_CPPFLAGS = -I$(srcdir)/inc -I$(srcdir)/src/inc
119 ++AM_CPPFLAGS = -include $(top_builddir)/autoconfig.h -I$(srcdir)/inc -I$(srcdir)/src/inc
120 + AM_CFLAGS =
121 +
122 + LDADD = libixml.la
123 +--- threadutil/Makefile.am.orig
124 ++++ threadutil/Makefile.am
125 +@@ -4,7 +4,7 @@
126 + # (C) Copyright 2005 Remi Turboult <r3mi@×××××××××××××××××.net>
127 + #
128 +
129 +-AM_CPPFLAGS = -I$(srcdir)/inc -I$(srcdir)/src/inc
130 ++AM_CPPFLAGS = -include $(top_builddir)/autoconfig.h -I$(srcdir)/inc -I$(srcdir)/src/inc
131 +
132 + if ENABLE_DEBUG
133 + AM_CPPFLAGS += -DDEBUG -DSTATS
134 +--- upnp/src/api/UpnpString.c.orig
135 ++++ upnp/src/api/UpnpString.c
136 +@@ -28,38 +28,6 @@
137 + /* Other systems have strncasecmp */
138 + #endif
139 +
140 +-#ifndef UPNP_USE_MSVCPP
141 +- /* VC has strnlen which is already included but with (potentially) different linkage */
142 +- /* strnlen() is a GNU extension. */
143 +- #if HAVE_STRNLEN
144 +- extern size_t strnlen(const char *s, size_t maxlen);
145 +- #else /* HAVE_STRNLEN */
146 +- static size_t strnlen(const char *s, size_t n)
147 +- {
148 +- const char *p = (const char *)memchr(s, 0, n);
149 +- return p ? p - s : n;
150 +- }
151 +- #endif /* HAVE_STRNLEN */
152 +-#endif /* WIN32 */
153 +-
154 +-/* strndup() is a GNU extension. */
155 +-#if HAVE_STRNDUP && !defined(WIN32)
156 +- extern char *strndup(__const char *__string, size_t __n);
157 +-#else /* HAVE_STRNDUP && !defined(WIN32) */
158 +- static char *strndup(const char *__string, size_t __n)
159 +- {
160 +- size_t strsize = strnlen(__string, __n);
161 +- char *newstr = (char *)malloc(strsize + 1);
162 +- if (newstr == NULL)
163 +- return NULL;
164 +-
165 +- strncpy(newstr, __string, strsize);
166 +- newstr[strsize] = 0;
167 +-
168 +- return newstr;
169 +- }
170 +-#endif /* HAVE_STRNDUP && !defined(WIN32) */
171 +-
172 + /*!
173 + * \brief Internal implementation of the class UpnpString.
174 + *
175 +--- upnp/Makefile.am.orig
176 ++++ upnp/Makefile.am
177 +@@ -6,7 +6,7 @@
178 +
179 + SUBDIRS = doc . sample
180 +
181 +-AM_CPPFLAGS = \
182 ++AM_CPPFLAGS = -include $(top_builddir)/autoconfig.h \
183 + -I$(srcdir)/inc \
184 + -I$(top_srcdir)/threadutil/inc \
185 + -I$(top_srcdir)/ixml/inc
186
187 diff --git a/net-libs/libupnp/libupnp-1.6.19.ebuild b/net-libs/libupnp/libupnp-1.6.19.ebuild
188 new file mode 100644
189 index 0000000..c589c65
190 --- /dev/null
191 +++ b/net-libs/libupnp/libupnp-1.6.19.ebuild
192 @@ -0,0 +1,53 @@
193 +# Copyright 1999-2016 Gentoo Foundation
194 +# Distributed under the terms of the GNU General Public License v2
195 +# $Id$
196 +
197 +EAPI=5
198 +
199 +inherit eutils flag-o-matic autotools
200 +
201 +DESCRIPTION="An Portable Open Source UPnP Development Kit"
202 +HOMEPAGE="http://pupnp.sourceforge.net/"
203 +SRC_URI="mirror://sourceforge/pupnp/${P}.tar.bz2"
204 +
205 +LICENSE="BSD"
206 +SLOT="0"
207 +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ppc ~ppc64 ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux"
208 +IUSE="debug doc ipv6 static-libs"
209 +
210 +DOCS="NEWS README ChangeLog"
211 +
212 +src_prepare() {
213 + epatch "${FILESDIR}"/${P}-suse.patch \
214 + "${FILESDIR}"/${P}-docs-install.patch
215 +
216 + # fix tests
217 + chmod +x ixml/test/test_document.sh || die
218 +
219 + eautoreconf
220 +}
221 +
222 +src_configure() {
223 + use x86-fbsd && append-flags -O1
224 + # w/o docdir to avoid sandbox violations
225 + econf \
226 + $(use_enable debug) \
227 + $(use_enable ipv6) \
228 + $(use_enable static-libs static) \
229 + $(use_with doc documentation "${EPREFIX}/usr/share/doc/${PF}")
230 +}
231 +
232 +src_install () {
233 + default
234 + dobin upnp/sample/.libs/tv_{combo,ctrlpt,device}
235 + use static-libs || prune_libtool_files
236 +}
237 +
238 +pkg_postinst() {
239 + ewarn "Please remember to run revdep-rebuild when upgrading"
240 + ewarn "from libupnp 1.4.x to libupnp 1.6.x , so packages"
241 + ewarn "gets linked with the new library."
242 + echo ""
243 + ewarn "The revdep-rebuild script is part of the"
244 + ewarn "app-portage/gentoolkit package."
245 +}
246
247 diff --git a/net-libs/libupnp/metadata.xml b/net-libs/libupnp/metadata.xml
248 new file mode 100644
249 index 0000000..0fcdbd7
250 --- /dev/null
251 +++ b/net-libs/libupnp/metadata.xml
252 @@ -0,0 +1,19 @@
253 +<?xml version="1.0" encoding="UTF-8"?>
254 +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
255 +<pkgmetadata>
256 + <maintainer type="person">
257 + <email>maq@××××××××.com</email>
258 + <name>Marcus Stjärnås</name>
259 + </maintainer>
260 + <maintainer type="person">
261 + <email>gurligebis@g.o</email>
262 + <name>Bjarke Istrup Pedersen</name>
263 + </maintainer>
264 + <maintainer type="project">
265 + <email>proxy-maint@g.o</email>
266 + <name>Proxy Maintainers</name>
267 + </maintainer>
268 + <upstream>
269 + <remote-id type="sourceforge">pupnp</remote-id>
270 + </upstream>
271 +</pkgmetadata>