[packages/protoshares] - fix building with miniupnpc 2.0 - rel 10

baggins baggins at pld-linux.org
Sun Apr 16 16:21:56 CEST 2017


commit 6b0dd9381aff3ad4b05e9a17e9f79563a46f97c8
Author: Jan Rękorajski <baggins at pld-linux.org>
Date:   Sun Apr 16 16:21:38 2017 +0200

    - fix building with miniupnpc 2.0
    - rel 10

 miniupnpc-2.0.patch | 18 ++++++++++++++++++
 protoshares.spec    |  4 +++-
 2 files changed, 21 insertions(+), 1 deletion(-)
---
diff --git a/protoshares.spec b/protoshares.spec
index 5afbe69..d3700b7 100644
--- a/protoshares.spec
+++ b/protoshares.spec
@@ -1,5 +1,5 @@
 %define	snap	20131203
-%define	rel	9
+%define	rel	10
 Summary:	ProtoShares
 Name:		protoshares
 Version:	0.8.5
@@ -9,6 +9,7 @@ Group:		X11/Applications
 Source0:	ProtoShares-%{snap}.tar.bz2
 # Source0-md5:	f18b07195152c72a1e322444d84b4543
 Patch0:		boost-1.58.patch
+Patch1:		miniupnpc-2.0.patch
 URL:		http://invictus-innovations.com/protoshares
 BuildRequires:	QtCore-devel
 BuildRequires:	QtDBus-devel
@@ -35,6 +36,7 @@ Qt-based ProtoShares Wallet.
 %prep
 %setup -q -n ProtoShares
 %patch0 -p1
+%patch1 -p1
 
 %build
 qmake-qt4 protoshares-qt.pro \
diff --git a/miniupnpc-2.0.patch b/miniupnpc-2.0.patch
new file mode 100644
index 0000000..53cfee8
--- /dev/null
+++ b/miniupnpc-2.0.patch
@@ -0,0 +1,18 @@
+--- primecoin-0.1.2-hp14/src/net.cpp~	2014-04-26 17:02:25.000000000 +0200
++++ primecoin-0.1.2-hp14/src/net.cpp	2017-04-16 16:05:02.024093670 +0200
+@@ -1083,10 +1083,14 @@
+ #ifndef UPNPDISCOVER_SUCCESS
+     /* miniupnpc 1.5 */
+     devlist = upnpDiscover(2000, multicastif, minissdpdpath, 0);
+-#else
++#elif MINIUPNPC_API_VERSION < 14
+     /* miniupnpc 1.6 */
+     int error = 0;
+     devlist = upnpDiscover(2000, multicastif, minissdpdpath, 0, 0, &error);
++#else
++    /* miniupnpc 1.9.20150730 */
++    int error = 0;
++    devlist = upnpDiscover(2000, multicastif, minissdpdpath, 0, 0, 2, &error);
+ #endif
+ 
+     struct UPNPUrls urls;
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/protoshares.git/commitdiff/6b0dd9381aff3ad4b05e9a17e9f79563a46f97c8



More information about the pld-cvs-commit mailing list