[packages/ncmpcpp] new patch to fix build on 32bit archs; rel 2

atler atler at pld-linux.org
Mon Oct 31 23:22:40 CET 2016


commit 97dc3c2d2155a4eed05ac5be14498561f5541f92
Author: Jan Palus <atler at pld-linux.org>
Date:   Mon Oct 31 23:21:09 2016 +0100

    new patch to fix build on 32bit archs; rel 2
    
    explicitly create size_t instead of guessing underlying type

 ncmpcpp-size_t.patch | 12 ++++++++++++
 ncmpcpp.spec         |  4 +++-
 2 files changed, 15 insertions(+), 1 deletion(-)
---
diff --git a/ncmpcpp.spec b/ncmpcpp.spec
index 8ecf381..7624dd3 100644
--- a/ncmpcpp.spec
+++ b/ncmpcpp.spec
@@ -2,11 +2,12 @@ Summary:	ncurses mpd client inspired by ncmpc
 Summary(pl.UTF-8):	klient mpd wzorowany na ncmpc
 Name:		ncmpcpp
 Version:	0.7.6
-Release:	1
+Release:	2
 License:	GPL v2
 Group:		Applications
 Source0:	http://ncmpcpp.rybczak.net/stable/%{name}-%{version}.tar.bz2
 # Source0-md5:	cd8b478d6968dc361f6e062acbe2d255
+Patch0:		%{name}-size_t.patch
 URL:		http://ncmpcpp.rybczak.net
 BuildRequires:	autoconf >= 2.59
 BuildRequires:	automake
@@ -38,6 +39,7 @@ plików lokalnych oraz inne drobne udogodnienia.
 
 %prep
 %setup -q
+%patch0 -p1
 
 %build
 %{__libtoolize}
diff --git a/ncmpcpp-size_t.patch b/ncmpcpp-size_t.patch
new file mode 100644
index 0000000..8f77502
--- /dev/null
+++ b/ncmpcpp-size_t.patch
@@ -0,0 +1,12 @@
+diff -urN ncmpcpp-0.7.6.orig/src/utility/html.cpp ncmpcpp-0.7.6/src/utility/html.cpp
+--- ncmpcpp-0.7.6.orig/src/utility/html.cpp	2016-10-31 23:17:38.007041389 +0100
++++ ncmpcpp-0.7.6/src/utility/html.cpp	2016-10-31 23:18:00.243521920 +0100
+@@ -66,7 +66,7 @@
+ 	for (size_t i = s.find("<"); i != std::string::npos; i = s.find("<"))
+ 	{
+ 		size_t j = s.find(">", i)+1;
+-		if (s.compare(i, std::min(3ul, j-i), "<p ") == 0 || s.compare(i, j-i, "</p>") == 0)
++		if (s.compare(i, std::min(std::size_t{3}, j-i), "<p ") == 0 || s.compare(i, j-i, "</p>") == 0)
+ 			s.replace(i, j-i, "\n");
+ 		else
+ 			s.replace(i, j-i, "");
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/ncmpcpp.git/commitdiff/97dc3c2d2155a4eed05ac5be14498561f5541f92



More information about the pld-cvs-commit mailing list